Raspberry Pi game cabinet, made for CPSC 3340 Creative Embedded Systems
- Raspberry Pi Zero 2 W, headerless
- ESP-WROOM-32
- SD card
- Small touchscreen for Raspberry Pi Zero
- Short MtM microUSB cable
- Breadboard-layout PCBs
- Joystick (x2)
- Push button (x2)
- Flip switch (x2)
First, you have to solder your RasPi Zero to the small display. Solder all the pins; I found that it's much easier if you create an electrical connection between the pins and the holes before soldering by bending them slightly so they touch the copper rings. This makes it so that both the pins and the holes get heated and the solder can flow between them.
The joysticks you can get on Amazon come pre-installed with MtM headers. We need to remove these.
The best way to do this is to separate the headers by crushing them with some piliers, then applying heat and pulling them out one by one. Note that if you apply heat while pulling with the pliers, the pliers will act as a heat sink, so apply heat then apply pliers.
Then, you can solder your own wires to each of the four pins to be used: GND, 5V, VRY, and VRX. Make sure to use long enough wires.
OnShape CAD available here.
Also see STL files in /cad
Follow this guide to install boot media onto an SD card for Raspberry Pi Zero.
On the SD card, follow manufacturer's instructions to add the drivers to the Pi, so it displays to the screen upon bootup.
At this point, you can boot up the Pi; if you need to register your device on the Yale network you can get the MAC address by doing ifconfig.
Once the Pi is connected to the Internet, you can get the IP address, SSH in, and add your SSH key.
You can then clone this repo, set Git to store your credentials, and log in with a Personal Access Token.
I also recommend adding an authorized SSH key.
Sensor data is sent from the ESP32 to the Raspberry Pi over USB serial. Right now, data is being sent as ASCII (although in the future we could change this to raw binary data).
2048/2048/2048/2048/1/1/0/0
Where the numbers are delimited by slash (/). Each number represents:
- Player 1 joystick X
- Player 1 joystick Y
- Player 2 joystick X
- Player 2 joystick Y
- Player 1 button
- Player 2 button
- Player 1 switch
- Player 2 switch




