Getting Started
Quick start
- Install PinballCTL on the Pi
- Connect to the Pi over SSH
- Connect or flash the ESP32-S3
- Set up and test your first switch
- Run on a Mac or see the Windows options
What you need
To get PinballCTL running, have a Raspberry Pi 5 with Raspberry Pi OS 64-bit, a suitable power supply, network access, a browser and a Pi terminal. You'll also need an ESP32-S3 and a USB data cable when you're ready to connect the controller.
You can install and run PinballCTL before wiring any inputs. A single supported input, such as a switch, lets you see your first hardware event and try a rule. Check your board’s pin map and voltage limits before wiring it.
For development, you can also run PinballCTL directly on a Mac. This lets you build rules, set up scoring and preview displays before moving your project to a Raspberry Pi.
1. Prepare and reach the Pi
- In Raspberry Pi Imager, choose your Pi model and Raspberry Pi OS 64-bit. Configure your own username, network and SSH access before writing the card.
- Boot the Pi, then sign in at its console or use SSH with the hostname/address and username you configured.
- Open a terminal and run
python3 --version. The application requires Python 3.11 or later.
Expected result: you can run commands on the Pi. If you cannot connect, confirm the Pi address at your router or local console. Do not assume every installation is named raspberrypi.local.
2. Install PinballCTL
Run on the Pi in a directory where you have not already installed the project:
sudo apt update
sudo apt install -y python3-venv python3-pip git
git clone --branch main https://github.com/pinballctl/pinballctl.git
cd pinballctl
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install -e .
pinballctl --version
pinballctl start
pinballctl status
Expected result: installation succeeds and status shows the web process and its address. A missing bridge/device is expected until the controller is connected.
If installation fails, keep the error message, check Python and network access, and use Detailed setup. Do not install a second copy over an existing running service.
3. Open the application and secure access
- Find your Pi’s IP address on the Network line of
pinballctl status. On a device connected to the same network, open a browser and enter the address withhttp://before it and:8888after it. For example, if your Pi’s IP address is192.168.1.50, enterhttp://192.168.1.50:8888. - Sign in. The source defaults are username
adminand passwordpasswordon an unconfigured installation. Saved or environment-provided credentials can override them. - Open Settings → Access, set your own credentials and choose Save Changes. Verify the new login before relying on unattended access.
Expected result: the dashboard opens and your new credentials work. If the interface is unreachable, check pinballctl status and the port. The systemd web service uses 8000. Run one mode at a time.

If the installation was successful, opening the URL in your browser should show the PinballCTL login screen.
4. Connect and check the ESP
- Disconnect power to coils and other high-current outputs before connecting the ESP32-S3 with a USB data cable. Leave that power disconnected through the switch and rule tests.
- Open ESPLink and check live connection status, controller identity and firmware information.
- If the board is blank or needs an update, download the image for your board in Firmware, then flash it from ESPLink. After the board reconnects, check the firmware version before deploying configuration.
Warning. Flashing replaces the program currently on the ESP32-S3. Files and settings from an existing project on the board may also be lost. Back up anything you want to keep before flashing.
Expected result. The ESP should show as connected and report the uploaded firmware version. If it does not show as connected, check the cable, serial port, permissions and bridge status. A charge-only USB cable will not work.

Screen guide: check the connection state first, then identity and version.
5. Setting up your first input
- Open Hardware, then Reload Pins with the ESP connected.
- Identify your safely wired input from its board/channel and UID. Give it a friendly name such as Test target and select the matching input function. Check polarity and supported input options against the circuit.
- Choose Save Changes, then Sync to ESP. Wait for the reported result.
- Open Logs, select the event log and operate the switch once. Record the actual event name and source UID. Confirm a release event as well when that input type provides one.
Expected result: the event identifies your input and occurs when you operate it. If silent, check the live connection, pin identity, input polarity, saved mapping and sync result before creating a rule.

Screen guide: board/channel identifies the physical connection; the UID identifies it to rules. Friendly names make the same device easier to find elsewhere.
6. Create and test a safe rule
- Open Rules → Add Rule and name it Test target in Metadata. Keep it enabled.
- In Triggers, choose the actual hardware source and event observed in step 5. Leave Conditions empty for this first test.
- In Actions, choose the System event action (Fire Event / Emit Event), set Event Type to Custom and enter
TEST_TARGET_SEENas its event name. Do not select a pulse, output, coil or existing gameplay event. Check that no other rule listens for this new name. - Review Summary, correct validation errors, then Save. Check sync status and use Sync to ESP when required for deployed behaviour. The custom event action runs on the Pi, so the application and bridge must remain running.
- Operate the physical switch once and find both the original input event and
TEST_TARGET_SEENin the event log.
Expected result: the custom event follows your switch event without energising an output. If it does not, check the exact trigger/source, enabled state, saved rule, validation and sync status. Do not use the custom result event as its own trigger: that would create a loop.

