Skip to content

Commit e969ae0

Browse files
committed
match 0.91 USBComposite library
1 parent bcbb062 commit e969ae0

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

examples/GameportToUSB/GameportToUSB.ino

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#include "GameControllers.h" // https://github.com/arpruss/GameControllersSTM32
2-
#include "USBHID.h" // https://github.com/arpruss/USBHID_stm32f1
2+
#include "USBComposite.h" // https://github.com/arpruss/USBHID_stm32f1
33

44
#define LED_BUILTIN PB12 // change to match your board ; PB12 for some black pills ; PC13 for blue/red pill
55

@@ -20,13 +20,15 @@
2020
// Gameport 14 (B4) -- A7 (button 4)
2121

2222
GamePortController controller(PA0,PA1,PA2,PA3,PA4,PA5,PA6,PA7);
23+
USBHID HID;
24+
HIDJoystick Joystick(HID);
2325

2426
void setup()
2527
{
2628
pinMode(LED_BUILTIN, OUTPUT);
2729
USBComposite.setProductId(0xE004);
2830
USBComposite.setProductString("MapleGameportToUSB");
29-
USBHID.begin(HID_JOYSTICK);
31+
HID.begin(HID_JOYSTICK);
3032
// USBHID.registerComponent();
3133
// USBComposite.begin();
3234
digitalWrite(LED_BUILTIN, 1);

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=GameControllersSTM32
2-
version=0.0.4
2+
version=0.0.5
33
author=Alexander Pruss
44
maintainer=arpruss <[email protected]>
55
sentence=Support Nunchuck, GameCube controller and Game Port joysticks on STM32F1

0 commit comments

Comments
 (0)