Reliability, power and security engineering
The skills that separate firmware that works on the bench from firmware that survives ten years in the field: recovering from resets, brown-outs, flipped…
Role: Senior firmware engineer for products that must last in the field
The job day to day
You read a field unit's reset log and find the brown-out behind a week of mystery reboots, cut a sensor's sleep current from 300 to 3 µA with a power analyser, review the bootloader's signature check against glitching, and explain to the product manager why the update must boot on trial.
What you will be able to do
- Tell every reset cause apart and keep state that survives resets in checked RAM records
- Protect configuration and critical variables against flipped bits, and test it by injecting faults
- Recover a locked I2C bus, detect stuck pins and budget UART clock tolerance
- Build a current budget, pick sleep modes by their wake sources, and estimate battery life
- Design a secure boot chain with signed images, protected keys and anti-rollback versions
- Ship A/B updates that verify, boot on trial and roll back after a failed start
- Write constant-time and glitch-resistant checks, and lockouts that a reset does not clear
- Read a firmware dump: vector table, strings and disassembly, as an attacker would
Standards
- IEC 60730 Class B
- IEC 61508
- IEC 62443-4-2
- ETSI EN 303 645
- NIST SP 800-193
- PSA Certified
Before you start
- 4.1 Core peripherals
- 4.2 Serial communication
- 4.4 Storage
- 6.1 Debugging and testing
- 7.4 Safety and security
- 7.5 Power and EMC
B1 Faults and recovery
What the field does to a device and how firmware survives it: every reset cause, RAM that outlives a reset, brown-outs, flipped bits, locked buses, stuck pins and drifting clocks, and injecting each on purpose.
- Fault injection: resets, brown-outs and flipped bits · Reading the reset cause, RAM that survives a reset, brown-outs, single event upsets and injecting faults on purpose.
- Stuck buses, stuck pins and drifting clocks · Freeing a locked I2C bus, detecting stuck pins, UART clock budgets and a timeout on every wait.
B2 Power engineering
Where a battery's charge goes and how to keep it: a current budget from states and datasheet figures, measuring it, sleep modes chosen by their wake sources, and the clocks, pins and parts that draw.
- A current budget and battery life · Average current from states and durations, datasheet figures, measuring it, and what batteries really deliver.
- Designing for low power · Sleep modes and wake sources, entering them on STM32 and AVR, clocks and pins that draw, race to sleep.
B3 Product security
Keeping control of a device someone else holds: signed firmware and a chain of trust, A/B updates with trial boots and anti-rollback, timing and power side channels, glitching, and reading a firmware dump.
- Signed firmware and the chain of trust · Hashes, HMACs and signatures, a root of trust, key management, encryption and anti-rollback versions.
- A/B updates, trial boots and rollback · Two slots, verifying in place, an atomic boot record, the trial boot and when to confirm.
- Side channels and glitches · Timing and power side channels, constant-time code, glitching single decisions, and lockouts that hold.
- Reading a firmware dump · Vector tables, strings and disassembly, what attackers look for, and protecting the image.
Capstone: A hardened sensor node
Six graded stages in bare-metal C on a Nucleo-F446RE. The simulator cuts the supply, flips bits in RAM, locks the I2C bus, measures the current, interrupts the update and guesses the PIN; hidden tests check every recovery.