Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed FastIO FastPWM USBDevice
Diff: USBJoystick/USBJoystick.h
- Revision:
- 11:bd9da7088e6e
- Parent:
- 10:976666ffa4ef
- Child:
- 21:5048e16cc9ef
diff -r 976666ffa4ef -r bd9da7088e6e USBJoystick/USBJoystick.h --- a/USBJoystick/USBJoystick.h Sat Aug 23 01:24:36 2014 +0000 +++ b/USBJoystick/USBJoystick.h Tue Aug 26 22:24:54 2014 +0000 @@ -106,7 +106,7 @@ * @param buttons buttons state, as a bit mask (combination with '|' of JOY_Bn values) * @returns true if there is no error, false otherwise */ - bool update(int16_t x, int16_t y, int16_t z, uint16_t buttons, uint16_t status); + bool update(int16_t x, int16_t y, int16_t z, uint32_t buttons, uint16_t status); /** * Write an exposure report. We'll fill out a report with as many pixels as @@ -149,7 +149,7 @@ * @param buttons button state, as a bitwise combination of JOY_Bn values * @returns true if there is no error, false otherwise */ - bool buttons(uint16_t buttons); + bool buttons(uint32_t buttons); /* * To define the report descriptor. Warning: this method has to store the length of the report descriptor in reportLength. @@ -167,7 +167,8 @@ int16_t _x; int16_t _y; int16_t _z; - uint16_t _buttons; + uint16_t _buttonsLo; + uint16_t _buttonsHi; uint16_t _status; void _init();