Added setup folder with needed launch files - Update when new version is ready
This commit is contained in:
1 parent
91b7840535
commit
0dcada4db2
50 files changed
+3753
-11
No files matched your search
@@ -155,12 +155,66 @@ $env:ARCADE_CABINET_TOKENS = '{"cabinet_01":"your-generated-cabinet-one-token","
|
||||
py -3 tools/room_controller/server.py --bind 0.0.0.0 --database arcade_room.sqlite3
|
||||
```
|
||||
|
||||
Keep the database at a stable location and back it up. Allow TCP **8766** through the controller machine's firewall for the room LAN. Keep real tokens and deployment databases out of source control.
|
||||
Keep the database at a stable location and back it up. Allow TCP **8766** through the controller machine's firewall for the room LAN. The assigned internal tokens are documented in the [cabinet setup guide](docs/cabinet_setup.md), as requested for this installation. Keep deployment databases out of source control.
|
||||
|
||||
Open `http://CONTROLLER_IP:8766/` on the staff computer or iPad and enter the operator token. The iPad needs only a browser. Use a trusted isolated LAN; the default HTTP connection is not encrypted. See the [deployment guide](tools/room_controller/README.md) for network and credential details.
|
||||
|
||||
## 5. Connect cabinets to the controller
|
||||
|
||||
### PC versus Pi: which configuration file?
|
||||
|
||||
`arcade_network.cfg` configures a **Godot client**, not the Python controller. Its contents depend on the role that Godot runs in, not just the operating system.
|
||||
|
||||
| Machine / role | Where settings belong | Credentials |
|
||||
| --- | --- | --- |
|
||||
| PC running the Python controller + browser | `tools/launch/launcher.ini`, `[controller]` | `operator_token` and JSON `cabinet_tokens` for all cabinets |
|
||||
| PC running the optional Godot `--operator` app | `user://arcade_network.cfg`, `[network]` | `url` and `operator_token` |
|
||||
| Pi running a managed cabinet | `user://arcade_network.cfg`, `[network]` | `url`, its own `cabinet_id`, and its own `cabinet_token` |
|
||||
| PC running a game as a test cabinet | Same cabinet fields as the Pi | That test cabinet's ID/token; do not duplicate an active Pi's ID |
|
||||
|
||||
**For the normal browser-operator setup, the PC does not need an `arcade_network.cfg`.** Enter the operator token in the browser; the server takes its credentials from the launcher/environment.
|
||||
|
||||
Example Pi Godot configuration:
|
||||
|
||||
```ini
|
||||
[network]
|
||||
url="http://WINDOWS_PC_IP:8766"
|
||||
cabinet_id="cabinet_01"
|
||||
cabinet_token="CABINET_01_TOKEN"
|
||||
```
|
||||
|
||||
Optional PC Godot operator configuration (only for `--operator`, with the controller on that same PC):
|
||||
|
||||
```ini
|
||||
[network]
|
||||
url="http://127.0.0.1:8766"
|
||||
operator_token="OPERATOR_TOKEN"
|
||||
```
|
||||
|
||||
The Pi's URL must use the **PC's LAN IP**, never `127.0.0.1` unless the controller actually runs on that Pi. Both client roles use controller port **8766**. GPIO port **8765** is separate and stays local to the Pi.
|
||||
|
||||
Godot CFG strings require double quotes. Launcher INI scalar values are unquoted; the `cabinet_tokens` JSON object still uses JSON quotes.
|
||||
|
||||
When using the scripts, nonempty `[cabinet] url` and `token` values in `launcher.ini` override Godot's CFG. Existing `ARCADE_ROOM_URL` / `ARCADE_CABINET_TOKEN` environment values override those launcher values. Leave the INI URL/token blank to fall back to the CFG, and clear stale environment variables if needed. The scripts always pass their configured `[cabinet] id` (default `cabinet_01`) as `--cabinet`, overriding the CFG's ID: set the correct ID on every Pi even when using the CFG for its token.
|
||||
|
||||
### Generate a 16-character token
|
||||
|
||||
These are application authentication tokens, not SSH keys. Generate a separate token for each cabinet and for the operator:
|
||||
|
||||
```powershell
|
||||
# Windows
|
||||
py -3 -c "import secrets; print(secrets.token_urlsafe(12))"
|
||||
```
|
||||
|
||||
```sh
|
||||
# Pi / macOS / Linux
|
||||
python3 -c "import secrets; print(secrets.token_urlsafe(12))"
|
||||
```
|
||||
|
||||
Each command produces exactly 16 URL-safe characters. Preserve capitalization and any `-` or `_`, including a trailing hyphen. Restart the affected controller/client after changing credentials.
|
||||
|
||||
The supplied internal token assignments, complete controller configuration, and individual Cabinet 1–7 examples are in the [cabinet setup guide](docs/cabinet_setup.md). Use those assigned tokens for the current installation; generate new ones when provisioning additional identities or deliberately replacing a token.
|
||||
|
||||
On each cabinet, create **arcade_network.cfg** in the application's Godot user-data directory:
|
||||
|
||||
```ini
|
||||
@@ -226,6 +280,8 @@ The sample [proof_of_concept](data/scenarios/proof_of_concept.tres) connects a P
|
||||
|
||||
The older `-- --operator` Godot mode remains available for Cabinet 01 quick controls. Use the browser interface for multiple cabinets and the room map.
|
||||
|
||||
For a sequential two-Pi test, choose **Cabinet 1 -> Cabinet 2**: winning Pac-Man on the first cabinet loads and automatically starts Galaga on the second. See the [chain-test walkthrough](tools/room_controller/README.md#two-pi-chain-test-cabinet-1-wins---cabinet-2-starts).
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
| Symptom | Check |
|
||||
|
||||
Reference in new issue
Block a user