Design och utvärdering av ett firmware-uppdateringssystem för STM32-baserade industriella styrsystem
2026 (Swedish)Independent thesis Basic level (degree of Bachelor), 10,5 credits / 16 HE credits
Student thesisAlternative title
Design and Evaluation of a Firmware Update System for STM32-based Industrial Control Systems (English)
Abstract [sv]
Industriella styrsystem kräver regelbunden firmware-uppdatering, men fysisk åtkomst till enheterna är ofta opraktisk. Detta arbete designar, implementerar och utvärderar ett remote firmware update-system (RFU) för en STM32F412-baserad styrenhet för kylanläggningar, där uppdateringar sker via RS232. Systemet består av en bootloader med backup-sektor-arkitektur, oberoende watchdog-timer och en uppdateringsflagga i reserverat SRAM, samt en desktopapplikation som hanterar överföringen via YMODEM-protokollet med CRC-16-feldetektering. Robustheten utvärderas genom systematisk felinjicering över åtta testfall som täcker normala uppdateringar, strömavbrott under radering och skrivning, kommunikationsavbrott, korrupta paket, hängande applikationer och upprepade uppdateringar. Samtliga testfall godkänns över totalt 26 körningar, utan att manuell intervention via JTAG krävs i något fall. Resultaten visar att en relativt enkel kombination av backup-region, CRC-validering och watchdog-baserad rollback räcker för att hantera samtliga testade felscenarier inom plattformens single-bank-begränsning.
Abstract [en]
Industrial control systems require regular firmware updates, but physical access to the units is often impractical. This work designs, implements and evaluates a remote firmware update (RFU) system for an STM32F412-based control unit used in industrial chillers, where updates are performed over RS232. The system consists of a bootloader employing a backup-sector architecture, an independent watchdog timer and an update-request flag stored in reserved SRAM, together with a desktop application that handles the transfer using the YMODEM protocol with CRC-16 error detection. Robustness is evaluated through systematic fault injection across eight test cases covering normal updates, power loss during erase and write, communication loss, corrupted packets, hanging applications and repeated updates. All test cases pass over a total of 26 runs, with no case requiring manual recovery via JTAG. The results show that a relatively simple combination of a backup region, CRC validation and watchdog-driven rollback is sufficient to handle all tested failure scenarios within the constraints of the platform’s single-bank flash architecture
Place, publisher, year, edition, pages
2026. , p. 10
National Category
Computer Engineering
Identifiers
URN: urn:nbn:se:liu:diva-225017ISRN: LIU-IDA/LITH-EX-G--26/061--SEOAI: oai:DiVA.org:liu-225017DiVA, id: diva2:2072628
External cooperation
Tark Thermal Solutions AB
Subject / course
Computer Engineering
Presentation
2026-06-01, 11:15 (Swedish)
Supervisors
Examiners
2026-06-182026-06-152026-06-18Bibliographically approved