Topic domain
Embedded Systems
Computing under hard constraints of power, memory, and time.
- Articles
- 80
- Clusters
- 8
- Foundational
- 24
- Intermediate
- 32
- Advanced
- 24
Cores, peripherals, and memory maps.
- How a Microcontroller Memory Map Assigns Meaning to Every Address
- Flash Wait States and the Cost of Fetching Instructions from Embedded Flash
- Nested Interrupt Entry, Tail-Chaining and Late Arrival in the NVIC
- Clock Gating, Peripheral Enable Order and the Write That Disappears
- Bus Matrix Arbitration and What DMA Contention Costs the Core
- GPIO Configuration Registers and the Reset States That Drive Pins
Startup code, vectors, and register access.
- Where the Reset Vector and Initial Stack Pointer Come From
- Getting Initialised Data and BSS Ready Before main Runs
- What volatile Guarantees in Memory-Mapped Register Access
- Read-Modify-Write Hazards in Peripheral Registers
- What the Hardware Does Between an Interrupt and Its Handler
- Relocating the Vector Table and Running It from RAM
Tasks, priority inversion, and deadlines.
- How a Preemptive RTOS Scheduler Picks the Next Task
- Blocking Primitives: How a Task Waits Without Spinning
- Priority Inversion and How Bounded It Can Be
- Rate-Monotonic Priority Assignment and Its Utilisation Bound
- Response-Time Analysis for Fixed-Priority Task Sets
- Deferred Interrupt Work: Splitting Handlers from Processing
I2C, SPI, CAN, and their failure modes.
- Open-Drain Signalling and Arbitration on a Shared Two-Wire Bus
- The Shift Register Behind SPI and Why There Are Four Clock Modes
- UART Framing, Baud Rate Error, and the Overrun That Loses Data
- CAN Frame Layout and Why Bit Stuffing Is Mandatory
- Clock Stretching and Recovering a Bus Held Low by a Stuck Slave
- Differential Signalling, Common-Mode Rejection, and Where to Put the Terminator
Sleep states, duty cycling, and energy budgets.
- From Duty Cycle to Average Current and Battery Life
- What a Sleep Mode Actually Turns Off
- Wake-Up Latency and Its Energy Cost
- Tickless Idle and Timer Reprogramming
- Peripheral Clock Gating and Autonomous Transfer
- Voltage and Frequency Scaling with a Performance Constraint
Bootloaders, A/B images, and rollback.
- What a Bootloader Must Establish Before Jumping to an Application
- Image Headers and Integrity Validation Before Execution
- Dual-Bank Slots and How a Bootloader Picks One
- Erase Granularity, Write Ordering, and Power Loss During a Flash Write
- Chunked Transfer and Retransmission in Firmware Delivery
- Trial Boot, Confirmation, and Automatic Rollback
Redundancy, watchdogs, and certification practice.
- Deriving a Safety Integrity Level from Risk Parameters
- Windowed Watchdogs and the Program-Flow Contract
- Safe States and Fail-Silent Behaviour in Control Systems
- Lockstep Cores and Comparator Logic in Safety Microcontrollers
- Runtime Self-Tests and Diagnostic Coverage Measurement
- Common-Cause Failure and What Design Diversity Actually Buys
Cross toolchains, debug probes, and tracing.
- Anatomy of a Cross Toolchain: Triples, Sysroots, and Multilibs
- Linker Scripts: Why Sections Have Two Addresses
- Reading an ELF Image: Sections, Symbols, and DWARF
- Intel HEX, Motorola SREC, and What a Programmer Actually Consumes
- How a Probe Reads Memory Without the CPU: Debug Ports and Access Ports
- Hardware Breakpoints, Watchpoints, and the Comparators Behind Them
All Embedded Systems articles
- Oct 21, 2026 Stack and Memory Budgeting for a Set of Preemptive Tasks Why each task needs its own stack, how worst-case stack depth is computed from the call graph plus exception frames, and where a shared stack changes the accounting.
- Oct 12, 2026 Bus Matrix Arbitration and What DMA Contention Costs the Core How a multi-master bus fabric picks a winner when the core and a DMA engine target the same SRAM, why round-robin is not always fair, and how contention shows up as jitter.
- Oct 7, 2026 Fault Escalation and Reading the Stacked Frame After a Crash Why an imprecise bus fault arrives as a hard fault, which status bits distinguish the causes, and how the stacked frame locates the instruction that failed.
- Sep 9, 2026 How a Microcontroller Memory Map Assigns Meaning to Every Address How fixed address regions are decoded on a microcontroller, why peripherals sit at constant addresses, and what the bus does with an address that nothing claims.
- Aug 18, 2026 Earliest-Deadline-First and What Happens When the System Overloads Why dynamic deadline ordering is optimal on one processor, how the utilisation test differs from the fixed-priority one, and how the schedule degrades after a bounded overload.
- Aug 3, 2026 UART Framing, Baud Rate Error, and the Overrun That Loses Data How start-bit synchronisation survives clock mismatch, how much baud error a ten-bit frame tolerates, and why the receive FIFO overruns before the interrupt handler runs.
- Jul 18, 2026 Dual-Bank Slots and How a Bootloader Picks One Why two firmware slots turn an in-place overwrite into a recoverable operation, how the boot decision is made from metadata, and what the doubling of flash costs.
- Jul 8, 2026 Wake-Up Latency and Its Energy Cost Why returning from a low-power state costs microseconds and microjoules, how that cost sets a floor on the usable duty cycle, and where the transition sequence loses time.
- Jun 22, 2026 How a Preemptive RTOS Scheduler Picks the Next Task The ready-list, priority comparison, and context switch path a fixed-priority kernel follows on every tick, and why the runnable set is the only structure that matters.
- Jun 19, 2026 Intel HEX, Motorola SREC, and What a Programmer Actually Consumes The record structure of the two textual image formats, how each encodes load addresses and detects corruption, and why a raw binary loses the information a programmer needs.
- May 28, 2026 From Duty Cycle to Average Current and Battery Life How charge accounting turns an active and sleep schedule into an average current, and where the resulting battery-life estimate stops being trustworthy.
- May 28, 2026 Time-Triggered Buses, Global Time, and Bus Guardians How a static TDMA schedule removes arbitration from the communication path, how nodes agree on a global time, and why a bus guardian is needed to enforce slot ownership.
- May 26, 2026 Rate-Monotonic Priority Assignment and Its Utilisation Bound Why assigning priorities by period is optimal among fixed-priority schemes, what the 69 percent bound actually guarantees, and where the harmonic case recovers full utilisation.
- May 23, 2026 Signature Verification and Where the Root Key Lives How a constrained bootloader verifies an image signature, which algorithms fit in its budget, and why storing the public key in flash defeats the purpose.
- May 19, 2026 Ordering Constraints in the First Thousand Instructions Clock sources, flash wait states, external memory controllers, and the floating-point unit all have prerequisites, so the startup sequence is a dependency graph rather than a list.
- May 8, 2026 Differential Signalling, Common-Mode Rejection, and Where to Put the Terminator Why a twisted pair driven in opposition rejects ground noise, how termination absorbs reflections, and why the correct value is set by the cable rather than the transceiver.
- Mar 30, 2026 Duty-Cycled Radios and Preamble Sampling Why a receiver that listens continuously dominates a radio budget, how preamble sampling trades latency for a short listen window, and where the trade breaks.
- Mar 30, 2026 Peripheral Clock Gating and Autonomous Transfer How gating a peripheral clock saves dynamic power, why a gated peripheral still costs leakage, and how DMA lets a conversion happen with the core asleep.
- Mar 16, 2026 Where the Reset Vector and Initial Stack Pointer Come From Why the first two words of a firmware image are read by hardware before any instruction executes, how the vector table is indexed, and what breaks when the table moves.
- Feb 28, 2026 Chunked Transfer and Retransmission in Firmware Delivery How an image crosses a slow or unreliable link in numbered chunks, why the window size is bounded by the receiver buffer, and where the retry logic belongs.
- Feb 26, 2026 Open-Drain Signalling and Arbitration on a Shared Two-Wire Bus How pull-up resistors and open-drain drivers turn two wires into a wired-AND, and why that makes simultaneous transmission by two masters harmless rather than destructive.
- Feb 16, 2026 Worst-Case Execution Time Analysis and What the Bound Is Worth Why a measured maximum is not a worst case, how static analysis bounds a path through the control-flow graph, and which microarchitectural features make the bound pessimistic or unobtainable.
- Feb 8, 2026 Instruction Trace: Funnels, Packet Formats, and Reconstructing Execution How an on-chip trace unit compresses executed addresses into packets, why the trace is not a log of instructions, and what a decoder must infer from partial data.
- Feb 4, 2026 Clock Gating, Peripheral Enable Order and the Write That Disappears Why a peripheral register write does nothing until its bus clock is enabled, why enabling order matters for parts with dependency chains, and how to diagnose the silent failure.
- Jan 29, 2026 DO-178C Objectives, Design Assurance Levels, and Structural Coverage How software level follows from failure condition severity, what the objective tables actually require at each level, and why MC/DC measures test adequacy rather than correctness.
- Jan 22, 2026 Safe States and Fail-Silent Behaviour in Control Systems How a safe state is chosen when no single output value is safe for every hazard, why de-energisation is the default, and what fail-silent units cost in availability.
- Jan 18, 2026 Lockstep Cores and Comparator Logic in Safety Microcontrollers How two cores executing the same instruction stream are compared cycle by cycle, what a comparator can and cannot detect, and why the delay between the lanes is a deliberate design parameter.
- Jan 9, 2026 Anatomy of a Cross Toolchain: Triples, Sysroots, and Multilibs How a compiler built for one machine produces code for another, what the target triple actually selects, and which ABI mismatches fail at link time versus silently at run time.
- Jan 9, 2026 Masking Interrupts, Priorities, and Exclusive Access Without an OS The three mechanisms a bare-metal core offers for making a shared update atomic, what each one costs, and how to pick between them per invariant.
- Dec 9, 2025 Sizing Pull-Up Resistors Against Bus Capacitance and Rise Time The two inequalities that bound a pull-up value: the rise time the mode allows and the sink current a device guarantees, and why the window closes as the bus gets faster.
- Dec 8, 2025 Sizing Energy Storage for an Intermittently Powered Device How a harvesting source, a buffer capacitor, and a load with a fixed energy per operation determine whether a device can run at all, and what happens at the boundary.
- Nov 28, 2025 Stack Unwinding on a Target With No Frame Pointer How a debugger reconstructs call frames from compiler-generated unwind tables, and why an interrupt frame on a bare-metal target breaks the unwinder entirely.
- Nov 11, 2025 Successive-Approximation ADCs: Sample-and-Hold Settling and Conversion Timing What limits the sample rate of a SAR converter, why the sampling switch needs a settling budget, and how source impedance turns a datasheet accuracy figure into a smaller one.
- Oct 17, 2025 Image Headers and Integrity Validation Before Execution How a bootloader decides an image is complete and well-formed, which fields belong in the header, and why a checksum over the wrong range is worse than none.
- Oct 11, 2025 Anti-Rollback Counters and Version Monotonicity Why a validly signed older image is still a downgrade attack, how a monotonic counter is kept without a battery, and what the counter costs in flash endurance.
- Sep 7, 2025 The Shift Register Behind SPI and Why There Are Four Clock Modes Two shift registers joined by two wires explain SPI completely, including the CPOL and CPHA combinations, the daisy chain, and the consequences of having no acknowledgement.
- Aug 21, 2025 What the Hardware Does Between an Interrupt and Its Handler The stacked frame, the link register value that redirects the return, and the chaining shortcuts that make back-to-back interrupts cheap.
- Aug 6, 2025 Blocking Primitives: How a Task Waits Without Spinning The blocked-state bookkeeping behind a semaphore take, how a woken task reaches the ready set, and what the wake-up path costs in latency and stack.
- Jul 20, 2025 In-Circuit Programming: Why the Flash Algorithm Runs From RAM How a probe erases and writes flash through the target core, why the routine cannot execute from the memory it is modifying, and what sector granularity costs an update.
- Jul 17, 2025 Memory Protection Units on Microcontrollers and Stack Overflow Detection How an MPU partitions a small address space into regions with access attributes, why guard regions catch a stack overflow at the fault rather than later, and what the unit cannot protect.
- Jul 14, 2025 CAN FD: Longer Payloads, a Faster Data Phase, and the Loop That Must Close in Time The frame format changes that let a CAN FD frame carry 64 bytes at a higher bit rate, and the transceiver symmetry requirement that limits how far the data phase can be pushed.
- Jul 14, 2025 What a Sleep Mode Actually Turns Off The clock, regulator, and bias changes behind the named low-power states on a microcontroller, and why the deepest state is rarely the cheapest one to use.
- Jul 11, 2025 Bit-Banding: Atomic Single-Bit Access Through an Alias Address Region How the Cortex-M3 and M4 alias one bit of memory to a whole word, what address arithmetic maps bit to word, and why the feature disappeared from later cores.
- Jun 25, 2025 Common-Cause Failure and What Design Diversity Actually Buys Why two identical channels fail together more often than independence predicts, how beta factors enter the reliability calculation, and which kinds of diversity reduce the shared term.
- Jun 23, 2025 Deferred Interrupt Work: Splitting Handlers from Processing Why the top half of a handler should only acknowledge and wake, how the bottom half runs at a chosen priority, and what the split costs in latency.
- Jun 21, 2025 Interrupt Latency, Tick Overhead, and the Kernel Cost Budget How to decompose the delay from an external event to a task running into measurable pieces, and which kernel configuration choices move each piece.
- May 30, 2025 Secure Debug Lifecycle: Authentication, Locked Ports, and Recovery How a debug port is gated by device life-cycle state and certificates, what an open port exposes once keys are readable, and why the lock is one-way once the device ships.
- May 30, 2025 What volatile Guarantees in Memory-Mapped Register Access volatile forces a compiled access to happen, but it does not make the access atomic, ordered, or visible to the device in the order the source implies.
- May 21, 2025 Priority Inversion and How Bounded It Can Be Why a low-priority task holding a shared lock delays a high-priority one, how inheritance and ceiling protocols change the blocking term, and what each still leaves unbounded.
- May 20, 2025 How a Probe Reads Memory Without the CPU: Debug Ports and Access Ports The transaction sequence a debug probe uses over SWD or JTAG to halt a core and touch memory, and why some reads return stale data even though the transfer succeeded.
- May 10, 2025 Linker Scripts: Why Sections Have Two Addresses How a linker script assigns load and virtual addresses, why initialised data needs a copy step at startup, and what happens to sections the script does not mention.
- May 9, 2025 Hardware Breakpoints, Watchpoints, and the Comparators Behind Them Why a target supports only a handful of breakpoints, how an address comparator matches an instruction fetch, and what a data watchpoint does to the pipeline when it fires.
- Apr 12, 2025 GPIO Configuration Registers and the Reset States That Drive Pins How a general-purpose pin is routed, why the reset state of every pin matters at power-on, and which configuration mistakes produce a pin that looks correct and is not.
- Mar 20, 2025 Erase Granularity, Write Ordering, and Power Loss During a Flash Write Why a firmware update cannot be made atomic at the byte level, how sector granularity dictates the update algorithm, and what a partially erased sector actually contains.
- Mar 19, 2025 What a Bootloader Must Establish Before Jumping to an Application The register values, memory layout, and validation a bootloader owes an application image, and why the transfer has to be a tail branch rather than an ordinary call.
- Feb 28, 2025 Runtime Self-Tests and Diagnostic Coverage Measurement How startup and periodic self-tests establish that safety mechanisms still work, how coverage is measured by fault injection, and why a high percentage hides a distribution.
- Feb 17, 2025 Response-Time Analysis for Fixed-Priority Task Sets The recurrence that computes exact worst-case response time, why it converges, what the blocking term adds, and where the critical instant assumption costs pessimism.
- Jan 10, 2025 Flash Wait States and the Cost of Fetching Instructions from Embedded Flash Why an on-chip flash array cannot feed a fast core at one word per cycle, how wait states and prefetch buffers change that, and where the timing stops being uniform.
- Dec 20, 2024 Getting Initialised Data and BSS Ready Before main Runs Why a C static variable occupies two addresses, how the startup copy moves initialised data from flash into RAM, and why zeroed memory has to be zeroed by software.
- Nov 22, 2024 Retention Versus Reinitialisation in Deep Sleep The trade between keeping state alive across a sleep and rebuilding it on wake, expressed as a sleep-current penalty against a per-wake energy cost.
- Sep 18, 2024 Voltage and Frequency Scaling with a Performance Constraint Why lowering frequency alone rarely saves what it appears to, how voltage follows frequency, and where the quadratic voltage term stops paying for itself.
- Sep 4, 2024 Nested Interrupt Entry, Tail-Chaining and Late Arrival in the NVIC How the interrupt controller decides which of several pending interrupts runs first, why back-to-back handlers skip the full restore, and what happens when a request arrives during entry.
- Jul 22, 2024 CAN Frame Layout and Why Bit Stuffing Is Mandatory The field-by-field structure of a classical CAN frame, the stuff-bit rule that keeps receivers synchronised, and what each field costs in the worst case.
- Jul 17, 2024 Read-Modify-Write Hazards in Peripheral Registers Why assigning through a bit-set idiom corrupts registers the hardware also writes, how write-one-to-clear flags interact with that idiom, and what surrogate registers buy.
- Jul 5, 2024 Windowed Watchdogs and the Program-Flow Contract Why a watchdog that accepts a refresh too early is as dangerous as one that never fires, how the window and the sequence check constrain the timing, and where the supervision must live to be independent.
- May 9, 2024 Reading an ELF Image: Sections, Symbols, and DWARF How a debugger maps a source line to a flash address, what the symbol table contributes that DWARF does not, and why a stripped image still debugs correctly.
- Apr 18, 2024 Worst-Case Response Time of a CAN Message Under Fixed-Priority Arbitration Why the identifier is a priority, how the blocking and interference terms of a response-time bound are computed for a bit-stuffed frame, and where the analysis stops being optimistic.
- Dec 11, 2023 Deadline Misses: Detection, Recovery, and Watchdog Design How a kernel learns that a deadline was missed, what recovery actions are safe after a miss, and how a watchdog is configured so that a stuck task resets cleanly.
- Nov 9, 2023 Tickless Idle and Timer Reprogramming How a kernel suppresses the periodic tick while the system is idle, which timer it programs instead, and what the reprogramming costs in latency and in lost timekeeping.
- Oct 26, 2023 Attributing Energy to Code with a State Machine Model How to assign charge to firmware paths by tracking state transitions, why instruction counts are a poor proxy, and where the attribution model is structurally wrong.
- Oct 9, 2023 Delta Updates: Applying a Patch to an Image Already in Flash How a difference between two firmware builds is expressed as copy and insert operations, why block alignment decides the patch size, and where the reconstructed image goes.
- Sep 9, 2023 Boot Metadata Persistence and the Commit Record The record format that survives an interrupted write, how many copies are enough, and why the sequence number rather than the timestamp decides which copy wins.
- Sep 2, 2023 Timer Prescalers, Auto-Reload and the Arithmetic Behind a Period How the prescaler and auto-reload registers divide a clock into a period, why the achievable periods are quantised, and how update events and preload buffering change when a new period takes effect.
- Aug 1, 2023 Voting Redundancy and Average Probability of Failure on Demand How 1-out-of-2 and 2-out-of-3 architectures change the PFD calculation, why the common-cause term dominates the result, and what a voter must do when its channels disagree.
- Jul 25, 2023 Deriving a Safety Integrity Level from Risk Parameters How tolerable risk, demand mode, and consequence parameters become a SIL or ASIL target, and why the resulting number constrains architecture and evidence rather than code quality.
- Apr 6, 2023 Clock Stretching and Recovering a Bus Held Low by a Stuck Slave Why a slave is allowed to hold the clock line down, how that interacts with arbitration and timeouts, and the pulse sequence that frees a device stuck mid-byte.
- Jan 10, 2023 Relocating the Vector Table and Running It from RAM How the table base register changes where exceptions dispatch, why a misaligned base fails silently, and what a writable copy of the table enables.
- Nov 19, 2022 CAN Error Counters and the State Machine That Silences a Faulty Node Transmit and receive error counters move by different amounts for different faults, and the three-state model that follows from them decides when a node stops talking.
- Jul 27, 2022 Scheduling Without a Scheduler: Superloops and Their Latency Budget How a main loop plus interrupt handlers bounds worst-case response time, where jitter creeps in, and the point at which the structure stops meeting its deadlines.
- Dec 13, 2021 Trial Boot, Confirmation, and Automatic Rollback How a new image is allowed to run under supervision, what counts as proof that it works, and why the confirmation step has to come from the application rather than the bootloader.