Firmware Updates Over The Air for LoRa using Random Linear Network Coding

More Info
expand_more

Abstract

LoRaWAN is a public Wireless Sensor network with excellent properties like being long-range, low-energy radios and resulting in long battery life. Devices are connected to this network through gateways, and they will run in that deployment for years without replacement. Therefore, bugs and security issues in such devices' firmware are present for a long time, unless firmware updates are applied to fix them. Firmware-Updates Over-The-Air (FUOTA) is a firmware update application framework for LoRaWAN, but packet loss is an unsolved issue for such firmware updating frameworks. State-of-the-art packet dissemination uses the Low-Density Parity Checks (LDPC), but this has decoding overhead. Also, it is inflexible due to its fixed-rate nature. The code can not be dynamically adjusted to adapt to temporary changes in channel conditions.
In this work, we provide critical analysis to justify replacing Low-Density Parity Checks code (LDPC) proposed in FUOTA with the famous code Random Linear Network Coding (RLNC). The benefit of RLNC shows when scaling to multicast networks using LoRaWAN FUOTA as fewer messages need to be exchanged to serve the complete network of firmware updates. An analysis is presented on how to configure the finite field size, generation size, and redundancy for generation-based RLNC. The parameters are optimized to cope with the worst-case packet-error rate. As such, RLNC can optimally counter every lost packet with redundancy with near-zero decoding overhead. Since devices sleep after decoding a set of fragments, or the generation, sending additional fragments does not decrease efficiency. Finally, the decoding probability is provided as an analytical tool to show that a specific amount of redundancy can deal with a specific worst-case packet-error rate.
To evaluate and test the RLNC code for LoRa, embedded firmware and terminal software have been developed to do indoor and outdoor measurements. This testbed has been developed with a custom control plane replacing all FUOTA MAC layer modules (Fragmentation, Multicast, Synchronization, Device Management, etc.). Therefore, it can be shaped into custom network configurations meant for evaluating the firmware updating process without having to set up infrastructures like ChirpStack or TheThingsStack. Our work's testbed can isolate the decoding process and evaluate it for artificial packet drops.
Results are presented, which show that systematic coding phase of LDPC will perform poorly compared to RLNC. This systematic phase is at least as large as the firmware update. Between 38% to 88% improvement in decoding success is found by using RLNC in case of varying network conditions due to burst loss.