The web page¶
Every TriggerGate server, whether a Windows PC, an Advantech UNO or an ESP32 board, serves the same web page. It shows the state of the service and of every input as it happens, runs faceoffs and test triggers, changes the device's settings, and opens the diagnostic tools. It runs entirely in the browser and talks to the server through the same hub a show-control application uses, so what it shows is what any client sees. This page walks through every part of it and links to the pages that explain each feature in depth.
Opening the page¶
| Server | From the same machine | From another computer, tablet or phone |
|---|---|---|
| Windows service | http://localhost:9090/ |
https://<host>:9190/ |
| Advantech UNO | https://<host>/ |
|
| ESP32 board | https://<host>/ |
From another computer the page needs HTTPS: it is a WebAssembly application that browsers run only in a secure context. A plain HTTP address from another computer takes you to the server's certificate page, which installs the certificate and leads on to the secure address. How to do that on each kind of computer and phone is in Open the web page over HTTPS.
The page follows the browser's light or dark setting.
Address options¶
The page's address can carry options in its query string:
| Option | Effect |
|---|---|
?platform=XKeysWindows (or AdvantechWindows, Uno) |
Connects to that platform on a server that runs more than one. |
&device=1 |
Connects to that device of the platform, numbered from 0. |
?hubPort=8123 |
Connects to the hub on that port of the same host instead of the usual one. For use behind a proxy that serves the page and the hub on one port. |
Choosing a platform in the page sets the first two for you. See Connecting to a platform and device.
Header¶
The header shows:
- TriggerGate and a version label: the platform the page is connected to ("Advantech", "X-keys", "Uno" or "ESP32") followed by the page's own version. Click the version for the About dialog, which also shows the server's version and build date.
- Host: the name of the machine or board serving the page.
- A connection label: Connected, Reconnecting or Disconnected.
While the connection to the server is down, the page is covered by a notice that says what is happening. It reconnects by itself when the server comes back; if the connection closes for good, the notice asks you to reload the page.
Service panel¶
Platform¶
On a server with more than one platform or device, for example a Windows PC with an Advantech card and two X-keys keypads, the Platform choice lists them all: "Advantech", "X-keys: XK-24" and so on, with "(not connected)" and a dimmed label for an X-keys device that is not plugged in. Choosing one reloads the page connected to it. The choice is hidden when there is only one.
Status¶
The status tree has a light and a line of text for each part. The color is always repeated in words.
| Entry | What it shows |
|---|---|
| TriggerGate | The overall state of the page's connection and the device. |
| Connection to TriggerGate | The page's connection to the server. |
| GPIO System | The device's own state, in the server's words, for example the card or keypad in use and how many inputs it has, or why it is disconnected. |
| Wall clock | The quality of the server's clock and its estimated error, such as "NTP, within 3 ms": green when disciplined with a known error, amber when free-running or of unknown error, red for a minute after the clock stepped, gray when the server reports no clock. Hover for the time source, the last step and the device's ordering resolution. Below it, the server's current UTC time, advanced in the browser from the last sample, and on servers that report them, the latest NTP observations with a Clock diagnostics section. |
| Faceoff synchronization (PTP) | ESP32 only. Whether the board is locked to a PTP grandmaster, with the grandmaster identity, domain, timescale, the scheduling error bound, servo observations under Clock diagnostics, and the current PTP time. A board needs PTP only for scheduled faceoffs; local faceoffs work without it. |
What the clock entries mean, and how to get a green light, is in Clocks and time.
Secure access and certificate¶
The link Secure access and certificate opens the server's certificate page in a new tab. Use it to install the certificate on another computer or phone, or to find the secure address. See Open the web page over HTTPS and HTTPS settings and your own certificate.
Inputs panel¶
One tile per input the device has, numbered from 0. Each tile shows the input number and its level in words:
- high or low: the level the server last read by polling.
- out: the input is the device's status output pin (on the UNO and ESP32, where outputs and inputs share pins).
- A lightning bolt, drawn dim, on every input that can raise hardware interrupts. It flashes each time an interrupt is reported for that input. The bolt shows at a glance which inputs can take part in an interrupt faceoff.
The legend above the tiles explains the colors and the bolt. With no device attached the panel says "No inputs reported yet." The tiles redraw at most ten times a second, however fast edges arrive.
Commands¶
The command buttons appear while the page is connected.
| Button | What it does | More |
|---|---|---|
| Start faceoff | Opens a dialog to choose the participants and the kind of edge, then starts a faceoff. | Triggers and faceoffs |
| Prepare faceoff | The same, with a lockout time, to start a pre-faceoff. | Pre-faceoff lockout |
| End faceoff | Ends the current faceoff or pre-faceoff at once. | |
| Trigger random | Sends test edges on chosen inputs at random times. | Below |
| Identify | Flashes the device's status output, or on an Advantech card its locate indicator, for half a second, so you can see which device you are connected to. On X-keys and the UNO it fails, with "No valid output LED is configured" or "No valid output pin is configured", while no status output is assigned in Settings. | Platforms and devices |
| Input diagnostics | Opens the per-input counters, and from there the button health check. | Below |
| Settings | Opens the device's hardware settings. | Below |
| Shut down | Asks for confirmation, then shuts the device down. | Below |
The result of every command is written to the log, for example "Start Faceoff (edges = Polling) OK", or "Fail" with the server's reason, such as the inputs that were held down.
While a button health check runs on the device, from this page or any other client, a banner at the top says how many inputs are being watched and how long the check can still run. Start faceoff and Prepare faceoff are unavailable until it ends, and the device refuses faceoff requests, test triggers and settings changes.
Start faceoff and Prepare faceoff¶
The dialog has:
- Inputs: one toggle per input. The page remembers your last selection in this browser and offers it again; with nothing remembered, every input is selected.
- Edges: on a device with inputs that raise interrupts (an Advantech card), the switch Faceoffs use polling. Off, interrupt edges decide, and every selected input must be able to raise interrupts or the request is refused. On, polled edges decide; every input supports them, but they are seen up to one polling interval late. The page remembers the last choice. On a device without interrupt inputs the dialog says "Faceoffs use polling" and offers no switch; on an ESP32 that still means interrupt-stamped entries (see Platforms and devices).
- Lockout (seconds), for Prepare faceoff only: 0 to 60, default 2.
The web page always treats a rising edge as the press, and attaches no trigger actions. A show-control application can choose the press edge per input and attach actions.
Trigger random¶
Trigger random checks the path from TriggerGate to its clients without anyone pressing a button. The dialog has:
- Inputs: the inputs to trigger, all selected at first.
- Trigger edge: for each selected input, whether its first test edge is rising or falling. The opposite edge follows 0.2 seconds later.
- Timing spread: a minimum and maximum delay, from 0 to 4 seconds. The dialog starts at 2 to 4 seconds; this is the web page's own default, and a .NET client that does not set a window uses 1 to 4 seconds. Each input fires once at a random time in that range.
The server then sends every client of the device test edges for those inputs, as if they had been pressed at those times. Test edges are marked Test in the log, carry places in the order they fire, and never reach the hardware or a real faceoff. On the Windows service and the UNO, a second after the last one, the server sends the inputs' real levels again. A new request is refused while a sequence is still running.
Input diagnostics and button health check¶
Input diagnostics shows a card per input with its level, how long it has had that level, its accepted edges, the time since the last one, how many quiet windows accepted edges opened, how many observed edges were suppressed, and any queue overflows. Every detected change, including one suppressed from reporting, also updates the input's 200 ms press history; these counters do not enumerate every change. The dialog refreshes every second. It is available on Advantech cards and the ESP32; other devices say it is unavailable. See Input diagnostics.
Its Button health check button opens the guided, timed test of the buttons themselves: you choose the buttons to test, press, hold and release each one as the dialog instructs, and get a finding for each button with a timeline of every change, which you can export as JSON. The button is disabled, with the reason, on devices that cannot run the check. See Button health check.
Settings¶
The Hardware settings dialog shows only the sections the device supports:
| Section | Devices | Fields |
|---|---|---|
| Outputs | All | Status output pin: which output confirms input activity and flashes on Identify, or Unassigned. On X-keys the choices are the keypad's red and green lights; on the UNO and ESP32 they are pins, and a pin used as an output cannot also be an input. An Advantech card has no outputs. |
| Input mapping | ESP32 | Logical input 0 to 7: the GPIO pin each input reads, or Unassigned. A pin can be used only once. See ESP32 input wiring. |
| Clock | UNO, ESP32, Windows | NTP server where the device sets its own (the ESP32, and the UNO when its system allows it): a host name or address; blank uses the platform's default. On Windows a note says that Windows manages the clock. On the ESP32 a note says that PTP follows a master it discovers on domain 0 and needs no NTP setting: the NTP server sets only the wall clock. See Clocks and time. |
| OSC playback defaults | Windows, UNO, ESP32 | Destination, Source subnet, Test OSC address and Send test OSC. The test address must start with /, contain no control characters, and be at most 256 UTF-8 bytes; blank uses /triggergate/test. The test button uses the current unsaved address, while Save persists it per device. This address affects the test button only, not faceoff action addresses or RunOsc packets. On ESP32, OSC is sent over IPv4 Ethernet. See Trigger actions. |
Save applies the settings to this device only and writes "Settings updated successfully." to the log; problems are shown in the dialog before you can save. An ESP32 accepts new settings only while no faceoff or pre-faceoff is armed.
Shut down¶
After you confirm, the UNO powers off and the ESP32 stops until it is reset or powered again. The Windows service refuses the command, and the log shows the refusal.
Log¶
The log lists edges, command results and errors, newest first. Each row has the time in your browser's local time (hover for the date), an icon for its kind (rising edge, falling edge, success, failure, error) and its details. An edge row shows the input number and chips:
| Chip | Meaning |
|---|---|
| Interrupt or Polled | How the edge was detected. |
| A trophy and 1st | The faceoff winner. |
| A broken trophy and 2nd, 3rd, … | Later places in the faceoff. |
| ≈ before a place | A tie: "Too close to call: the order was drawn at random". A row already in the log gets the mark when its partner arrives. |
| A timer and a time | The faceoff time of the entry. |
| A lock and Penalty for | A press during a lockout, with the lockout time remaining. |
| Test | A test edge from Trigger random. |
A faceoff the server canceled appears as "Faceoff cancelled:" with the reason.
The log keeps the latest 200 rows; when there are more, the heading says "latest 200 of" the total. Clear log empties it. The log belongs to this page: it starts empty when the page loads and is not shared with other viewers.
Download device log… appears on devices that keep their own log. It opens a dialog that downloads any part of the device's log as a text file: choose a range in your local time (or a preset such as the last 15 minutes) and the lowest level to include. See Device log.