Project GamePi: Raspberry Pi Based Portable Game Console

Hi!

DSC_3044

 

Hope you’re well. In this weeks episode of ‘Weird Electronic Devices You Can Make In Your Own Home’, we’ll be diving into a Raspberry Pi based handheld inside of a Game Boy (DMG). My inspiration to pick this one up was seeing the awesome SuperPiBoy,  as well as the wonderful PiGRRL from Adafruit. I took bits from both of those projects, and added my own small touch.

Parts:

My little bit of spice for this project were the additional 3 controls on the rear panel. Instead of using momentary switches,  I used capacitive touch sensors. I chose the standalone versions that Adafruit sells, because the form factor is favorable to this application, and for simplicity.

I started with a trashed original Game Boy. I found it in a lot buy with a broken Game Gear (I can see another project in my future… :)) for 15$. I handed off the internals to a chip tune obsessed friend, and began the conversion.

I chose not to retain any of the original parts, except for the plastics. I first measured the LCD window, and shaved it to the appropriate size for the 3.5 inch LCD. I shaved down as much of the internal plastics as I could. I then mounted the LCD in place with hot glue. The KB button PCB mounts using the original mounting hardware, no modification required.

DSC_3008

With that done, I soldered a ribbon cable onto the button PCB, and removed the 12v -> 5V regulator from the LCD PCB. I found a datasheet for the regulator on my board, but your results may vary. Apparently, there are many revisions of this device. Here’s a link to a thread which speaks out the conversion in detail (Thanks SuperPiBoy). You can see where I soldered on to the 5V OUTPUT pad on the chip footprint in the photo. Worst case, you can search the board for a chip that has 12V on one pin, and 5V on another, it is likely that’s the chip that needs to be removed.

DSC_3028

The LCD PCB ends up being slightly too large to fit into the case, but can be safely shaved down without having to move any traces. If you needed to keep going with the shaving, the buttons can be moved easily.

DSC_3007

With that done, the Mini USB breakout gets mounted where the old power switch was. It’s the perfect footprint for that spot, and with a tiny bit of shaving, gets supported by the plastic standoff post in that corner.

  • The USB 5v and GND output get tied to the LiPoly Charger 5V and GND.
  • The Charger BAT and GND get tied to the respective V+ and GND on your battery of choice. (Please though, only use LiPoly with the LiPoly charger, obviously.)
  • Pass the V+ from your battery through your SPDT switch, and then along to the PowerBoost V+ input.
  • GND on the battery can go straight to the PowerBoost GND.
  • 5V Output from the PowerBoost goes to the TP2 pin on the Raspberry Pi, and PowerBoost Output GND goes to TP1 pin on the Pi.

Congrats! Your Pi is powered. Your LCD board will also need 5V output from the PowerBoost, as well as the three capacitive sensor boards and audio amplifier.

DSC_3016

DSC_3017

DSC_3023

After a significant amount of shaving of the rear case, I was able to mount all of the aforementioned electronics. The chargers and power input devices are mounted on the recessed area of plastic for the cartridge. The capacitive pads are underneath the label area of the rear plastic. I mounted a female USB port where the old Link port was, and the SPDT switch where the volume knob used to be. I hotglued my snazzy Kitch Bent battery cover in place, and cut it’s locking tab to save space.

DSC_3020

I drilled holes in the center of the cap-pad plastics, so there can be a tactile feeling when searching for the buttons on the rear case. I also used a significant amount of nuts/bolts and standoffs to hold everything in place solidly, so the rear case is littered with bolts in different areas. I used a “Cell” format battery, so that it would sit nicely on the bottom of the case. The battery I chose also has an in-circuit thermal cutoff, so if there’s a problem charging it, it will (hopefully) prevent serious damage/fire. I cut the “fuel gauge” board off of the cell, as I didn’t need it.

DSC_3025

DSC_3026

DSC_3021

For the Raspberry Pi, I removed the Audio Jack, Composite Jack and relocated the USB port. Being a Model A, it did not have the Ethernet jack or second USB port. I soldered wires onto the respective areas to pull the signals I needed. Take care when soldering to the Composite Video pads, as it’s easy to damage the Pi’s composite output with too much heat. For the audio, I routed the Audio Jack output direct to the headphone port, as well as to the amplifier board. Since I did not have a “switched” variety headphone jack around for this project, I came up with the following arrangement. When booting, the Pi runs a program to check the state of the 3 Cap Pads. If they’re all HIGH, it will boot into “Headphone Mode” and drive the Shutdown pin on the amplifier board, freeing the headphone jack. For the speakers, I stuffed a set of Macbook (3Ohm) speakers into the area where the old GB speaker used to be. I tied them to the outputs on the amp board.

I trimmed down the GPIO pins down to half height, and soldered the Common Ground PCB and OUTPUT pins (from the cap-sensors) to their respective BCM GPIOs. I then cleaned up the wiring with a couple of wire ties, and routed the wires as best I could.

DSC_3033

DSC_3036

DSC_3035

And, that’s it!

As far as software goes, running on a Model A means that running RetroPie 2.0+ is out of the question (as ES 2.0 is apparently more graphically intense, and requires a 256/256 GPU split). I loaded RetroPie 1.10 onto a high speed SD card, and shimmed in my custom bits of software to glue everything together. Cave Story runs great! 😀

 Post-Mortem:

When shaving the case down to fit the LCD, I neglected to do something about the standoffs for securing the two halves of the case together. This lead to complications at the very end of the project, because there was no reliable way to join the halves together. I fixed this by hot gluing a bolt down in two corners of the case. I then fed a machine screw up into the case, and into the bolt. My screws ended up being the perfect length to pull the bolt, without going all the way through. It hurts the project’s aesthetics, as it’s clear the halves no longer join seamlessly, but it has an acceptable amount of mechanical strength.

The Capacitive Sensors are HIGH when active, and LOW when dormant. The opposite is true for the Common Ground Button PCB, which (when the internal pullups are activated) are HIGH when dormant and LOW when active. This lead to complications using Retrogame (the Adafruit C utility used to convert the physical button presses into keyboard events), as the ‘always-active’ buttons would pin it. I’m in the process of writing a program that is compatible with mixed button conditions, and will update this post when I push it to my git.

DSC_3042