DEV Community

drflamemontgomery
drflamemontgomery

Posted on

Raspberry Pi Zero W Network Game Controller Hub

After several weeks of searching. I finally discovered how to turn a Raspberry Pi Zero W into a USB controller.

Hardware

raspberry pi zero w

Software

raspbian-jessie-lite
raspbain-jessie
Warning Don't update your version of raspbian-jessie.

Instructions

  1. Flash raspbian-jessie or raspbian-jessie-lite onto your raspberry pi zero w.

  2. Connect to the wifi

  3. Run wget -o https://github.com/drflamemontgomery/RaspberryPiZero-Controller/archive/refs/heads/main.zip

  4. unzip RaspberryPiZero-Controller-main.zip

  5. mv RaspberryPiZero-Controller-main/* ./

  6. chmod +x setup.sh
    sudo ./setup.sh
    chmod +x hid.sh
    gcc -o tcp tcp.c -lpthread

  7. Add lines from /home/pi/rc.local to /etc/rc.local before exit 0

  8. ifconfig
    find your ip address. format is usually 192.168.1.xxx or 10.0.0.xxx

  9. shutdown

  10. plug your raspberry pi zero w into a device of your choice using the OTG usb port

You should now have a raspberry pi zero w acting as a network controller hub on address IP_ADDR:8080. You should now be able to connect up to 4 devices and use them as controllers.

Connecting

You can either program your own software using specifications from https://github.com/drflamemontgomery/RaspberryPi0ControllerPDF/blob/main/Raspberry_Pi_Controller.pdf or you can download https://github.com/drflamemontgomery/rpicontroller

Top comments (0)