Runtime Firmware Update for 32-Bit Microcontrollers with Instruction Cache Under Concurrent Task Execution
Smart sensor devices increasingly require remote firmware updates to deploy new functionality, security patches and algorithmic improvements without interrupting services. Runtime firmware updates remain a significant challenge in embedded sensing systems, particularly in real-time and high-availability applications where service interruption and system reboot are undesirable. This paper presents an innovative runtime firmware update mechanism for 32-bit embedded systems architecture and integrated with a custom Runtime Scheduler (RTS). The proposed approach enables dynamic Flash Program Memory (FPM) reprogramming without reboot while preserving concurrent task execution, making it suitable for intelligent sensors and edge-based IoT devices requiring continuous operation. Three update granularities, application, function and row levels, were implemented and experimentally evaluated. Reducing update granularity significantly decreased both system downtime and update data size. For the demonstration update developed to validate the concept, function-level updates reduced the transmitted patch size to approximately 35% of the data that would have been required for the equivalent application-level update, while row-level updates reduced the maximum continuous system unavailability time to approximately 16 ms by distributing FPM write operations across multiple RTS cycles. The mechanism also incorporates instruction cache invalidation, dynamic task validation and fault recovery procedures. Experiments using an intelligent power quality monitoring sensor testbed demonstrate its feasibility while improving availability, reducing update overhead and maintaining operational continuity.
Authors
- Bernardino Pinto Neves (ORCID: https://orcid.org/0000-0002-9018-5859)
- António Valente (ORCID: https://orcid.org/0000-0002-5798-1298)
- Victor D. N. Santos (ORCID: https://orcid.org/0000-0002-5441-4394)
- José Eduardo G. Oliveira (ORCID: https://orcid.org/0000-0001-7723-4989)
Institutions
- Instituto de Engenharia de Sistemas e Computadores Investigação e Desenvolvimento (PT)
- University of Trás-os-Montes and Alto Douro (PT)
- Polytechnic Institute of Coimbra (PT)
- Institute for Systems Engineering and Computers (PT)
- University of Coimbra (PT)
Publication Details
- Journal
- Sensors
- Published
- 2026-09-14
- DOI
- https://doi.org/10.3390/s26185813
- Primary Topic
- Parallel Computing and Optimization Techniques
- Type
- article
- Field-Weighted Citation Impact
- 0.00