Skip to content

Commit 33554f5

Browse files
committed
new USBHID
1 parent 704cf02 commit 33554f5

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

examples/GameportToUSB/GameportToUSB.ino

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

44
#define LED_BUILTIN PB12 // change to match your board
55

@@ -26,7 +26,8 @@ GamePortController controller(PA0,PA1,PA2,PA3,PA4,PA5,PA6,PA7);
2626
void setup()
2727
{
2828
pinMode(LED_BUILTIN, OUTPUT);
29-
29+
30+
USBHID.begin(HID_JOYSTICK);
3031
digitalWrite(LED_BUILTIN, 1);
3132
controller.begin();
3233
adc_set_sample_rate(ADC1, ADC_SMPR_13_5); // ADC_SMPR_13_5, ADC_SMPR_1_5

0 commit comments

Comments
 (0)