What next?
Keep the test rule clearly named, or disable it after testing. Create and download a backup, then learn Rules, Lighting or Audio. Use Troubleshooting when the observed result differs from the expected result.
Detailed setup
Outcome and prerequisites
For the Raspberry Pi setup below, you’ll need a Raspberry Pi 5, a suitable power supply, a microSD card (32 GB recommended), network access, Raspberry Pi OS 64-bit and Python 3.11 or later.
For development, you can run PinballCTL directly on a Mac with Git and Python 3.11 or later. You can build rules, set up scoring and preview displays before connecting an ESP32-S3 or moving your project to a Raspberry Pi.
When you’re ready to connect the controller, use an ESP32-S3 and a USB data cable. You can install and run PinballCTL before wiring any inputs. For your first hardware test, use one supported input and check your board’s pin map and voltage limits before wiring it. See Supported Components for the scope of hardware testing.
Diagram guide: the Pi hosts authoring and host services; the ESP handles physical I/O and output safety limits.
1. Plan the electrical boundary
- Identify the Pi supply, controller supply and load supplies from your actual design.
- Disconnect coil/high-current output power before wiring. Check input voltage limits and grounding against the board and driver documentation.
- Keep coils, motors and lamps off GPIO. Use suitable drivers, fuses and flyback protection for the actual loads, plus a physical means to disconnect output power.
Expected result: a powered Pi/ESP can be tested without energising a high-current output. If you cannot identify the power and driver arrangement, stop the output setup and resolve the circuit first. Firmware arming, watchdogs and pulse limits are additional safeguards, not replacements for electrical design.
2. Write the SD card and start the Pi
- Install Raspberry Pi Imager on your computer. Insert the microSD card. Check its name and size before selecting it because writing the image erases that card.
- In Imager choose your Pi model, Raspberry Pi OS (64-bit), and the microSD card. Open the OS customisation options. Set a hostname such as
pinball-pi, create a username and password, and configure your Wi-Fi if you are using it. Enable SSH if you plan to connect without a monitor. Save the settings and write the card. - Eject the card, put it in the Pi and power the Pi on. The first boot can take a few minutes. Connect Ethernet if you have not configured Wi-Fi.
- For a local console, connect a monitor and keyboard. Sign in with your Pi username and open Terminal from the desktop menu. If you installed Raspberry Pi OS Lite, the login prompt itself is the console.
Connect by SSH for the first time
SSH opens a terminal on the Pi from another computer. On macOS open Terminal from Spotlight. On Windows open PowerShell or Windows Terminal. On Linux open Terminal from the applications menu. Put both devices on the same network.
Run the command below with your own username and hostname. The examples use the username builder and hostname pinball-pi.
ssh builder@pinball-pi.local
If the hostname does not resolve, use the Pi’s network address from your router’s connected-devices list. With a keyboard and screen on the Pi, hostname -I also lists its addresses. For example, if the Pi is at 192.168.1.50, run ssh builder@192.168.1.50.
- On the first connection, SSH may ask whether you trust the host key. Verify it is your Pi before accepting. From the Pi’s local console you can run
ssh-keygen -lf /etc/ssh/ssh_host_ed25519_key.pubto compare the ED25519 fingerprint when that key type is shown. - Type the Pi account password when prompted and press Enter. The terminal hides each character as you type.
- A prompt such as
builder@pinball-pi:~ $means you are on the Pi. Runhostnameandpython3 --versionto check where you are and that Python is at least 3.11. To disconnect, typeexit.
Run the install commands below after the Pi prompt appears. Copy the command text without a leading prompt, press Enter and wait for each command to finish. sudo requests administrator privileges and may ask for your Pi password again. If a command fails, stop and read its error before continuing.
3. Install a recorded development revision
Run on the Pi, outside any existing project checkout:
sudo apt update
sudo apt install -y python3-venv python3-pip git
git clone --branch main https://github.com/pinballctl/pinballctl.git
cd pinballctl
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install -e .
pinballctl --version
pinballctl --help
Expected result: the command-line tool runs from this checkout's virtual environment. If the pinballctl command is missing, activate this checkout's .venv and check the installation error rather than installing globally.
The Godot host project is available under src/pinballctl/runtime/godot in the checkout and ships in the Python package. Display playback needs a compatible local Godot executable and display environment. Follow Media and Godot when you reach that stage.
4. Start manually for the first test
From the checkout with its environment active:
pinballctl start
pinballctl status
pinballctl start starts the web interface and the Godot supervisor in manual mode. It also starts the serial bridge at 460800 baud when it detects an ESP32-S3. If the ESP32-S3 is unplugged, startup skips the bridge and you can still sign in and use the web interface.
To manage just the web interface in manual mode, use pinballctl start --web-only, pinballctl reload --web-only or pinballctl stop --web-only. These commands leave the serial bridge and Godot supervisor alone. For systemd operation, see step 9.
- Use
pinballctl statusto check which processes are running and find the Pi’s IP address on the Network line. The output also lists detected serial ports and log locations. - On a device on the same trusted network, open the Pi’s IP address in a browser using the default manual port 8888. For example, if the Pi’s IP address is
192.168.1.50, enterhttp://192.168.1.50:8888. - Sign in using your installation's credentials. An unconfigured source installation defaults to
admin/password; saved settings andPINBALLCTL_USER,PINBALLCTL_PASSWORDor hashed-password environment settings may override them. - Open Settings → Access, save your own credentials and verify them in a fresh login.
Expected result: the dashboard loads and access uses your own credentials. Keep the interface on a trusted network. If unreachable, check address, port, process status and network/firewall rules.

