Microcotroller Related Definitions¶
microcontroller¶
compact integrated circuit designed to govern a specific operation in an embedded system.
Core Components:¶
- CPU (Central Processing Unit) is the brain that executes instructions and performs arithmetic and logical operations. It includes an ALU (Arithmetic Logic Unit), control unit, and registers for temporary data storage.
-
Memory:¶
- Flash memory (non-volatile) stores the program code and retains it when power is off
- RAM (volatile) provides temporary storage for variables and data during program execution.
- EEPROM for storing small amounts of data that needs to persist between power cycles.
- bus system connects everything together through
-
data buses for transferring data
-
address buses for specifying memory locations
-
control buses for coordinating operations
-
I/O Ports provide the interface to the outside world, allowing the microcontroller to read sensors and control external devices through digital pins.
- Peripheral Components
-
peripherals built in components like timers/counters for precise timing operations, ADC (Analog-to-Digital Converters) for reading analog sensors, communication interfaces (UART, SPI, I2C) for talking to other devices, PWM generators for motor control, and interrupt controllers for responding to urgent events.
-
Clock System provides timing signals, usually from an internal oscillator or external crystal.
-
Common architectures
- Harvard architecture separate memory spaces for instructions and data, used by AVR and PIC
- Von Neumann architecture shared memory space, used by some ARM cores
Modern microcontrollers like ARM Cortex-M use modified Harvard architectures for efficiency.
Key Terms/Definitions:¶
Embedded toolchains are specialized sets of software—compilers (e.g., GCC, Clang), linkers, and debuggers—configured to translate high-level code (C/C++) into machine code for specific target microcontrollers, which differ from the development machine's architecture.
MCU development boards (e.g., Arduino, STM32 Nucleo, ESP32) are single-board computers, generally categorized by bit-width (8-bit to 64-bit), architecture (ARM RISC, AVR, PIC), and memory. They are designed for embedded systems, featuring on-chip flash memory and GPIO for interfacing with sensors and motors.
Microcontroller (MCU) architecture defines the internal structure, organization, and interaction of hardware components—CPU, memory (RAM/ROM), and peripherals—integrated onto a single chip to control specific, dedicated tasks. It typically follows Harvard or Von Neumann models, utilizing RISC or CISC instruction sets to manage embedded systems efficiently.
megahertz (MHz) is a unit of frequency equal to one million cycles per second. It measures the speed of electromagnetic waves (like radio) or, more commonly in computing, the clock speed of processors and RAM, where a higher MHz value generally indicates faster processing of instructions.
Flash memory is a non-volatile, rewritable storage medium that retains data without power, commonly used for code storage (firmware) in devices like SSDs and microcontrollers. SRAM (Static Random Access Memory) is a volatile, high-speed, and expensive memory used for temporary data, such as CPU cache and active variables, losing data when power is lost. This size limits your code size.
SRAM (Static Random Access Memory - Volatile) - stores your variables, arrays.. anything your program uses while running. It clears when the power turns off.
GPIO (General-Purpose Input/Output) pins are uncommitted, programmable digital pins on a microcontroller (MCU) that act as an interface to the outside world. They can be individually configured via software as inputs (reading sensor data/switches) or outputs (controlling LEDs/relays). These pins represent the fundamental way a microcontroller communicates with peripheral devices. Look for the programmable I/O lines in the description.
I/O (Input/Output) packages are libraries in programming languages (like java.io or Go's io) that provide essential interfaces, classes, and methods for reading, writing, and manipulating data streams from various sources such as files, networks, and memory buffers. They abstract the complexities of hardware communication into manageable operations.
Package - how it can be delivered. DIP pin package, surface mount.
An Integrated Development Environment (IDE) for microcontrollers is a software application that provides a comprehensive, all-in-one suite of tools for designing, writing, compiling, debugging, and flashing code onto a microcontroller unit (MCU). It acts as the central hub for embedded system development, combining an editor, compiler, and debugger to make the process of programming hardware more efficient.
family a group of processors that have the same architecture
translator translates user code into code specific to the architecture of the microcontroller