PDL for FM4  Version1.2
Peripheral Driverl Library for FM4
USB Device Middleware: HID Joystick

Functions

void UsbDeviceHidJoystick_Init (stc_usbn_t *pstcUsb)
 
void UsbDeviceHidJoystick_ChangeThrottle (int8_t iThrottle)
 
void UsbDeviceHidJoystick_ChangeX (int8_t iX)
 
void UsbDeviceHidJoystick_ChangeY (int8_t iY)
 
void UsbDeviceHidJoystick_ChangeXY (int8_t iX, int8_t iY)
 
void UsbDeviceHidJoystick_ChangeButton1 (boolean_t bButtonValue)
 
void UsbDeviceHidJoystick_ChangeButton2 (boolean_t bButtonValue)
 
void UsbDeviceHidJoystick_ChangeButton3 (boolean_t bButtonValue)
 
void UsbDeviceHidJoystick_ChangeButton4 (boolean_t bButtonValue)
 
void UsbDeviceHidJoystick_ChangeHatUp (void)
 
void UsbDeviceHidJoystick_ChangeHatRight (void)
 
void UsbDeviceHidJoystick_ChangeHatDown (void)
 
void UsbDeviceHidJoystick_ChangeHatLeft (void)
 
void UsbDeviceHidJoystick_ChangeHatNoDirection (void)
 
boolean_t UsbDeviceHidJoystick_IsConnected (void)
 

Detailed Description

Provided functions of USB Device Joystick module:

Used to enumerate a joystick device

Function Documentation

void UsbDeviceHidJoystick_ChangeButton1 ( boolean_t  bButtonValue)

Used to change the button 1 value

Parameters
bButtonValueTRUE = pressed, FALSE = released

Definition at line 246 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeButton2 ( boolean_t  bButtonValue)

Used to change the button 2 value

Parameters
bButtonValueTRUE = pressed, FALSE = released

Definition at line 266 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeButton3 ( boolean_t  bButtonValue)

Used to change the button 3 value

Parameters
bButtonValueTRUE = pressed, FALSE = released

Definition at line 286 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeButton4 ( boolean_t  bButtonValue)

Used to change the button 4 value

Parameters
bButtonValueTRUE = pressed, FALSE = released

Definition at line 306 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeHatDown ( void  )

Used to change the hat direction DOWN

Definition at line 351 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeHatLeft ( void  )

Used to change the hat direction LEFT

Definition at line 364 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeHatNoDirection ( void  )

Used to change the hat direction no direction

Definition at line 377 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeHatRight ( void  )

Used to change the hat direction RIGHT

Definition at line 338 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeHatUp ( void  )

Used to change the hat direction UP

Definition at line 325 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeThrottle ( int8_t  iThrottle)

Used to change the throttle value

Parameters
iThrottlesigned byte value

Definition at line 190 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeX ( int8_t  iX)

Used to change the X value

Parameters
iXsigned byte value

Definition at line 203 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeXY ( int8_t  iX,
int8_t  iY 
)

Used to change the X and Y value

Parameters
iXsigned byte value
iYsigned byte value

Definition at line 232 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

void UsbDeviceHidJoystick_ChangeY ( int8_t  iY)

Used to change the Y value

Parameters
iYsigned byte value

Definition at line 216 of file UsbDeviceHidJoystick.c.

References pu8JoystickData, SendData(), and UsbPOLL.

Here is the call graph for this function:

boolean_t UsbDeviceHidJoystick_IsConnected ( void  )

Return connected state

Returns
TRUE if ready

Definition at line 391 of file UsbDeviceHidJoystick.c.

References bReady.