L337Snowman
Posts: 12
Joined: Wed Dec 19, 2012 12:23 pm

USB Gamepad

Wed Dec 19, 2012 12:37 pm

Over the past few days, I have been experimenting with my Raspberry Pi quite a lot. I finally managed to get the Quake 2 and Cave story binaries to work, both running at quite reasonable frames. I recently had an idea ( :idea: ): I wanted to make a portable Raspberry Pi ROM emulator/gaming device. I was going to use a 3.5 inch monitor:

Image

A Rii Mini Keyboard:

Image

And also some sort of gamepad. I recently had a trip to Japan, where I fortunately had the chance to go to a massive electronics store in Akihabara. I purchased a gampad that was designed to look like a Famicom controller:

Image

It works all well and fine with my Windows 7 PC using Joy2Key. I decided this was going to be the gamepad used in my portable Raspberry Pi device. I plugged it into the Pi and it seemed to recognise it. I ran some input tests through the terminal, and each of the buttons worked fine. Then the trouble started. I was looking online for a linux keyboard-to-gamepad mapper sort of thing. I searched for hours and hours and tried every single one that I could find, but all of them had errors compiling, e.g. rejoystick, joy2key, qjoypad. Please help me, I am desperate to start playing Cave Story with this thing! I also want to use the D-Pad as a mouse, if that is at all possible. It would save a lot of space on my portable device.

Regards, Snowman

SSilver2k2
Posts: 179
Joined: Wed Jun 06, 2012 1:51 am
Location: United States
Contact: Website AOL

Re: USB Gamepad

Thu Dec 20, 2012 3:32 am

have you tried doing a:
sudo apt-get install joy2key

it seems to already be in the repos.
My blog of various geeky things - http://blog.sheasilverman.com
PiPLAY - http://piplay.org
DeskCade.com - Mini Raspberry Pi Arcade Cabinet

L337Snowman
Posts: 12
Joined: Wed Dec 19, 2012 12:23 pm

Re: USB Gamepad

Thu Dec 20, 2012 3:43 am

SSilver2k2 wrote:have you tried doing a:
sudo apt-get install joy2key

it seems to already be in the repos.

trying it now. also, i have a little problem where when i boot up the pi, i cant get into the lxde through startx without putting sudo in front.

L337Snowman
Posts: 12
Joined: Wed Dec 19, 2012 12:23 pm

Re: USB Gamepad

Thu Dec 20, 2012 12:39 pm

SOLVED!!!!! I might write up a solution later but right now I have to go to bed. Thanks for everything Shea!

moocow1452
Posts: 26
Joined: Wed Apr 04, 2012 10:03 pm

Re: USB Gamepad

Sat Dec 22, 2012 8:10 pm

Do tell...

L337Snowman
Posts: 12
Joined: Wed Dec 19, 2012 12:23 pm

Re: USB Gamepad

Fri Dec 28, 2012 3:28 am

moocow1452 wrote:Do tell...
Okay, sorry for the super super late reply, I have been on holidays. It ended up being a really simple fix, all I had to do was install some packages with "sudo apt-get install". Here is a list of them:

libxtst-dev
qt4-dev-tools
g++

I tried this solution before on the first raspbian image that was released and it didn't work. I then accidentally corrupted the sd card to the point of no boot, as I was fiddling with boot options, trying to get certain things to happen on boot. I downloaded the newest image and put on a clean formatted sd card and tried the solution again and it worked.

User avatar
winkleink
Forum Moderator
Forum Moderator
Posts: 279
Joined: Mon Nov 07, 2011 9:12 am
Location: UK
Contact: Website

Re: USB Gamepad

Fri Dec 28, 2012 10:19 am

Just wondering what your set up is.
I'm running a Raspberry Jam on the 20th of Jan in Egham, Surrey (More info and registration link: http://www.raspberrypi.org/phpBB3/viewt ... 57&t=26309) and was thinking a game set up on a big screen would be a fun thing to have in place.
Not very geeky but would definitely draw the crowds (hopefully)

So, just wondering how you have things set up to make sure I get it all sorted for the 20th Jan

Thanks,
Albert.
Twitter:Winkleink
Google+: Winkleink

Return to “Troubleshooting”