Skip to content

Latest commit

 

History

History
69 lines (46 loc) · 1.87 KB

README.md

File metadata and controls

69 lines (46 loc) · 1.87 KB

Blog

CI

CMake for Arm Cortex-M

An example repository of using CMake with the arm-none-eabi-gcc compiler for an Arm Cortex M4 processor.

Install the tools

Install the required tools, make sure they are in the system path

  1. Git
  2. CMake
  3. Ninja
  4. Arm GNU Toolchain
  5. OpenOCD

Cloning

This repository includes submodules. When cloning, use the --recursive flag.

git clone --recursive https://github.com/ryanwinter/cmake-arm-cortex-m

Building with CMake

Debug GCC

cmake --preset debug
cmake --build --preset debug

Release GCC

cmake --preset release
cmake --build --preset release

Debug IAR

cmake --preset debug-iar
cmake --build --preset debug-iar

Release IAR

cmake --preset release-iar
cmake --build --preset release-iar

Debugging with VSCode

The repository includes the necessary assets to build, flash and debug the application in VSCode using the Embeeded Tools extension

  1. Install VSCode
  2. Open the project folder in VSCode
  3. Press F5 to build, flash and run the project

GitHub Build Workflow

Third party

This repository includes source from the following 3rd parties.

  1. CMSIS 5