Homemade Handheld Console

About the project

A step by step guide for building your own handheld gaming console using a raspberry pi.

Project info

Difficulty: Moderate

Platforms: Raspberry Pi

Estimated time: 1 day

License: GNU General Public License, version 3 or later (GPL3+)

Items used in this project

Hardware components

Raspberry Pi 3 Raspberry Pi 3 x 1
3.2", 240x320 pixels, slim Intelligent Display Module powered by Espressif ESP8266 SoC built-in Wifi and Resistive Touch panel 3.2", 240x320 pixels, slim Intelligent Display Module powered by Espressif ESP8266 SoC built-in Wifi and Resistive Touch panel https://www.ebay.com.au/itm/New-3-2-Inch-TFT-LCD-Module-Touch-Screen-For-Raspberry-Pi-B-B-A-Raspberry-Pi-3/132155850204?_trksid=p2485497.m4902.l9144 x 1
Lithium Ion Polymer Battery 3.7V 1200mAh Lithium Ion Polymer Battery 3.7V 1200mAh https://www.ebay.com.au/itm/3-7V-2200mAh-604070-Lipo-Polymer-Battery-Li-ion-cells-For-DVD-mobile-phone-PAD/182547941591?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m1438.l2649 x 1
SD/MicroSD Memory Card - 16GB Class 10 - Adapter Included SD/MicroSD Memory Card - 16GB Class 10 - Adapter Included https://www.ebay.com.au/itm/Micro-SD-Card-SanDisk-16GB-32GB-64GB-128GB-256G-Ultra-Class-10-Memory-A1-100Mb-s/142588279477?hash=item2132ec7ab5:rk:1:pf:0&var x 1
M3 Standoffs and Screws Kit M3 Standoffs and Screws Kit https://www.ebay.com.au/itm/120Pcs-270Pcs-Male-Female-Brass-Standoff-Spacer-PCB-Board-Screws-Nut-Assortment-/182252373605?oid=252610183264 x 1
Zero Delay USB Encoder Zero Delay USB Encoder https://www.ebay.com.au/itm/Zero-Delay-Arcade-USB-Encoder-PC-to-Joystick-MAME-5Pin-Sanwa-Push-Button-W-Cable/282567160546?_trksid=p2485497.m4902.l9144 x 1
Round Tactile Button Switch 15 pack Round Tactile Button Switch 15 pack https://www.ebay.com.au/itm/12x12x7-3mm-Momentary-Tactile-Push-Button-Touch-Micro-Switch-4P-PCB-w-Cap-25-Pcs/142464665944?_trksid=p2485497.m4902.l9144 x 1
90 by 150mm Proto Board 90 by 150mm Proto Board https://www.ebay.com.au/itm/1Pcs-9-x-15-cm-DIY-Prototype-Paper-PCB-fr4-Universal-Board-prototyping-pcb-kit/232450480977?_trksid=p2485497.m4902.l9144 x 2
USB OTG Cable- Fem. A to Micro B - 5in USB OTG Cable- Fem. A to Micro B - 5in https://www.ebay.com.au/itm/30cm-Short-Right-Angle-90-2A-Micro-USB-Quick-Charger-Charging-Sync-Data-Cable-/222970239226?oid=282881205736 x 1
3.5mm Mini Speaker 3.5mm Mini Speaker https://www.ebay.com.au/itm/Mini-Portable-3-5mm-Pillow-Speaker-For-MP3-MP4-CD-iPod-Phone/263268728929?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m1438.l2649 x 1
Rocker Switch Rocker Switch https://www.ebay.com.au/itm/10pcs-lot-Black-10-15mm-2PIN-ON-OFF-Boat-Rocker-Switch-Car-Dash-Dashboard-Truck/272917309673?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m1438.l2649 x 1
PowerBoost 500 Recharge 5V Lipo PowerBoost 500 Recharge 5V Lipo https://www.ebay.com.au/itm/1PCS-5V-Micro-USB-1A-18650-Lithium-Battery-Charging-Board-Charger-Module-new/152942011024?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2060353.m1438.l2649 x 1

View all

Software apps and online services

