rasberry pi and pygame

April 9, 2024, 21:40

animelover1212

Hi. So for a project for school I’m thinking of using a breadboard as a controller for a game I made in pygame. I want to make a controller with a breadboard and buttons. If the player presses the button, it moves the character. Is this possible before I start?

thetysonator

ofc

oops.se

Yes, some models of Pis can be a USB HID (Human Interface Device) aka keyboard/mouse via the "USB Gadget mode" and then you can emulate a keyboard key press from a "Button" press.