Use Arduino for sending button states through a serial port and use a python script (using pyserial) to convert the read states into keyboard/mouse presses (using pynput).
Advantages:
you are not limited to Micro//Leonardo but can incorporate other boards as well (Mega has more individual pins, saving you from using key matrixes and allowing you for more buttons pressed simultaneously),
you can more easily incorporate custom button mappings to the script.
3
u/Atlantic_Underdog Dec 11 '21
Word of advice: ditch the micro.
Use Arduino for sending button states through a serial port and use a python script (using pyserial) to convert the read states into keyboard/mouse presses (using pynput).
Advantages:
you are not limited to Micro//Leonardo but can incorporate other boards as well (Mega has more individual pins, saving you from using key matrixes and allowing you for more buttons pressed simultaneously),
you can more easily incorporate custom button mappings to the script.