Screen guide: the login protects the application; changing the Pi operating-system password does not change this application login.
5. Connect the ESP and verify compatibility
- Keep output power off and connect the ESP32-S3 with a USB data cable. If the previous manual start skipped the bridge, run
pinballctl startagain to detect the controller and start the bridge. - Open ESPLink and verify live connection state, controller identity and firmware information. Cached identity alone is not a live connection.
- If the board is blank or needs an update, use Firmware to download the image for your board. Then follow the flashing steps in ESPLink and check the reported version after the board reconnects.
- If disconnected, check cable, the detected serial device, bridge logs and Linux device access. Recheck after reconnecting.
Expected result: the bridge exchanges live status with the intended ESP. Stop here if compatibility or transport errors remain. Communication is framed JSON; serial terminal text commands are not a supported configuration method.

Screen guide: inspect connection state before relying on the identity/version fields. Use the detailed connection guide for no-device and reconnect states.
6. Map and observe a physical input
- Open Hardware → Reload Pins with the controller connected.
- Match the input's UID, board and channel to your wiring. Give it a meaningful friendly name and choose its input function.
- Open its settings where available and check polarity, pull configuration and supported debounce/gesture options against the circuit. Do not unhide reserved pins just to obtain more outputs.
- Choose Save Changes, then Sync to ESP. Wait for completion and inspect any error.
- Operate the input once and use Logs to confirm the actual event name and source. Confirm press/release or open/closed behaviour appropriate to the input.
Expected result: the physical input produces the intended event without false repeats. If silent or inverted, check pin identity, voltage/polarity, saved mapping, sync and connection before changing a rule. Use Hardware and Events in Logs to investigate.