Retropie 4.4 Retropie 4.4 https://retropie.org.uk/download/
SD Formatter SD Formatter https://www.sdcard.org/downloads/formatter_4/
Win32 Disk Imager Win32 Disk Imager https://sourceforge.net/projects/win32diskimager/
WinSCP WinSCP https://winscp.net/eng/download.php
PuTTY PuTTY https://www.putty.org/
Case 3D Model Case 3D Model https://cdn.instructables.com/ORIG/FIY/JF4Y/JO8XSKJD/FIYJF4YJO8XSKJD.obj & https://cdn.instructables.com/ORIG/F4Y/QA0B/JO8XSKJE/F4YQA0BJO8XSKJE.obj

Hand tools and fabrication machines

Soldering iron and thin solder Soldering iron and thin solder x 1
Heat shrink tubing Heat shrink tubing x 1
Hot glue gun Hot glue gun x 1
Stanley knife (box cutter) Stanley knife (box cutter) x 1
Pencil Pencil x 1
Small phillips head screwdriver Small phillips head screwdriver x 1
SD card reader SD card reader x 1
Wire cutters/strippers Wire cutters/strippers x 1
HDMI cable HDMI cable x 1
USB wall charger USB wall charger x 1
Spare micro USB cable Spare micro USB cable x 1
Computer monitor with HDMI input Computer monitor with HDMI input x 1
USB keyboard USB keyboard My recommendation: https://www.ebay.com.au/itm/2-4GHz-Mini-Wireless-Keyboard-Mouse-Air-Mouse-Touchpad-for-PC-Smart-TV/382433701575?_trksid=p2485497.m4902.l9144 x 1

View all


Step 1: What You Will Need

The following is a list of tools and equipment you will need for this project. The prices of these items is in Australian dollars and the links provided are for what I used in my project. If you do not live in Australia, you may find better sellers/prices for these items.


Raspberry Pi 3 $70 [LINK]

3.2 Inch TFT LCD $17 [LINK]

3.7V 2200mAh Lipo Battery $15 [LINK]

16GB Micro SD Card $10 [LINK]

M3 Standoffs and Screws Set $7 [LINK]

Zero Delay USB Encoder $5 [LINK]

Tactile Buttons $4 [LINK]

2x 90 by 150mm Proto Board $2 [LINK]

Short Micro USB Cable $2 [LINK]

5V Micro USB Charging Board $1 [LINK]

3.5mm Mini Speaker $1 [LINK]

Rocker Switch $1 [LINK]

TOTAL ~$135


Soldering Iron and thin solder

Heat shrink tubing

Hot glue gun

Stanley Knife (Box Cutter)

A pencil

Small Phillips head screwdriver

SD Card reader

Wire cutters/strippers

HDMI Cable

USB Wall Charger

Spare micro USB cable

Computer Monitor with HDMI input

A USB keyboard [I recommend this one]

(Optional) 3D printer


Retropie 4.4: [LINK]

SD Formatter: [LINK]

Win32 Disk Imager: [LINK]



(Optional) Case 3D Model:

Step 2: Installing Software

Download all of the software using the links in the software section. Once you have downloaded and unzipped all of the software, insert the micro SD card into your computer using a card reader.

Once the SD card has been recognised run SD Formatter.

Double check that the Drive selected is definitely your SD card and that it does not contain anything important. This step will erase everything on the SD card perminently.

Select options and change the format type to FULL (Erase) and turn on format size adjustment, then click ok and Format.

Once the SD card has been formatted, run Win32diskimager. Select the Retropie image file, make sure the device is set to the SD card and click Write and then Yes. This will take a few minutes.

Once the image has been written to the SD card, insert the SD card into your raspberry pi. Attach the 3.2 Inch LCD Screen to the raspberry pi by lining up the far right pins on the console with the mount on the back of the screen. Connect a moniter to the pi using an HDMI cable and power in using a USB wall charger and micro USB cable. Also be sure to connect a USB keyboard to one of the pi's USB slots.

The software will take a couple of minutes to initialize and reboot. Once this process is done you should see the device configuration screen. If not, try unplugging your keyboard and plugging it in again.

Enter in the inputs you would like to control the software. Keep in mind that 'A' is to select items in the menu, 'B' is to go back, start is to open up the menu and the hotkey will be used with a combination of other keys to save, load, restart and exit out of games that are running.

Once you have configured your controls, navigate to the configuration menu and then to the RASPI-CONFIG option.

Once in this menu, select 'Localization Options', then select 'Change Wi-Fi Country' and select your country.

