Background
The PlasFit system consists of an ESP32-based master unit, connected to the server over Wi-Fi, and dozens of STM32-based slave units that communicate with it over LoRa. About 150 units are already deployed in the field. Until now, every firmware change required a physical visit to each unit.
The challenge
- A slow, limited channel: LoRa at 917 MHz, with a 1% transmit-time limit under Israeli regulations.
- Fixed hardware: not a single pin may change, because new boards must run the same firmware as the boards already in the field.
- Small memory: 128 KB of flash, with no external memory.
- No bricked units: an update that fails halfway must not leave a dead device in the field.
What we designed
- Memory map: a small bootloader, a region for the active firmware and a separate region for the new firmware. The bootloader copies the new version only after a full CRC32 check.
- Broadcast to everyone at once: the master transmits the firmware to all units in parallel, and each unit reports which parts it is missing. Then only the missing parts are re-sent.
- Staying within the transmit limit: a transmission rate planned in advance to stay under 1%.
- Gradual rollout: one unit for a full work cycle, then a group of 5, and only then all the rest.
The result
A complete, documented design that allows the whole fleet to be updated remotely, with no hardware change and no field visits.