An advanced, project-based learning roadmap for embedded systems development on the STM32C031C6T6 (Cortex-M0+). From here on, the focus shifts to design decisions, scalability, and long-term maintainability. You'll stop asking "How do I make this peripheral work?" and start asking "How should this system be structured so it can grow, be reused, and be maintained?"
This repository is the continuation of ESH Roadmap Basic. While the basic roadmap focused on understanding individual peripherals through register-level access, this advanced roadmap tackles the engineering challenges that come after: system architecture, build infrastructure, reproducible environments, and scalable firmware design.
Key learning objectives:
- Containerized, reproducible build environments with Docker
- Firmware architecture patterns (layered drivers, HAL abstractions, event-driven design)
- Testing strategies for embedded software
- CI/CD pipelines for firmware projects
| MCU | STM32C031C6T6 — ARM Cortex-M0+, 48 MHz, 32 KB Flash, 12 KB SRAM |
| Board | NUCLEO-C031C6 |
| Debugger | On-board ST-LINK/V2-1 (SWD) |
| User LED | LD4 — PA5 |
| User Button | B1 — PC13 (active low) |
| Tool | Version | Purpose |
|---|---|---|
| Visual Studio Code | Latest | Primary IDE |
| Docker | Latest | Reproducible build environment |
| GNU ARM Embedded Toolchain | Latest | arm-none-eabi-gcc cross-compiler |
| Make | Latest | Build automation |
| CMake | Latest | Cross-platform firmware configuration and builds |
| OpenOCD | Latest | On-chip programming & debugging |
ESH_roadmap_advanced/
├── adv-00-docker/ # Dockerized bare-metal blinky (Makefile build)
├── adv-01-cmake/ # Bare-metal blinky upgraded to a CMake workflow
├── adv-02-docker-cmake/ # Dockerized ARM GCC workflow driven by CMake presets
├── STM32C031C6/ # Datasheets & reference manuals
└── README.md
Each project follows a consistent internal structure:
adv-XX-<topic>/
├── src/ # Source files (.c)
├── inc/ # Header files (.h)
├── startup_stm32c031xx.S # Vector table & startup code
├── stm32c031x6_flash.ld # Linker script
├── Makefile/CMake # Build configuration
└── build/ # Build output (generated)
| # | Folder | Topic | Description |
|---|---|---|---|
| 00 | adv-00-docker |
Docker Build Environment | Bare-metal blinky project built with a Makefile inside a Docker container. Demonstrates reproducible, host-independent firmware builds. |
| 01 | adv-01-cmake |
CMake Build Structure | Bare-metal blinky project migrated from a Makefile to a reusable ARM GCC CMake workflow with presets and a flash target. |
| 02 | adv-02-docker-cmake |
Docker + CMake Workflow | Bare-metal blinky project that combines a Dockerized toolchain with a preset-based CMake build and OpenOCD flash flow. |
-
Clone the repository
git clone https://github.com/Padifu03/ESH_roadmap_advanced.git cd ESH_roadmap_advanced -
Open in VS Code
code .
When VS Code prompts for recommended workspace extensions, install them. In particular, STMicroelectronics.stm32-vscode-extension is recommended for STM32 device setup, STM32 tooling integration, and board-oriented workflows.
- Select a project — open the desired folder (e.g.
adv-00-docker).
Configure the project:
cmake --preset debug
cmake --preset releaseBuild the firmware:
cmake --build --preset debug
cmake --build --preset releaseFlash with OpenOCD:
cmake --build --preset debug --target flash
cmake --build --preset release --target flashBuild the Docker image:
docker build -t stm32c031-blinky adv-02-docker-cmake/docker/Configure and build the firmware inside the container:
docker run --rm -v ${PWD}:/workspace stm32c031-blinky cmake --preset debug
docker run --rm -v ${PWD}:/workspace stm32c031-blinky cmake --build --preset debugClean or flash from the container:
docker run --rm -v ${PWD}:/workspace stm32c031-blinky cmake --build --preset debug --target clean
docker run --rm -v ${PWD}:/workspace --device /dev/bus/usb:/dev/bus/usb stm32c031-blinky cmake --build --preset debug --target flash| Document | File |
|---|---|
| STM32C031C6 Reference Manual | stm32c031c6_RM.pdf |
| STM32C031C6 Datasheet | stm32c031c6_datasheet.pdf |
| STM32C031C6 User Manual | stm32c031c6_user_manual.pdf |
| NUCLEO-64 Board User Manual | stm32_nucleo64_UM.pdf |
| Cortex-M0+ Generic User Guide | Cortex-M0plus_UG.pdf |
| ESH Roadmap Basic (prerequisite) | GitHub |
Contributions, suggestions, and bug reports are welcome. To contribute:
- Fork the repository.
- Create a feature branch (
git checkout -b feat/my-feature). - Commit your changes with clear, descriptive messages.
- Open a Pull Request against
master.
Please keep the existing project structure and coding style consistent.