Then back in RASPI-CONFIG menu, select 'Interfacing Options', then SSH. Press tab to select 'YES' then hit enter to enable SSH.

Once again back in the RASPI-CONFIG menu, navigate to 'Advanced Options' and select 'Expand Filesystem. This will take a few seconds.

Once you have completed these steps, exit the RASPI-CONFIG menu and reboot the pi when prompted.

After the device has rebooted, enter the 'Configuration' menu again and select 'WIFI'. Select 'Connect to WiFi Network' and select the network you would like to connect to. Enter your password and the pi should connect to your Wi-Fi network.

Exit back to the 'Configuration' menu and select 'SHOW IP.

The screen should now display the IP address of your raspberry pi that you can use to remotely access your pi from your computer.

Step 3: Installing Drivers and Boot Config

Run PuTTY on your computer and enter in the raspberry pi IP address into the Host Name section. Click yes to acknowledge that you trust the IP address entered.

You will then be prompted to login. The default login credentials will be

Username: piPassword: raspberry

Once these credentials have been entered, you can now start modifying the pi. The first step is to download the drivers that will allow the 3.2 inch screen work.

Type the following commands; I recommend copying and pasting them into PuTTY using ctrl+C and right click.

git clone  https://github.com/swkim01/waveshare-dtoverlays.gitsudo cp waveshare-dtoverlays/waveshare32b.dtbo /boot/overlays/

Now to edit the boot config file:

sudo nano /boot/config.txt

Delete the # before disable_overscan=1 and set it to


Then delete all the #'s before the overscan values and set them all to -20


Delete the # before hdmi_force_hotplug=1


Navigate down to hdmi_mode=1 and delete the # before it. Underneath this line type hdmi_mode=87:


Next we will overclock the pi and adjust the settings to maximize performance.

WARNING: Changing some of these settings may void warranty and may cause your raspberry pi to overheat. I have used the following settings for a long time now and haven't had any issues but I can't guarantee the safety of your raspberry pi.

Navigate down to the arm_freq=800 line, remove the # and change the value to 1200. Add the following lines so it looks like this:


Next remove the # in front of


Navigate down to the bottom of the file and add the following two lines:


Hit CTRL+X to exit the config file and hit 'Y' when prompted to save the changes. Hit Enter when prompted for what file name to write.

Now reboot the raspberry pi by typing the command:

sudo reboot

Once the pi has rebooted, run PuTTY again (the last session will disconnect) and enter in the IP address again. This IP might change, so double check it by navigating back to the 'SHOW IP' screen in the retropie configuration settings.

Once PuTTY is connected again, login using pi/raspberry and enter the following command:

ls /dev/fb* 

you should see dev/fb0 /dev/fb1

if you don't see /dev/fb1 , something has gone wrong and you will need to format the SD card and start again

If you do see dev/fb0 /dev/fb1, enter the following commands one at a time, giving sufficient time for each step to complete:

sudo apt-get install cmakegit clone https://github.com/tasanakorn/rpi-fbcpcd rpi-fbcp/mkdir buildcd build/cmake ..makesudo install fbcp /usr/local/bin/fbcp

Now we need to edit one more file. Enter:

sudo nano /etc/rc.local

Navigate down to the line above “exit 0” and enter the following:

/usr/local/bin/fbcp &

Save the file by hitting CTRL+X, Y, then Enter.

Now reboot the device using:

sudo reboot

When the pi reboots, the touchscreen should now be displaying Retropie. No need for an HDMI monitor anymore!

Step 4: Installing ROMS

Before building the enclosure for your raspberry pi, it is worth testing out the software by installing ROMS.

I won't go into detail as to how and where to get game ROMS as there are many ways of obtaining them which vary in legality. Once you have sources some game ROMS, here is how to remotely install them onto your raspberry pi.

Turn the pi on by plugging it into the USB wall charger and wait for it to boot up.

Next run WinSCP

Type in the IP address into the Host name section

Enter 'pi' for the username and 'raspberry' for the password. It's worth saving this configuration so you don't have to type it in every time.

Click on 'Login' and click 'Yes' if the software askes you to remember this key

The ROMS are kept in /home/pi/RetroPie/roms

There needs to be a folder here for each system you want to emulate. There should be some folders already here by default.

Some systems like the PSX require BIOS files, which need to be sourced and placed in the BIOS folder.

