16 Commits

Author SHA1 Message Date
lemmingDev
0d66fbca5f Configurable HID descriptor
Major update.
Library now has a configurable HID descriptor that allows users to customise how the gamepad presents itself to the operating system
2021-04-06 12:17:44 +10:00
lemmingDev
6fe951491b Merge branch 'NimBLE' into NimBLE-Updated 2021-01-13 16:41:22 +10:00
lemmingDev
7217ec3677 64 buttons, added 2 sliders, all axes 16bit
Library now additionally supports:
- 2 sliders
- 64 buttons (up from 32)
- 16bit on all axes (left/right triggers and sliders are unsigned, left/right thumbsticks are centered on zero)
- updated examples
2021-01-13 16:28:48 +10:00
lemmingDev
6fd458494c Merge branch 'master' into Updates 2021-01-10 00:33:50 +10:00
lemmingDev
5e15b7f960 Ability to update individual axes
void setX(int16_t x = 0);
  void setY(int16_t y = 0);
  void setZ(int16_t z = 0);
  void setRZ(int16_t rZ = 0);
  void setRX(int16_t rX = 0);
  void setRY(int16_t rY = 0);
2021-01-09 23:16:42 +10:00
lemmingDev
3f78c7ac83 Individual axes can be set
Now, each axis/hat can be set independently

setLeftThumb takes 2 int16_t parameters for x and y axes
setRightThumb takes 2 int16_t parameters for z and rZ axes
setLeftTrigger takes 1 char parameter for rX axis
setRightTrigger takes 1 char parameter for rY axis
setHat takes a hat position as above (or 0 = centered and 1~8 are the 8 possible directions)

Axes/hat can still be set all at once with setAxes

Library can now disable the aotoReport feature (enabled by default), and manually call the sendReport() function when wanted
2021-01-07 22:17:37 +10:00
wakwak_koba
e3f9997fcd Merge remote-tracking branch 'upstream/master' 2021-01-06 06:50:57 +09:00
lemmingDev
d046a6ce41 Change device ID
Change device ID so Windows recognises it as a new controller, so the game controller control panel currently names the amount of buttons after the recent library change
2020-11-29 08:07:38 +10:00
lemmingDev
3018600dbd 32 buttons and X,Y,Z and rZ axes are now 16 bit
Library now supports 32 buttons
X,Y,Z and rZ axes are now 16 bit int16_t (-32767 to 32767) instead of 8 bit (-127 to 127)

If you're upgrading, remember to account for this when setting your axes values
2020-11-28 13:43:27 +10:00
lemmingDev
2a6256e841 Attempt to add iOS compatibility 2020-11-22 13:38:40 +10:00
wakwak_koba
f660c548a5 for NimBLE-Arduino 2020-10-06 20:58:53 +09:00
lemmingDev
ce8cf9e981 Update BleGamepad.cpp
fix previous commit error bleKeyboardInstance --> BleGamepadInstance
2020-05-08 17:50:43 +10:00
Vladimir Dronnikov
7b6ed11ba8 Update BleGamepad.cpp 2020-04-26 06:55:30 +03:00
Marco Graf
599dcda97e setting battery level also in hid, if it was created, yet. Accordingly to commit on ESP32-BLE-Mouse
replaced tabs with spaces
2020-02-20 22:00:26 +01:00
lemmingDev
32306c3d11 Thumbsticks are now passed to setAxes as unsigned chars (0 ~ 255) (255 being fully depressed) 2019-09-17 21:02:13 +10:00
lemmingDev
3ed1c21ac5 Add files via upload 2019-09-14 18:32:50 +10:00