Limitations on USB gamepads/keyboards?
-
Hi again
I've been doing some research on how I can implement controllers on my handheld project. I'll need something like 15 buttons in total, ranging from gamepad functionality to system functions like save and load, exit emulator etc. Setting up buttons directly on the GPIO pins seems inconvenient. There's also the controlblock thing that seems neat, but a little expensive. What I'm thinking is, why go through these alternatives if a USB keyboard has like 40 keys I can use? Aside from the analog stick, any cheap USB keyboard has more than what I need all in one. I just have to break it apart and rewire whatever buttons I want. The keyboard is just an example, of course, the internal board is huge; I would use a simple gamepad with some extra buttons so it doesn't take up so much room.But there must be a catch here I'm not seeing. What's the catch??
-
@diegzumillo What about a USB 10 key? I have an old one I got at a $1 store, but I'm guessing they sell them online nowadays. Mine has 19 keys on it (including the numlock key). I haven't had it apart, but I would imagineyou could tack external buttons directly to the PCB.
-
Besides the lack of an analog stick, that's a great idea! If you only want dpad, it's good enough.
So... no catch then? How curious. My skepticism sense is still tingling. But I'll look for a USB thing with an analog stick and plenty of buttons and see what happens :)
-
@diegzumillo As far as I know, there is no catch on usb keyboards as far as how many buttons you can define.
One other thought as well: can you double up some functionality? (like how the default to exit is start + Select)? You might b able to get away with a "function" button help down along with other presses or joystick input to do the extra functions? I have set up stuff like reset and save states on my playstation gamepad. I am thinking that might work with a USB arcade stick or even a playstation arcade stick with usb adapter (the playstation units usually have start, select, 8 buttons and a stick).
I'm just not sure how to cram everything into a portable package...
-
@diegzumillo - not sure if you have considered this already but what about a Teensy? They arent the cheapest but I'm led to believe that they are fairly easy to configure as a gamepad with all the functionality of a Playstation sixaxis controller (including dual analog) - if you haven't seen it, Check out @TheLuthier 's PiSP project on this forum for a great example of many buttons in a small package. I'm not sure what limitations there are to the total number of inputs but there is a Teensy with extra pinouts available too. They also show up as a keyboard device which saves having to configure custom shortcuts etc.
Out of interest, what games do you need 15 buttons for, or what purpose will you have for that number of inputs? As @mrbwa1 mentioned there are tons of built in shortcuts on Retropie, would you be able to get away with less buttons?
Edit: I just re-read your initial post. I see now that you are after menu options on top of basic joypad functionality. You could wire up custom buttons for save, load etc. and that would be fair enough as a design choice, but you don't necessarily have to, as the newer versions of Retropie have pre defined key presses for all those functions. I.e. Select + L shoulder button for load state, select + R shoulder button for save state, select + left/right D-pad to change save/load slots, select + start to quit game plus a few more i don't really use. Forgive me if you knew this already and I'm being patronising, but you mentioned in another post that you're fairly new to Raspberry pi, so i'm guessing Retropie as well?
Is this the same project you have in mind for the led flashes based on emulator choice? That would be an awsome idea for a portable and I don't think I have seen it done before.
-
Hi Pifan :)
Yep, it's the same project! But as much as I like the idea, things are not looking very promising so far. All solutions available are way too rigid it seems.
I am new to everything here. I did know about the key combination but assuming I don't it's a lot safer :P
I don't really need that many keys though. I do find it more elegant to have a dedicated key for the most used commands like save, load, quit/close and turn on/off. But another way of doing this is taking advantage of the key combination feature and wire a button that triggers the combination internally, no need for messing with software settings. Then I don't need to find a freakish control with more keys than usual.
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.