Now you need to copy your game ROM files into their respective folders by either dragging them in or via Ctrl+C and Ctrl+V.

Click OK to begin the transfer.

This may take a while depending on what ROMS you are transferring and how many. I recommend transferring ROMS in batches. This way if the connection drops out you don't have to start all over again and if you reboot after uploading a couple of ROMS you can actually play them while doing another transfer without interrupting it.

Once the transfer has successfully completed, click the terminal option on the toolbar and enter the command:

sudo reboot

Once the pi has rebooted you will now be able to test games using the keyboard or by connecting a USB controller and configuring its inputs. At this point you can use your raspberry pi as a miniature retro games console, either by propping it up somewhere or connecting it to your TV.

Step 5: Building the Enclosure: Buttons!

Next we will start to build the enclosure for the raspberry pi to sit in and connect the buttons, speaker and power supply to turn it into a portable gaming device.

First we need to cut a hole in one of the proto boards to pass the LCD mount through and hold the screen in place.

Line up the screen in the center of the proto board and as close to the top without obstructing the holes in the corners which you will need to screw in the spacers for holding the back piece on. If you've purchased the boards in the equipment list of this tutorial, the lcd mount will line up with rows 19 to 22 and rows C to P.

Using a pencil, trace around where the mount touches the board and mark the lines clearly.

Using a stanley knife, cut out the marked area. This make take a while and could blunt your stanley blade, so if you think you have a more appropriate tool, feel free to use it, just be careful not to crack or snap the board. Do not cut any further than you need to.

Once you've but out the hole, pass the LCD mount through it to see if it fits. It should be as snug as possible to avoid the screen moving around.

Next mark out where the bottom of the screen lines up on the board so that you know how much space you have to place the buttons

Open up your tactile switch set and start placing the switches on the board. You will need 4 on the upper left for up, down, left and right, 4 on the upper right for A, B, X and Y and 3 along the bottom for START, SELECT and your Hotkey/Home Button. I had to space the vertical buttons slightly farther apart than the horizontal buttons which wasn't ideal but after using the console for a while I'm used to it and it isn't as unusual as I thought it would be.

If you would like to have shoulder buttons like R1, R2, L1 and L2, add 4 more switches to the other proto board. This step is optional if you want to keep the console size small and only want to play games that don't require shoulder buttons (remember that the super nintendo has shoulder buttons!)

These buttons need to also be below the bottom of the screen as this is where the bottom of the raspberry pi will sit on the other side. How far in from the sides you place these buttons is up to you depending on what is most comfortable.

Now to flip the board over to start soldering. Make sure all the buttons are pushed down, flat on the board and that their pins are all protruding through and not bent underneath them. Once the iron is hot, add a little bit of solder to two vertically aligned pins on every button. This will help hold the buttons in place and make it easier to connect the wires.

With the main 8 buttons on the front board, add solder to the pins that are furthest from the center. This is to allow space for the speaker.

Next, grab the wire connectors that came with the Zero Delay USB encoder and solder each of the wires on a connector to each of the pins on a button. Repeat this until you have soldered a connector for every button on both boards.

Step 6: Speaker Installation

Once all of the connectors are in place, you can now place the speaker. This step is optional if you do not want a speaker and are happy to connect earphones to the audio jack.

Pop open the white plastic case on the speaker and place it face down on the back of the proto board that has the main face buttons. Using a hot glue gun, glue the speaker down insuring that none of the soldered wires are touching any metal parts of the speaker.

Step 7: Connect the USB Encoder

Next we need to connect all the buttons to the USB encoder. The encoder has 4 specific slots for up, down, left and right and a slot for the USB cable. The rest of the buttons can be connected to any of the slots on the bottom row. The connectors should click in place with a little push.

Once all the buttons and USB cable are connected, glue the USB encoder onto the bottom board, just bellow the connections to the shoulder buttons and just above the holes in the bottom corners of the proto board.

Now place the LCD screen through the hole in the top board and connect the raspberry pi to it from underneath. Feed the 3.5mm audio cable over the top of the pi so that it can access the audio jack.

Fold the two boards together so that all the wires are contained between the two boards and connect the USB cable to the raspberry pi.

Connect the raspberry pi to the USB wall charger to turn it on and wait for it to boot up. Connect your keyboard again so you can navigate to the controller configuration screen. You may find it easier to read the screen if you connect your monitor to the pi via HDMI again.

