Resources | Resources |




This section describes the interfaces that Brew MP provides for managing user input through the jogdial on a mobile device.

OEM to Brew shell:

Upon receiving a jogdial event from drivers, the OEM has to call either AEE_Event(EVT_JOGDIAL_POS, 0, +1) or AEE_Event(EVT_JOGDIAL_POS, 0, -1). The third parameter takes either + 1 or -1 based on the direction in which the jogdial was moved, where +1 signifies counter-clockwise movement, and -1 signifies clockwise movement.

After receiving this event, the Brew MP shell calculates wParam and populates dwParam as OEM-sent, and posts the event to applications or clients.

The prototype of AEEEvent is:

AEE_Event(AEEEvent evt, uint16 wParam, uint32 dwParam);

...where dwParam is a 32-bit parameter takes either a +1 or -1 value. After receiving this event, Brew MP applications need to type cast dwParam to an int32 variable.

For example, after the jogdial is moved clockwise, the following event is sent:

AEE_Event(EVT_JOGDIAL_POS, 0, -1);

Brew shell to applications:

The Brew MP shell posts the EVT_JOGDIAL_POS event to applications or clients that have to handle this event. Brew MP also sends dwParam and wParam along with this event.

dwParam is a uint32 variable. A positive value (+1) indicates counter-clockwise movement, and a negative value (-1) indicates clockwise movement. wParam represents the 16 least significant bits of GETUPTIMEMS(), which indicates the time lag between events.