Screen guide: use board/channel and UID together. The friendly label helps authoring but is not an electrical pin specification.
7. Build the first rule
Follow Quick start step 6: create Test target, use the observed input trigger and fire a distinct Custom event named TEST_TARGET_SEEN. Leave conditions empty initially; validate, save, review sync status and operate the input again.
Expected result: the log shows the input and derived event. Check exact event/source, enabled state, validation and saved configuration if it fails. Keep the Pi running: host event, state, scoring and media actions require it. Review Rules before adding conditions or output actions.
8. Configure an output only after the input test
- Keep load power disconnected while identifying the output UID and driver circuit.
- Configure the correct output function, polarity and safe state in Hardware. For a coil, configure pulse/hold/cooldown limits appropriate to its specifications and driver.
- Save and sync, then inspect the resulting status. Verify physical power removal and fault behaviour before any powered test.
- Perform a controlled hardware test only when you can safely observe and stop it. Recheck arming, watchdog and maximum-on behaviour on the actual Pi/ESP.
Expected result: the output has explicit limits and a known safe state. A successful save or preview is not a powered safety test. Do not choose example pulse times or hold duty values from screenshots: they may damage a different coil.
9. Choose service operation when ready
On Linux with systemd, install the services from the checkout with its virtual environment active:
pinballctl stop
pinballctl service install --user "$(id -un)" --workdir "$PWD" --venv-bin "$PWD/.venv/bin"
pinballctl status
systemctl status pinball-web.service pinball-runtime.target
Installation requires sudo. It enables and starts the web service and runtime target. If the older bundled pinball.service is installed, installation stops and disables it before starting the new units. The web service listens on port 8000. The service user needs access to the checkout, project data and serial device. Media requires a suitable display and audio environment.
Use pinballctl service stop web to close the admin listener while keeping the ESP bridge and Godot supervisor running. Use pinballctl service start web to reopen it. To keep the web service off at boot as well, use sudo systemctl disable --now pinball-web.service. The runtime handles Godot scene events, leaderboard requests and initials entry while the web service is stopped.
The runtime selector manages the bridge and Godot supervisor together. The bridge selector controls the serial bridge. The all selector controls both the runtime and web service. Reload sends Gunicorn a worker reload and restarts the selected active runtime units.
In a systemd installation, use the bridge service selector for serial process control. Stop the bridge through systemd before firmware upload or restore, and start it again after maintenance succeeds.
Check the web service and both runtime members with pinballctl status. On failure, inspect the component logs and the relevant unit in journalctl.
10. Record data locations and recovery
In this editable checkout, managed project data lives in src/instance/. It includes mapping, rules, media and audio data plus protected local settings. Do not replace it by extracting arbitrary ZIP files. The Backup / Restore library normally lives outside it at ~/.local/share/pinballctl/backups/, or the configured XDG/dedicated backup directory under the service user's account.
- Create an Everything backup and download an off-machine copy after the first working setup.
- Record how PinballCTL starts, its web port, the firmware version and the log locations.
- Before upgrades or recovery, stop gameplay and playback, preserve data and follow the backup guide. Never assume a restore automatically syncs the ESP or arms outputs.
Expected result: you can identify what is installed and recover project content without losing credentials or accidentally publishing old hardware configuration.
Troubleshooting and next steps
Use Troubleshooting for UI access, ESP offline, silent inputs, failed rules or missing assets. Keep one-input tests small: changing wiring, mapping, firmware and rules together makes faults harder to isolate.
Next: Interface Tour, Rules Wizard, Lighting, Audio, Media. Physical Pi/ESP installation, power-loss and coil safety checks remain target-hardware work; desktop documentation checks cannot verify them.
Run directly on a Mac
Open Terminal on the Mac. Check git --version and python3 --version. Install Git and Python 3.11 or later if either is missing. Run these commands in a folder where you keep projects:
git clone --branch main https://github.com/pinballctl/pinballctl.git
cd pinballctl
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install -e .
pinballctl start --host 127.0.0.1
pinballctl status
Open http://127.0.0.1:8888 on the Mac. Set your own application login under Settings → Access. When you are finished, run pinballctl stop from the active environment. In a new Terminal window, return to the checkout and run source .venv/bin/activate before using the CLI again.
Use an appropriate USB data cable if you attach an ESP32 for bench development. The systemd installer and Pi Wi-Fi controls are specific to Linux. For actual Godot playback, install a compatible Godot executable separately. See the Development Platform notes for the Mac development setup.
Windows, WSL and Docker
The easiest Windows setup is to run Pinball CTL on the Pi and use a browser on Windows. Use Windows Terminal or PowerShell for the SSH steps above.
If you want the development app to run on the Windows computer itself, WSL 2 with Ubuntu is an experimental option. Pinball CTL does not ship a native Windows build or a supported Docker image.
- Follow Microsoft’s WSL installation guide to install WSL 2 and Ubuntu. Open Ubuntu from the Start menu and create the Linux account when prompted.
- In Ubuntu, check
python3 --version. Use a distribution with Python 3.11 or later. Run the Linux install commands above from your Ubuntu home directory (cd ~), then runpinballctl start. Openhttp://localhost:8888in the Windows browser. - Start with browser authoring and simulation. An attached ESP32 needs separate USB forwarding through Microsoft’s USB/IP instructions. That controller path, display and audio output, and cabinet operation have not been verified here.
A Linux virtual machine is another experimental way to try authoring. Docker Desktop requires a custom container and separate handling of persistent project data and devices. Its USB/IP setup depends on the backend and device. For a machine that will control physical coils, use the Raspberry Pi setup and verify the actual hardware there.