Configure the buttons you've installed to test that they are all working. If a button is not detected while trying to configure, you may have to re-solder that particular button.

If all the buttons are detected, maybe try out a game for a bit to fully test the buttons.

Step 8: Battery Power

Next we need to set up the battery recharge circuit to make the console portable and re-chargeable.

Solder the red wire from the battery to the B+ terminal on the recharge circuit board and the black wire to the B- terminal.

WARNING: Double check before soldering or you could short out the recharge board or zap yourself.

After the battery is connected to the recharge board, we need to connect the micro usb cable. To do this we must cut the large USB end of the cable off with wire cutters. Feel free to shorten the cable if needed but keep in mind that it must reach from the bottom of the proto board all the way up to the top to connect to the raspberry pi power input. Strip back the rubber on the cable to reveal the two wires inside.

Solder the red wire to the OUT+ terminal on the circuit board and the black cable to the OUT- terminal. Again be very cautious when doing this.

You can solder the power directly to the raspberry pi board but I was not comfortable doing this so I instead opted to just have a usb cable plugged in. This is where a 90 degree angled, micro USB cable is nice (link in the equipment section) as it hides under the proto board nicely.

To test the connection, plug the micro USB cable into the raspberry pi. If the battery has charge, the pi should boot up. Connect your USB wall charger to a spare micro USB cable and connect this to the micro USB slot on the recharge circuit. The LED on the chip should light up red while charging and blue when at full charge.

If the pi powers up and the led on the circuit lights up to show that it is charging, you're ready to move onto the next step.

Step 9: Soldering the Encoder Directly to the Pi (Optional)

The next step is optional as it requires you to semi-permanently connect the controls to your raspberry pi. If you're thinking of using the pi for other projects and swapping it in and out of the gameboy configuration, skip this step.

First, you need to cut the USB connector off using wire cutters and strip the rubber back to reveal 4 wires; black, green, white and red. These wires are for Ground, Data +, Data – and VCC respectively.

Next you need to solder each wire to the configuration in the attached image.

WARNING: This action will definitely void warranty and runs the risk of killing your raspberry pi.

Step 10: On/Off Switch

The console should now work perfectly fine, to turn it on however, you'll need to plug the micro USB into the power socket of the pi and unplug it to turn it off. An on/off rocker switch makes this process a bit nicer. Attaching one is fairly simple if done carefully.

We need to cut a section of the thick rubber casing off the cable close to the micro USB end. If done carefully we can expose all 4 of the USB wires without cutting any of them. If you do cut them, no stress, you'll just have to solder them back together. The only wire we need to cut is the red one. Once the red wire is cut and stripped back, solder one end to one of the metal pins on the rocker switch and the other end onto the other pin.

Step 11: Gluing and Screwing It All Together

Glue the battery down on the bottom board between the USB encoder and where the pi will sit. Next, glue the recharge circuit to the under side of the top board. I found the bottom left side to be the best spot for this. Make sure it is close enough to the edge to easily attach a cable.

Glue the on off switch to the underside of the top board. I found that the top right corner is a good spot.

Before screwing everything together, run the 3.5mm audio cable and the micro USB cable coming from the recharge circuit over the top of the pi, on the left side of the IO pins.

Screw in the 20mm spacers to the bottom using the nuts found in the spacer kit, then line up the top board and screw the top board to the spacers using the M3 screws. Be sure to fold as many of the cables in between the two boards as you can, without damaging anything.

Step 12: (Optional) 3D Printed Case

Congratulations!Assuming everything went well with your build, you now have a working, portable, rechargeable retro console. Not only can you now play your favourite old-school games on the go but you can also plug the console into your TV and connect a wireless controller to use it as a mini console.As well as creating this tutorial, I have designed a case for this console that can be 3D printed and put together to give it a much more professional and comfortable look and feel.

Download the models at the top of this tutorial to 3D print yourself or send to a 3D printing vendor.

The case should clip together over the console and still leave space to connect power, controllers and an HDMI cable.

To secure the case even more, replace the female to male spacers with female to female and connect 10mm female to male spacers on the top board, and female to male 5mm spacers on the bottom board. Now you can use the M3 screws to attach the case to the spacers through the holes in the corners of the case.

CAD, enclosures and custom parts

Case Back


Leave your feedback...