Home/Hardware/GX5s/Provisioning
Provisioning

Zero-touch provisioning

No broker and no credentials in the firmware: each device gets its login over the air the first time it connects.

Provisioning sequence between the device and the broker: announce, login sent, reconnect with the stored login, telemetry GX5s Broker 1 · announce (anonymous) 2 · login + location 3 · reconnect with stored login 4 · telemetry

No broker and no credentials are compiled into the GX5s firmware. Each device gets its login over the air the first time it connects.

How it works

  1. Announce. A new device connects anonymously to a bootstrap broker and announces itself on discovery/<id>, with its firmware version.
  2. Login. Your backend replies on device/<id> with a broker login and configuration, such as its location and CAN setup.
  3. Reconnect. The device applies the configuration and tries the new broker straight away. It stores the login only if that connection succeeds; otherwise it goes back to the broker it came from and reports the failure.
  4. Run. From then on it connects with its stored login and publishes under device/<id>/<location>/.

The same message re-provisions a device that is already in service. If a device can't reach its stored broker several times in a row, it checks in with the bootstrap broker once, then tries its stored broker again. The stored login is never erased by this.

Security

  • Authorisation is enforced by the broker: broker permissions decide who may send commands to a device.
  • TLS runs in the modem and authenticates the broker.

Factory reset

Five resets in a row (reset button or power cycle), each within about five seconds of the previous boot, erase the stored login, the CAN setup and the offline queue. The power LED blinks five times and the device starts unprovisioned.

Source: firmware decisions (ADR 0001) in the gx5s repository.