Skip to content

Firmware 1.1.1

Latest

Choose a tag to compare

@LearnWeaver LearnWeaver released this 06 Oct 02:38

Firmware for the BBR Digital Expander. Update if your robot sees I2C dropouts, or the FTC driver logs expander REBOOTED.

What to download

bbr-digital-expander-1.1.1.uf2 — the firmware image. A UF2 is a drag-and-drop format: the board appears as a USB drive called RPI-RP2 and you copy the file onto it. Nothing to install.

Full instructions: Updating the firmware

sha256  68b5d5ae35feba85dff8d5820b5afdf10b2b6c920ed15476f03ffe08e2deab9a

What changed since 1.0.0

Robustness on a noisy bus. Found in robot testing, with motor noise getting onto the I2C cable:

  • No more hangs. Bus noise could make the board freeze for half a second and restart, holding the I2C clock low while it did, which the Hub reports as a stuck bus. Fixed at the cause: the two processor cores could both update an internal counter at the same instant and leave it in a state the I2C handler waited on forever.
  • Recovers from noise in about 1 ms. When a noise spike puts the board out of step with the Hub, it now lets go of the bus within about a millisecond, instead of after 50 ms (often twice).
  • No lost read after a pause. The first read after the Hub had been quiet could be mistaken for a stalled transfer and reset. No longer.

Checksums and diagnostics (protocol 1.2):

  • Encoder and sensor telemetry carries a CRC like the pose already did. The FTC driver checks it, so a reading damaged on the wire is re-read instead of reaching your code looking real.
  • The board reports why it last reset (power-on, watchdog, software) and how often its I2C link has been disturbed. In the FTC driver: readDiagnostics(), with reboots logged automatically.
  • Encoder velocity divides by the window it actually measured, not the nominal one (it read about 4% fast with the default window).

Protocol 1.2 is additive: new registers in previously reserved space, nothing moved. Drivers written for 1.1 keep working. The telemetry checksum and diagnostics are used by the FTC driver today; the Arduino and Python drivers still check the pose only.

Your configuration survives the update

Taught colours, trigger configuration, encoder directions, localizer parameters and PWM calibration are stored in a flash region this image does not reach. Flashing it does not erase them.

Compatible drivers

Platform Driver
FTC (Java) DigitalExpander — this repository
Arduino (C++) DigitalExpander-Arduino
Raspberry Pi (Python) DigitalExpander-Python

All three speak protocol 1.x and refuse to start against a firmware whose protocol major they do not know, rather than reading a register map that may have moved underneath them.

The current FTC and Python drivers also no longer end your program if the robot is bumped during gyro calibration: calibrateGyro() and resetLocalizerAndCalibrateImu() return false and keep the previous calibration.