this script (and a firmware reflashing) allows you to use an arduino uno r3 with a joystick and two buttons as a keyboard/controller
| controller.ino | ||
| README.md | ||
arduino-uno-r3-as-keyboard
this script (and a firmware reflashing) allows you to use an arduino uno r3 with a joystick and two buttons as a keyboard/controller
the firmware part
so first you grab your firmwares from https://github.com/robinplantey/arduino-hid-keyboard
when testing, after uploading your code (usually as root):
dfu-programmer atmega16u2 erase
dfu-programmer atmega16u2 flash --debug 1 Arduino-keyboard-0.3.hex
dfu-programmer atmega16u2 reset
then you powercycle
when editing, or to reset firmware,
dfu-programmer atmega16u2 erase
dfu-programmer atmega16u2 flash --debug 1 Arduino-usbserial-atmega16u2-Uno-Rev3.hex
dfu-programmer atmega16u2 reset
also because my pc is stupid i usually have to chmod 777 /dev/ttyACM0 before uploading but if you can already upload programs to it you're fine lol