This guide will help you set up the necessary tools to compile and debug the LPC1769 and STM32 microcontroller projects in this repository.
The ARM GCC Toolchain is required to compile code for ARM-based microcontrollers.
sudo apt update
sudo apt install gcc-arm-none-eabi
- Download the ARM GCC Toolchain from ARM Developer.
- Follow the installation instructions provided on the website.
OpenOCD is an open-source tool that provides debugging, in-system programming, and boundary-scan testing.
sudo apt install openocd
- Download OpenOCD from the official website.
- Follow the installation instructions provided on the website.
You can use various IDEs or text editors, but the following are recommended:
- VSCode: A lightweight code editor with excellent support for embedded development.
- MCUExpresso (NXP-specific): A specialized IDE for NXP microcontrollers, recommended for LPC1769 development.
- Download and install VSCode.
- Install the following extensions:
- C/C++ (Microsoft)
- Search for official PlatformIO IDE extension
- Install PlatformIO IDE.
- VSCode Extensions Manager and PlatformIO IDE auto-installer
- Check Quick Start guide (highly recommended).
- Download and install MCUExpresso IDE from the NXP website.
- Follow the setup instructions provided by NXP.
Depending on your build preference, install Make or CMake:
sudo apt install build-essential # For Linux
- Install MinGW and ensure the
make
utility is included.
sudo apt install cmake
- Download and install CMake from the official website.
To flash the firmware onto your microcontroller, you'll need the following tools:
- ST-Link Utility (STM32)
- OpenOCD (for both LPC1769 and STM32)
- Download the ST-Link Utility from the STMicroelectronics website.
- Follow the installation instructions provided on the website.
Already covered in Step 2.
For LPC1769 projects:
- If using MCUExpresso, you need to copy the source files and header files from the
src
andinclude
directories to your project, except fornewlib_stubs.c
.