Repository navigation
v2.5.3 — Decoupling GPIO Relays
Relay GPIO is now supplied by the device (v2.5.3)
The extension no longer hard-codes any hardware GPIO. Previously the Mini-PoS
relay pin — and the Identity-Login / NFC-Tag fallback pin — were fixed to a
specific GPIO number in the extension code. When the ZapBox Touch 3.5 channel
layout was re-mapped (the primary channel CH01 moved to GPIO 14), Mini-PoS
stopped switching: the server kept sending the old, now-wrong pin.
The device is the only component that knows its own GPIO layout, so it now tells
the server which relay pin to fire:
- Mini-PoS: the device sends its primary-channel pin in the
POST /zapbox/api/v1/pos/invoicebody ("pin": <gpio>). It is stored with the
invoice and echoed back over WebSocket on settlement. - Identity-Login / NFC-Tag: the
pin/auth_pinquery parameters are now
required (the device already sent them) instead of falling back to a hard-coded
default.
A future re-map of the channel layout needs no server-side change — the
extension holds no GPIO knowledge at all.