💡 This series is for engineers who want to graduate from “it works somehow” to “I know exactly why it works.”
About This Series
Why “Beyond Pointers”?
If you’ve been enjoying electronics with Arduino, you’ve probably wondered:
- “What does digitalWrite actually do internally?”
- “Why does using delay() stop everything else?”
- “Where is memory, physically?”
The answers are all “beyond the pointer” — on the other side of memory addresses.
Embedded systems are a world that deals with space, time, and electricity. Unlike OS-protected environments, you must control everything yourself.
This series is a step-by-step, reliable path to understanding the embedded engineering mindset: “addresses are the only reality.”
What You’ll Get From This Series
🎯 A New World View
- A microcontroller is a state machine: the CPU reads instructions from memory, writes to registers
- Addresses are the only reality: variables and registers are all “locations”
- The art of controlling time: interrupts, DMA, and the measurement mindset
- Strength through knowing how things break: the stack, pointer accidents, optimization traps
💡 Practical Skills
- Direct register manipulation: driving GPIO with BSRR
- Pointers = typed addresses: not scary — a weapon
- Interrupt design: know the anti-patterns, implement correctly
- Using DMA: the idea of making the CPU idle
- Measurement culture: measuring execution time with DWT CYCCNT
- Reading map files: controlling memory layout
📚 Thinking Like a Strong Embedded Engineer
- Data sheets are maps: use reference manuals as tools
- You can’t discuss without measuring: measurement-based design
- Learn by breaking: grow stronger through accidents
- Habit of reading generated code: understand the C-to-machine-code correspondence
Series Article List
Phase 0: Introduction
| Episode | Title | Date | Link |
|---|---|---|---|
| #0 | Why Embedded Programming Looks Hard — Place and Time | 2026/02/17 | 📖 Read |
Phase 1: The World of Space
| Episode | Title | Date | Link |
|---|---|---|---|
| #1 | The Microcontroller Is an “Address World” | 2026/02/23 | 📖 Read |
| #2 | Where Variables Live — Flash, RAM, and the Stack | 2026/03/01 | 📖 Read |
| #3 | How C Represents Memory — Arrays, Structs, and Padding | 2026/03/06 | 📖 Read |
| #4 | The World of Bits — Register Operations and the BSRR Design | 2026/03/14 | 📖 Read |
| #5 | Pointers = Addresses with Types — Turning Pointers into a Weapon | 2026/03/25 | 📖 Read |
| #6 | The Complete Pointer Accident Handbook — How and Why Things Break | 2026/03/28 | 📖 Read |
Phase 2: The World of Time
| Episode | Title | Date | Link |
|---|---|---|---|
| #7 | The World of Time — Knowing the Weight of a Single Cycle | 2026/04/08 | 📖 Read |
| #8 | What Are Interrupts? (NVIC / Vectors / The Danger) | 2026/04/10 | Coming soon |
| #9 | Interrupt Design Anti-Patterns — The Critical List | 2026/04/17 | Coming soon |
Phase 3: Mastering the System
| Episode | Title | Date | Link |
|---|---|---|---|
| #10 | The DMA Idea — Making the CPU Idle | 2026/04/24 | Coming soon |
| #11 | Linker Scripts and Map Files — Looking Under the Hood | 2026/05/01 | Coming soon |
| #12 | Optimization and Assembly — And Then, Mastery | 2026/05/08 | Coming soon |
📌 Updates: This page is updated as new articles are published. Bookmark recommended!
Who This Series Is For
✅ Recommended if you:
- Have Arduino experience and want to understand what’s happening inside
- Have learned basic C but got stuck on pointers
- Feel like “I can blink an LED, but I don’t know why it works”
- Want to understand the philosophy of embedded systems
- Want to be able to read data sheets
- Want to grow stronger by knowing how things break
Prerequisites
The following knowledge will help you get more from this series:
| Topic | Required level | Notes |
|---|---|---|
| C language | ⭐⭐☆☆☆ | Variables, functions, and if-statements are enough |
| Arduino | ⭐⭐☆☆☆ | LED blink experience is fine (not required) |
| Electronics | ⭐☆☆☆☆ | A rough understanding of why LEDs light up |
| Pointers | ❌ Not needed | This series will make them click |
ℹ️ Not confident with pointers?
That’s actually the ideal starting point. Episode 5’s core message — “a pointer is an address with a type” — makes everything connect.
Required Hardware
🔌 Essential Hardware
| Hardware | Model/Spec | Cost | Where to buy |
|---|---|---|---|
| STM32 development board | NUCLEO-F401RE | ≈$10–15 | Digi-Key, Mouser, ST |
| USB cable | Micro-USB Type-B | ≈$3 | Use what you have |
| Breadboard | Standard size | ≈$3 | Any electronics supplier |
| Jumper wires | M-M, M-F | ≈$3 | Any electronics supplier |
| LEDs + resistors | Red/green LEDs, 330Ω resistors | ≈$2 | Use what you have |
Total: approximately $20–25
💡 Why NUCLEO-F401RE?
- ST-Link/V2-1 built in: USB connection is all you need for development
- Arduino-compatible connector: existing shields work
- 84MHz Cortex-M4: fast enough that execution time measurement is meaningful
- Official support: fully supported by STMicroelectronics
- Expandability: all pins accessible via Morpho connectors
Slightly more expensive than a Blue Pill, but zero risk of wiring mistakes, counterfeits, or flash failures.
🛠️ Development Environment (Free)
- STM32CubeIDE (official from STMicroelectronics)
- Eclipse-based integrated development environment
- Debugger, build, and flash writing all in one
- Windows/Mac/Linux supported
- STM32CubeMX (integrated into CubeIDE)
- GUI tool for pin assignment and clock configuration
- Auto-generates initialization code (this series uses the minimum)
Installation is covered in detail in Episode 1.
HAL Library Policy
This series keeps HAL (Hardware Abstraction Layer) use to a minimum:
- Use CubeMX/CubeIDE only for the foundation (clock setup and pin initialization)
- All operations are direct register access (CMSIS level) as a rule
- HAL is shown as a “comparison frame” briefly at the end of each episode
Why: touching registers directly is how you build an intuition for addresses, bits, and time.
Series Schedule (13 Episodes: #0 + #1–12)
Episode 0: Introduction — What You’ll Get From This Series
Published: 📖 Read
Purpose: Building the reader’s mental framework
- Embedded systems are a world of space, time, and electricity
- Fighting in a world without OS protection
- The series goal: wiring up the thinking circuits of mastery
Practice: None (philosophy episode)
Phase 1: The World of Space (Episodes 1–6)
Embedded systems see the world through the coordinate system of “addresses.” Variables and registers are all just “locations.”
📘 Episode 1: The Microcontroller Is an “Address World”
Published: 📖 Read
- The CPU is a state machine — reads instructions from memory
- Addresses are the only reality
- Peripherals also live in memory space (preview of memory-mapped I/O)
Practice: Look inside memory and registers with the debugger
📘 Episode 2: Where Variables Live — Flash, RAM, and the Stack
Published: 📖 Read
- The roles of Flash and RAM
- The true nature of the stack and heap
- Why the stack is dangerous (foreshadowing)
Practice: Observe the stack pointer, see where local variables are placed
📘 Episode 3: How C Represents Memory — Arrays, Structs, and Padding
Published: 📖 Read
- Variables = memory
- Arrays = contiguous
- Structs = layout
- The meaning of volatile (foreshadowing)
Practice: Display and verify addresses (printf or watch)
📘 Episode 4: The World of Bits — Register Operations and the BSRR Design
Published: 📖 Read
- Mask / shift operations
- RMW (Read-Modify-Write) problem
- The BSRR design philosophy (STM32’s elegant solution)
Practice: Blink an LED by hitting GPIO registers directly (BSRR recommended)
📘 Episode 5: Pointers = Addresses with Types — Turning Pointers into a Weapon
Published: 📖 Read
- The essence: typed addresses
- The meaning of casts
- The moment it connects to memory-mapped I/O
- Reading the CMSIS header (GPIO_TypeDef)
- The meaning of the
->operator
Practice: Operate GPIO registers with raw pointers to blink an LED
📘 Episode 6: The Complete Pointer Accident Handbook — How and Why Things Break
Published: 📖 Read
- NULL dereference
- Dangling pointers
- Stack lifetime (returning the address of a local variable)
- Out-of-bounds array access
- UB (undefined behavior)
- How optimization makes things worse (foreshadowing)
Practice: Break-it code + observe in the debugger
Phase 2: The World of Time (Episodes 7–9)
Embedded systems require the art of controlling time. Clocks, periods, interrupts, measurement — everything is a battle on the time axis.
📘 Episode 7: The World of Time — Knowing the Weight of a Single Cycle
Published: 📖 Read
- Clocks / periods
- Execution time (understand in CPU cycles)
- You can’t discuss without measuring
Practice: Measure HAL_Delay / introduce DWT CYCCNT / GPIO toggle + oscilloscope
📗 Episode 8: Understanding Interrupts — Vector Table, NVIC, Context Saving, and TIM2 Implementation
- Vector table — the map that tells the CPU where to jump on each interrupt
- NVIC (Nested Vectored Interrupt Controller) — priority, enable, pending management
- Context saving — 8 registers pushed automatically, preemption and pending behavior
- Shared variable problem (
volatile, atomicity — foreshadowing)
Practice: Generate 1ms periodic events with TIM2 interrupt
📗 Episode 9: Interrupt Design Anti-Patterns — The Critical List
Coming soon (planned 2026/04/17)
- Doing heavy work in an ISR
- Using printf in an ISR (fatal)
- Carelessly touching shared variables
- Priority hell
- Critical section misuse
- volatile over-/under-use
Practice: Deliberately implement anti-patterns and break things
Phase 3: Mastering the System (Episodes 10–12)
Once you understand space and time, the final step is the techniques to master the whole system.
📙 Episode 10: The DMA Idea — Making the CPU Idle
Coming soon (planned 2026/04/24)
- Work the CPU doesn’t have to do
- Throughput vs latency
- Intuition for bus contention
Practice: DMA-ify UART transmission (with a ring buffer)
📙 Episode 11: Linker Scripts and Map Files — Looking Under the Hood
Coming soon (planned 2026/05/01)
- .text / .data / .bss
- What the initialization process actually does
- How to read map files
- How to place the stack/heap
Practice: Track RAM consumption with a map file / size reduction examples
📙 Episode 12: Optimization and Assembly — And Then, Mastery
Coming soon (planned 2026/05/08)
- What changes between -O0 / -O2
- Revisiting volatile
- The habit of reading generated code
- The conditions for embedded mastery, summarized
Practice: Compare with objdump, unexpected optimization examples
How to Study
One Episode per Week — Sustainable Pace
Each episode’s estimated study time is 2–3 hours. One episode per weekend means you can finish the series in about 3 months.
Feb |████░░░░░░░░| Phase 0–1 start (philosophy + space)
Mar |████████░░░░| Phase 1 complete
Apr |████████████| Phase 2 complete (world of time)
May |██░░░░░░░░░░| Phase 3 complete (system mastery)
“Breaking Code” Makes You Stronger
Broken code is more valuable than working code.
- Episode 6: deliberately create pointer accidents
- Episode 9: implement interrupt anti-patterns and break things
Knowing how things break is the most powerful way to learn.
Real-Hardware Verification Comes First
“Try it with your hands” is the top priority over theory.
- Look inside memory with the debugger
- Measure execution time with DWT CYCCNT
- Track RAM consumption with map files
- Read generated code with objdump
You can’t discuss without measuring — the iron rule of the embedded engineer.
All Code on GitHub
Sample code for each episode will be published on GitHub:
📁 Repository: https://github.com/ramtuc/stm32-embedded-series
Each episode’s folder contains a complete working project file set and “break-it code.”
FAQ
Q1: Is it harder than Arduino?
A: Initially you’ll feel “there’s a lot to take in.” But the essence is just “seeing what Arduino was hiding from you.” From Episode 4 onward, there’s a real satisfaction in hitting registers directly.
Q2: I’m not great with pointers — will I be okay?
A: That’s actually ideal. One of the goals of this series is to internalize “pointer = address with a type.” Episode 5 makes it fully click.
Q3: Can I use a Blue Pill or STM32F103?
A: Technically yes, but NUCLEO-F401RE is strongly recommended:
- Built-in ST-Link (no extra wiring)
- 84MHz (ideal for execution time measurement)
- Official support (no counterfeits)
Blue Pills have many counterfeits and debugging becomes frustrating.
Q4: Don’t you use the HAL library?
A: Minimum use only. CubeMX handles clock setup and pin initialization; everything else is direct register access as the default. Why:
- Builds your intuition for addresses, bits, and time
- Develops the ability to read data sheets
- Applicable to other microcontrollers
A brief “HAL implementation example” is included at the end of each episode.
Q5: Will I reach a professional level?
A: This series will build the thinking circuits of a strong embedded engineer, but reaching professional fluency still requires hands-on experience. That said, you’ll break through these walls:
- Can’t read data sheets → you can
- Registers are scary → they become a weapon
- Stuck on pointers → you understand the essence
- Don’t understand interrupts → you can design them
It’s more than enough to cross the wall from “no experience” to “experienced.”
About the Author
RAM / ElectroRam Studio
- Specialization: Embedded systems development, IoT device design
- Experience: Embedded software development for industrial and medical equipment
- Activities: Electronics articles, technical books, PCB sales on Booth
🌐 Website: https://electwork.net
🛒 Booth shop: ElectroRam Studio
Let’s Get Started
“Beyond Arduino” holds unlimited possibilities:
- Devices with production-level performance
- Battery-powered systems that run for over a year
- Robots that demand real-time control
Being able to build these with your own hands — that’s the goal of this series.
See you in the embedded world beyond pointers!
See You in the Embedded World …