Blogger and DIYer Paul Rickards wrote about an awesome discovery today: he figured out how to rig an NES controller, via USB, to his iPad. Even better, he made it work like an iCade does, which theoretically opens up the support of his homebrew controller to every iCade-enabled game out there. He hasn't posted the code yet, but he did go over the story of how he made discovery and linked to some pretty important literature.

Like most of the world's greatest inventions, this was the result of an accident. While playing in iMAME, Rickards accidentally pressed some keys on his homebrew Commodore 64 USB keyboard. The app then said it was enabling iCade mode. Cue the "A-ha!" moment.

From here, Rickards manufactured another USB keyboard utilizing Arduino, but instead of using a keyboard matrix, he used his NES gamepad. A couple of legos for casing and two jacks later, he had a working NES controller for his iPad. Sweet!

We've asked Rickards if he intends to do more controllers in the future because this is pretty exciting news. Think about it: someday, you might finally be able to play an iPad game with the Duke, the ultimate gaming controller.

Well ... that is, if every game plays nice. Atari Greatest Hits [Free] collection and iMAME are the only games he's tested so far.

[via biosrhythm]

  • http://twitter.com/aagold3 Aaron G

    That's pretty awesome. I assume you're kidding on "The Duke" though, as that thing, and it's white and black buttons, was an atrocity.

  • Anonymous

    The lego case looks RAD! What a find here to be able to play with the old controller like that! I'd be using it for the ipop touch, though. Considering how many games I have in the imame app and the ones on the Atari app, that would be worth it in itself. Can't wait to find out just how I can do this!

  • http://buzzabit.com/aaron/ Aaron Sullivan

    I don't think there was anything secret about how the iCade works was there? There's a freely available pdf explaining that it works with key presses and exactly what each key press is registered for each button-down or button-up event. Still, it must have been fun to discover it that way and fun to rig that thing up. :)

    From the programmer side of things, I don't get why more devs don't support it. From experience, it's very simple to get the code hooked up (especially when you use MIT-licensed code that is out there already). It took me less than an hour to get basic functionality going and the rest is just choice of how you want it all to work with your game.

    Seriously, if your game is a port of a retro game that used a joystick and buttons or is just arcade-like (shooters and platformers) you should really add support, imo.

    Anyway, it's not a great standard to go forward with unfortunately. It would be SO much nicer if a more flexible bluetooth method could be implemented in the near future (as it seems might be possible with the 4S and later devices).

    • http://twitter.com/paulrickards Paul Rickards

      You're right, the developer PDF is freely available on how the iCade works by using key press events. I used this to map the game pad to the right events.

      What took me by surprise is that it works over USB-- iCade works via Bluetooth. I didn't expect it would work this way but it does. I suppose it's being passed as HID regardless of how it gets there.

      From this point it was a matter of using an Arduino with the V-USB library to speak as a USB keyboard. There are many other projects around that show how to get an NES controller connected to USB with an Arduino. As far as I know, this is the first with iCade support.

      And this only works on the iPad since the Camera Connection Kit doesn't seem to work with the iPhone/iPod Touch.

      • http://buzzabit.com/aaron/ Aaron Sullivan

        Ah! I glossed over that, sorry! Makes much more sense now. 

        That is interesting. In many ways that's handier because, for instance, the iCade has no off switch so you either have to wait for it to give up, or manually disconnect it through the general settings.

        Personal aside: I wish I had more time to tinker around with stuff like this. Still can't make time for my game. Tough to change my situation at the moment. Of course, I'm right in the middle of a ton of work from my day job teaching and that explains why I'm waxing envious here, instead. lol.

      • himanshu modi

        A few complain about the "lag" of iCade, so is this faster over USB?

      • http://twitter.com/albertnahka Albert Nahka

        Perhaps the first time to connect a NES controller over USB with iCade support but I've done this for PS2 controller already some time ago (as a small side project while working on my CoreMIDI based library for proper analog nubs support). See http://www.kotiposti.net/sodacan/coremidi for more details. But more interestingly, I did a custom iCade compatible arcade controller with real coin collector that can function both as a Bluetooth device or a USB device (iCade or CoreMIDI). http://youtu.be/4EP_Ot_52Rs.

  • http://buzzabit.com/aaron/ Aaron Sullivan

    *weird posting error. sorry

  • Anonymous

    I had this exact same idea the other night while falling asleep. Funny how these things happen. Anyway, in my dream product, the converter box would have an LCD display which you could use to scroll through presets which you configure using a computer (I guess you wouldn't really need a computer for this). You could select your favorite button mappings so every game works how YOU think it should.

  • Anonymous

    Being that Apple likes to "do things right," instead of do things first, I'm expecting now that the gaming community is just starting to get a standardized controller format (iCade), Apple, after four years of people complaining for one, will finally introduce an over-priced controller that has less functionality to iCade and other controllers and they'll call it the new standard.

  • http://clickplow.com/ John

    It really wouldn't be hard to hack the icade unit and connect just about any digital joystick. I'm sure guys like ben heck could even do it with xbox 360 and ps3 controllers.

    • http://twitter.com/Neomatt Matthieu Dietrich

      Actually, Ben Heck himself did it not so long ago: http://revision3.com/tbhs/iphonecontroller

      As for the mod itself, very good find (one of those "well yes, it should work!" moments), but my only gripe with using iCade-mode is that, as far as I know, you can only use one controller per device.

      I'd kinda wish for a SNES multitap (BT or USB), that would be the bee's knees. No idea how it could work though. :(

  • http://twitter.com/Zpiders Zpiders

    Can't we use a bluetooth gamepad on an ipad? I have an andorid tablet and the PS3 controller works great on it, very easy to setup as well.