Open errorflash opened 1 year ago
I believe the GamepadExample or the FunduinoJoystickShield examples that are provided with the library are what you are looking for. You can also check out http://mheironimus.blogspot.com/2022/07/simple-arduino-leonardo-usb-game-pad.html?m=1.
Is it possible to get an easy example (not the test example) ??
eg.:
Joystick A........... Joystick B...........
Buttons........
Analag IN A........ Analog IN B.......
I have no big brain in Programming and i don`t understand the Test code for own Projects.
Thanks for help!
`/ Bagger Joysticks 1.0 /
include
Joystick_ {joystick1(0x04, JOYSTICK_TYPEJOYSTICK, 3, 0, true, true, false, false, false, false, false, false, false, false, false)}; Joystick {joystick2(0x03, JOYSTICK_TYPE_JOYSTICK, 3, 0, true, true, false, false, false, false, false, false, false, false, false)};
const int pinToButtonMap = 2;
void setup(){
pinMode(2, INPUT_PULLUP); pinMode(3, INPUT_PULLUP); pinMode(4, INPUT_PULLUP); pinMode(5, INPUT_PULLUP); pinMode(6, INPUT_PULLUP); pinMode(7, INPUT_PULLUP);
const int pinToButtonMap = 2; } void loop() {
}`