hardware//chip//MCU

A microcontroller unit (MCU) is a self-contained chip that integrates a core (often ARM Cortex-M), flash memory, RAM and peripheral blocks (timers, ADC, UART, SPI, I2C) on a single die. It runs its firmware directly on bare metal or on a lightweight RTOS, with no operating system layer in between, and everything it needs is inside: about 256 KB of RAM for the stack and about 1024 KB of flash for the firmware.


A microcontroller unit (MCU) is a self-contained chip that integrates a core (often ARM Cortex-M), flash memory, RAM and peripheral blocks (timers, ADC, UART, SPI, I2C) on a single die. It runs its firmware directly on bare metal or on a lightweight RTOS, with no operating system layer in between, and everything it needs is inside: about 256 KB of RAM for the stack and about 1024 KB of flash for the firmware.

MCUs dominate IoT, automotive and industrial control, where cost, power and determinism matter more than raw speed. That is the line against an SoC, which integrates a GPU, an NPU and a modem around application cores; an MCU is built for real-time control with minimal overhead. STM32 (STMicro) and ESP32 (Espressif) are typical examples.

It is the workhorse of closed loops. A deterministic loop at 1 to 10 kHz with microsecond latencies, drawing 0.1 to 1 W, is what it does best, because its rich peripherals do the timing in hardware: a timer releases the loop, the ADC samples on a trigger, SPI and DMA bring the IMU's data without the CPU, PWM and CAN carry the commands out. What it does badly is memory (kilobytes to a few megabytes) and heavy computation, so a large network, a long-horizon MPC or a big SVD go to another processor (embedded system). A flight controller, a motor drive, the ESC behind every propeller and a vibration sensor that detects anomalies and sends only the alert are all MCUs.

An MCU is general-purpose: the same kind of chip can be a toaster, a drone, a watch or a sensor hub.

It usually carries ASIC helpers on the die (for instance an NPU, a DSP or an ADC), and needs more of them around it for specialized tasks.

Cortex-M is the natural match for IoT and also for wearables, with battery life of up to two years.

Its timing is what a real-time operating system builds on: an interrupt served in tens of cycles, with little variation, is why fast loops live here and not on Linux.