The Pico Build Kit ================== Release Date: 2025.07.20 These instructions were tested on Debian 12 and Debian 11 running on amd64 architecture, and the Raspberry Pi 3B. Introduction and Overview ------------------------- When I first started working with the Raspberry Pi Pico, it was difficult to create my first working C language project. I tried copying an example program, and it would not compile. As I explored around, I realized that the development system was dependent on using Cmake, and that I needed a working CMakeLists.txt configuration file for it. There were also environment variables that needed to be set correctly, and other things. It took time to sift through documentation and code repositories to find the parts I needed and put them together into a successful build. This happened again when I decided to try FreeRTOS. I learned that I needed a FreeRTOSConfig.h file, and the first few examples I found did not work. There were the same kind of complications and hurdles when I added RISC-V support, so I could use the RISC-V cores in my Pico 2, and again when I got a Pico 1. That was just to get started, and when I wanted to switch Pico models to have my project working on another Pico architecture, I had to adjust everything, changing values of environment variables, and modifying configuration files, for the build to succeed. While going through all of that, I naturally created shell scripts to automate the process. Those scripts were the starting point for creating the Pico Build Kit, which contains working configuration files, Bash shell scripts, and directions explaining what you need to know to get started with Raspberry Pi Pico development, and using the Pico Build kit to greatly simply and streamline your development process. The kit ... Simplifies and streamlines development for the Raspberry Pi Pico series using the C SDK. Facilitates managing multiple projects supporting multiple Pico board architectures. Makes it easier to switch among Pico architectures (RP2040 or RP2350) and boards (Pico 1, Pico 1 W, Pico 2, Pico 2 W). Includes directions and shell scripts for installing ... The Raspberry Pi Pico C SDK, including examples RISC-V support for the RP2350 Support for the Raspberry Pi Debug Probe FreeRTOS Includes configuration files CMakeLists.txt for the following types of programs: simple, using a single CPU core multicore, using both CPU cores FreeRTOS, with support for multitasking and inter-task communication FreeRTOSConfig.h for both Pico architectures: RP2040 (Pico 1, Pico 1 W) RP2350 (Pico 2, Pico 2 W) Includes makefiles for simplifying the commands in the development cycle, including: 'make init' to completely rebuild a project Used on the initial build, or when changing Pico architectures (RP2040/RP2350 or ARM/RISC-V) 'make' for recompiling after small changes to code 'make install' for installing your program over the USB serial port 'make ocdinstall' for installing with the Raspberry Pi Debug Probe 'make debug' for source debugging with the Raspberry Pi Debug Probe 'make back' for simple backups, without needing source code control Includes shell scripts for simplifying the development cycle picp: Installing .uf2 binary on a Pico through the USB interface newpico: Create a new Pico project ocdinstall: Install .elf binary using the Raspberry Pi Debug Probe ocdstart, ocdstop: start and stop the OpenOCD daemon, for running GDB The remainder of this document consists of instructions for installing the Pico Build Kit, along with documentation on how to use it, in tutorial style. Follow the directions from beginning to end and you will have it up and running. This is an early release, so if you run into trouble and have a fix, please let me know! I developed on Debian 12 GNU/Linux, and tested on Debian 12 and 11, and the "bookworm" Raspberry Pi Operating System. DIRECTIONS ========== ENVIRONMENT VARIABLES --------------------- The first step is to set two environment variables, PICO_SDK_DIR and PICO_PROJECT_DIR. The Pico Build Kit uses these, and will not function correctly without them. The PICO_SDK_DIR Environment Variable ------------------------------------- PICO_SDK_DIR needs to be set to the directory where you want the SDK and related files to be put. After the installation completes, you will have some or all of the following placed there: pico-sdk The Pico C SDK. pico-sdk-tools Supporting tools for the SDK. pico-examples Example programs for Pico microcontrollers. pico-extras More example programs. picotool PicoTool, required for installing .uf2 files through the Pico's USB port. riscv-toolchain (optional) RISC-V compiler support, for using the RISC-V cores of the RP2350 (Pico 2). openocd (optional) OpenOCD, needed for supporting the Raspberry Pi Debug Probe FreeRTOS-Kernel (optional) FreeRTOS for the Pico. NOTE: There is a PICO_SDK_PATH environment variable, which is used by the C SDK. Its value is set by the Pico Build Kit to the path spec of the pico-sdk directory. The PICO_PROJECT_DIR Environment Variable ------------------------------------------ This is set to the directory where your Pico software development projects are kept, and the PicoBuildKit files are also located in this directory. You can use any directory that you have access to (read and write permissions) for PICO_SDK_DIR and PICO_PROJECT_DIR. As a suggestion, try putting PICO_SDK_DIR in PICO_PROJECT_DIR. This will simplify your directory structure, keeping all Pico-related files under one directory, and it will also make it easier for you to access examples and demos included in the Raspberry Pi repositories. The following examples will use this method. In order for the Pico Build Kit to operate, the directories need to exist. Create directories for PICO_PROJECT_DIR and PICO_SDK_DIR, like this: $ cd ~ $ mkdir Pico $ mkdir Pico/SDK and add the environment variable definitions to your ~/.bashrc, like this: export PICO_PROJECT_DIR=$HOME/Pico export PICO_SDK_DIR=$HOME/Pico/SDK Then either source ~/.bashrc, like this: $ source ~/.bashrc or log out and back in again. INSTALLING THE PICO BUILD KIT ----------------------------- If you have already cloned the Pico Build Kit Git repository, move the PicoBuildKit directory to PICO_PROJECT_DIR, like this: $ mv PicoBuildKit $PICO_PROJECT_DIR Otherwise, cd to PICO_PROJECT_DIR and clone the repository: $ cd $PICO_PROJECT_DIR $ git clone http://git.jayts.com/repos/PicoBuildKit.git The directory PicoBuildKit should now be in your PICO_PROJECT_DIR. SDK INSTALLATION ---------------- The next step is to install Debian packages and the official Raspberry Pi Pico C SDK and related utilities. This process has been greatly simplified by six Bash shell scripts in PicoBuildKit/install, which you run in order: 1-install-sdk 2-install-riscv-support 3-continue 4-install-openocd 5-install-freertos 6-build-examples It may be a good idea to update your system just before starting because some of the scripts may need to install packages on your Debian or Raspberry Pi system. If so, you will be asked for your password. If you are running an operating system that has a different package manager, edit the scripts to change the 'apt install' commands to whatever your Linux distribution or other operating system requires. Other than that, the Bash shell scripts should work on any Linux or Unix-like system. (If not, please let me know.) NOTE: Depending on whether your command search path includes the current directory (.), you may need to run the scripts specifying it explicitly. Either way, running the scripts like this will work: $ ./1-install-sdk $ ./2-install-riscv-support $ ./3-continue $ ./4-install-openocd $ ./5-install-freertos $ ./6-build-examples Directions for each installation shell script follow. 1-install-sdk This script installs the Raspberry Pi Pico C SDK and related things, including many example programs. If you have set PICO_SDK_DIR correctly, and the directory exists, you can run 1-install-sdk and it will install the SDK there. Or if for any reason you skipped setting PICO_SDK_DIR, it will install to the current directory. (If you want, you can use the installation scripts just to install the SDK, RISC-V support, OpenOCD, and FreeRTOS, and not use other parts of the Pico Build Kit.) After the script completes, you should have the following five directories in PICO_SDK_DIR: pico-examples pico-extras pico-sdk pico-sdk-tools picotool The main part of the SDK is in pico-sdk, and you can find example code in pico-examples and pico-extras. To get some examples to compile, you may need to run 'newpico' (see below) to create a project, then copy just the .c file(s) from the example to the project, and look for settings in the example's CMakeLists.txt file that need to be copied to the one automatically supplied by 'newpico'. The pico-sdk-tools directory contains files that are part of support for OpenOCD, the RISC-V compiler, and Picotool. The picotool directory contains the Picotool source code. Picotool is used in the SDK to make .uf2 files that you transfer to the Pico over USB to install your programs. It can do other useful things that the Pico Build Kit do not depend on, so you might want to learn more about it. NOTE: These scripts clone the current version of the repositories, which may have been updated by Raspberry Pi in some way that breaks the Pico Build Kit. Please let me know if this happens to you. I hope I can keep the Pico Build Kit updated, but I cannot guarantee anything. (It depends on whatever donations I receive and many other things.) 2-install-riscv-support 3-continue This step is optional. If you do not want to install RISC-V support just after running 1-install-sdk, you may do this step later or not at all. If you have a Pico 2 and want to run programs on its RISC-V cores, you will need to install the GNU C compiler and related programs to support it. As of the time of this writing, it does not work to install GNU RISC-V support through Debian's repositories because the RP2350 was not supported in GCC until version 14. This means we will have to install RISC-V support from the Raspberry Pi repositories, and compile GCC 14, to include RP2350 support with the C SDK. Compiling GCC is not simple, and it takes a long time. The 2-install-riscv-support clones the correct repository for GCC 14, then compiles and installs it. If you run into problems during the long compilation, you can interrupt it and restart it. For example, if you type a Control-C to quit the compilation, you can re-continue it by running the 3-continue script. It will restart the compilation to pick up from where it left off. Before starting 2-install-riscv-support, consider the number of cores and the amount of RAM you have on your computer. If you have many cores and not very many GB of RAM, you may run out of memory during the GCC build, resulting in your computer becoming very slow to respond, or the build will be automatically killed, while only part way through. There is a way to prevent this problem. The build for GCC is done by a script provided by Raspberry Pi: $PICO_SDK_DIR/pico-sdk-tools/packages/linux/riscv/build-riscv-gcc.sh The last line of this script is make -j$(nproc) which runs make using every available core of the computer. Each thread created by make consumes A LOT of memory! To prevent out of memory errors, edit the script and change the line to make -j2 to use only two cores, or even make if your system has only one or two GB of RAM installed, as on some Raspberry Pi computers or old laptops. Running a memory monitor program during the build will help you get an idea of how many cores you can use to speed the process, without running out of memory. Also, in the 3-continue script, there is the following line: ncpu=4 You may need to change "4" to a lower number. At this point, it probably goes without saying, but if you are planning to buy a Raspberry Pi 5 for doing Pico development, I suggest you get at least 8 GB of memory. I managed to install RISC-V support on a Raspberry Pi 3B with only 1 GB, but it took about 60 hours! I don't recommend trying that, but if you have a Pi 4 or 5, it should be a lot easier. 4-install-openocd OpenOCD (Open On-Chip Debugger) is required for using the Raspberry Pi Debug Probe for installing programs onto the Pico, and for source-level debugging. If you installed OpenOCD from the Debian repository, remove it. It lacks configuration files for the Pico. This script installs it from its official OpenOCD repository at openocd.org, and also installs gdb-multiarch, the version of GDB (GNU DeBugger) that supports multiple architectures, from the Debian repository. 5-install-freertos FreeRTOS (freertos.org) is an efficient real-time operating system that allows you to have multiple tasks run by a scheduler, with inter-task synchronization and communication. If you want to use the FreeRTOS, run this script to install it. 6-build-examples This script builds the example programs included in the SDK. Wait until a bit later to run this script because you need to have the environment variables PICO_BOARD and PICO_PLATFORM set properly first. That is done by running the 'usepico' script. NOTE: In this version of the Pico Build Kit, not all of the examples are compiled. In this release, the main purpose of the 6-build-examples is to check correctness of the C SDK installation. For now, wait until after you have used 'newpico' to create a project, and have run 'make init' to successfully build it, before doing this step. Then run 'usepico pico' and then run './6-build-examples'. Bash Shell Scripts ------------------ The following Bash shell scripts are included in the Pico Build Kit: usepico.bash picp newpico ocdinstall ocdstart ocdstop They are located in the PicoBuildKit/bin directory. To get started, change to that directory: $ cd $PICO_PROJECT_DIR/PicoBuildKit/bin The 'usepico.bash' Shell Script ------------------------------- The 'usepico.bash' script is different from the others. It is a shell script that defines a Bash function called 'usepico'. For it to work, it must be sourced (not just run as a program) so that the commands affect the environment of the current interactive shell, not just a subprocess. Source the usepico.bash script like this: $ source ./usepico.bash or $ . ./usepico.bash You will need to do this for every shell session, so you will probably want to add the following line to your ~/.bashrc file following where you set the PICO_PROJECT_DIR variable: source $PICO_PROJECT_DIR/PicoBuildKit/bin/usepico.bash Using 'usepico' --------------- The 'usepico' function sets or changes the Pico architecture that the SDK targets, to ensure the output of the build fits the architecture you want the program to run on. It is a requirement that you run 'usepico' to specify which Pico model (or RPxxxx architecture) you are targeting. Use the argument "pico" for the Pico 1, and "pico2" for the Pico 2, like this: $ usepico pico or $ usepico pico2 If you have the W model, then add "w" as the second argument: $ usepico pico w or $ usepico pico2 w If you are using a Pico 2 (RP2350), you can also add which cores to use: $ usepico pico2 w riscv or $ usepico pico2 riscv The default is to use the ARM cores, but if you changed it to RISC-V and want to return to using the ARM cores, $ usepico pico2 arm And if you already set the architecture to the Pico 2, you can just use "arm" or "riscv" as the single argument: $ usepico riscv $ usepico arm If you are working on a project and you change the type of Pico device you are targeting, run 'usepico', then do a complete rebuild of your project. Remove the contents of the build directory and rebuild your .elf and/or .uf2 files. The 'init' makefile target can be used to do that. $ make init There are just two more details. First, if you are using FreeRTOS, the FreeRTOSConfig.h file is different between the RP2040 and RP2350. If you run 'usepico' in the directory that contains your project source, along with the FreeRTOSConfig.h file, it will automatically change the symbolic link to point to the correct version of FreeRTOSConfig.h that is in the config directory. So assuming your project uses FreeRTOS, use 'usepico' like this: $ cd $PICO_PROJECT_DIR/ $ usepico NOTE: If you make any changes to your FreeRTOSConfig.h file, and you want to change architectures later, you need to apply the change to the other config/FreeRTOSConfig.h* file, or you not have that setting for the other architecture. Finally, you probably noticed that when you run 'usepico', it prints out something like Using pico2_w with rp2350-riscv The first string, "pico2_w" is the value of the environment variable PICO_BOARD, and the second is the value of PICO_PLATFORM. These are the environment variables used by the C SDK, and also the CMakeLists.txt files I have supplied, to configure Cmake and the SDK for the target platform you are using. If you run 'usepico' with no arguments, all it does is print that, telling you what platform is currently targeted. Suggestion: Run 'usepico' when you cd to the directory of any project, before building it, to make sure you are building for the correct platform. If you get it wrong, you may create a .uf2 and/or .elf file that you can load in your Pico, but it will mysteriously fail to run. Examples: If you have a (non-W) Pico 2, and you want to use the ARM cores, use this command: $ usepico pico2 The ARM cores are the default. To switch to the RISC-V cores, $ usepico riscv Now, to compile the project for a Pico W, $ usepico pico w After you have used 'usepico' to set your target architecture, you can run the 6-build-examples script from the SDK installation step to build the example programs for the Pico device you are currently using. To install the programs on your Pico device, the 'picp' and 'ocdinstall' shell scripts are included in the Pico Build Kit. The next section contains directions on how to install and use them. Installing the Shell Scripts ---------------------------- The shell scripts are located in PicoBuildKit/bin. A makefile also is in that directory to make it simpler to install the shell scripts. By default, the scripts are installed in /usr/local/bin. If you want them to reside in a different directory, edit the makefile and change the setting of the INSTALL_DIR variable. The scripts need to be installed to a directory in your command search path (specified by the PATH environment variable). If you created a new directory for holding the scripts, remember to add the directory to your PATH. Then install them with this command: $ make The 'newpico' Shell Script -------------------------- The 'newpico' shell script creates a new Pico project. Before running it, run the 'usepico' script to set up an initial Pico architecture to target. 'newpico' will ask you whether you want to create a single-core project, multicore project, or FreeRTOS project. The default is a single-cpu project, which is the simplest and easiest way to get started with Pico programming. Multicore projects allow you to use both CPU cores, although you have to manage the tasks running on each core yourself. FreeRTOS projects have a little more overhead, in return for easier task and synchronization management. To use 'newpico', give it the name of your project as the argument, like this: $ newpico myproject replacing "myproject" with the name you choose for your project. (For the following examples, I will stick with "myproject" for the project name.) 'newpico' creates a directory by that name in your $PICO_PROJECT_DIR directory, and copies files from the PicoBuildKit/ProjectTemplate directory to start you off. After 'newpico' completes, the directory contains the following files and directories: myproject.c C source file for your project CMakeLists.txt Cmake configuration file. Symbolic link to file in config. makefile Configuration file for make(1) build/ Directory for the build. Your .elf and/or .uf2 files are placed here. config/ Directory containing alternates for makefile, CMakeLists.txt, and FreeRTOSConfig.h .bak/ Local backup directory. Contains the 'new' shell script. Additionally, if you created a FreeRTOS project, there will be a symbolic link named FreeRTOSConfig.h. That points to either config/FreeRTOSConfig.h-RP2040 or config/FreeRTOSConfig.h-RP2040. The build directory is empty at first, and is populated by Cmake and make when you build the project. If you want to change the name of the directory, it will not affect the operation of the Pico Build Kit. However, the name of the source file is used in the makefile, CMakeLists.txt, and .bak/new. If you want to change it, you must also modify those files and also change the name there. And that includes the other versions of CMakeLists.txt and makefile in the config directory, just in case you need them in the future. After running 'newpico', you can check it by changing to the project directory, and running 'make init', like this; $ cd myproject $ make init It will run Cmake and make, and you should see myproject.elf and myproject.uf2 in the build directory. The 'picp' Shell Script ----------------------- The 'picp' script is for loading your Pico program into the Pico to run it. It is very simple, and automates part of the process: 1. Press the BOOTSEL button on the Pico, and hold it down while inserting the USB cable. 2. Wait for the Pico's filesystem to mount. (You may need to click in a dialog for this, so if your GUI desktop allow it, it is best to USB devices automatically.) Then release the BOOTSEL button. 3. Copy the .uf2 file produced by the build to either /media/$USER/RPI-RP2, or /media/$USER/RP2350, depending on the model of Pico. The file will transfer into the Pico's flash memory, then the program will start running. You still need to do the first two steps, but the third step can be replaced by $ cd build $ picp The script takes care of using the correct name of the destination directory, in accordance with what you specified in your 'usepico' command. And if they do not match, it will print an error message, rather than copy a .uf2 file for the wrong architecture. It may seem like not much is saved, but just try it and see if you like it. In practice, I have found it makes the step a lot easier, and it helps avoid mistakes. There is an "install" target in the makefile, so you do not need to cd, just stay in the source directory and type $ make install or $ make picp After installing the .uf2 file in your Pico, open a new terminal window and run minicom like this: $ minicom -D /dev/ttyACM0 to see standard output inside a terminal window. The program will print hello, world! You will probably need to unplug the device and plug it back again to run the program after you have minicom already running. If you find minicom difficult to use, you may prefer my 'ucom' ("Microcom") program, which is simpler and made for communicating with microcontrollers. You can start Microcom before starting the Pico program, and it will wait for the Pico's USB serial device to appear, rather than just exit (as minicom does) if the device is not yet present. You can get Microcom with $ git clone http://git.jayts.com/repos/ucom.git Then compile with $ make The executable is called ucom. If you have only one USB serial port, just run $ sudo ucom and start your Pico program running. If more than one /dev/ttyACM device is in use, you can select it by giving ucom the number of the port as its argument. For example, $ sudo ucom 2 opens /dev/ttyACM2. Exit Microcom by typing a Control-C. You can avoid using sudo by adding yourself to the dialout group, as explained in the next section. Support for the Raspberry Pi Debug Cable ======================================== The 'ocdinstall', 'ocdstart', and 'ocdstop' Shell Scripts --------------------------------------------------------- These three scripts make it a lot easier to use the Raspberry Pi Debug Cable. The 'ocdinstall' script installs the .elf file created by the build process into the Pico, using the UART connection. You must have the UART cable (not just the debug cable) connected properly. The UART cable connects to pins 1-3 of the Pico. Also, to avoid the need for 'sudo' every time you install, add yourself to the dialout group, like this: $ sudo usermod -a -G dialout USERNAME where USERNAME is replaced by your username. Log out and back in again. You now have access to /dev/ttyACMxxx, which is used by OpenOCD, and also by the Pico when standard I/O is configured to use its USB port. Once you have it set up, you can install your program with the command $ ocdinstall .elf When installing this way, you do not need to disconnect the Pico's USB power cable or press the BOOTSEL button. To make it even simpler, there is a make target in the makefile called "ocdinstall", so in the project's source code directory, simply run $ make ocdinstall NOTE: If you are using a Pico 2 (RP2350) and are changing from the ARM to RISC-V cores or vice-versa, 'ocdinstall' may fail. If that happens, use 'picp' to install the program through the Pico's USB port to re-synchronize the Pico core selection with OpenOCD. After that, you may use 'ocdinstall' successfully. (It is unknown at the time of this writing exactly why this problem exists, but it seems to happen when the program currently in the Pico uses different cores than the program you are trying to install with OpenOCD.) For source-level debugging, first run the 'ocdstart' program to get the OpenOCD daemon running, then 'gdb-multiarch' to start the debugger. When you are finished, you can run 'ocdstop' to kill the OpenOCD daemon. This process is simplified by the 'debug' make target, so you can just type $ make debug It will start the daemon and GDB, and kill the daemon after GDB exits. Configuration Files =================== Besides your C source code, your project contains one or more configuration files required for the build process. CMakeLists.txt -------------- The C SDK uses Cmake, so you need a CMakeLists.txt file to configure it. If you look in the PicoBuildKit/config directory, you will see the following files that can be used as CMakeLists.txt: CMakeLists.txt-singlecpu CMakeLists.txt-multicore CMakeLists.txt-FreeRTOS The 'newpico' program chooses one of them and uses it to create a symbolic link called CMakeLists.txt in your project's source directory. There are a few things you may need to change as you develop your project. Near start of CMakeLists.txt, the project name is set: set(PROJECT_NAME myproject) If you change the name of the C source file, you will need to modify this line to match. If you want to add compiler options, find the line #add_compile_options(-Wall) Remove the '#' that comments it out and then change "-Wall" to the options you want to add. Note that if you enable -Wall, you may get spurious warnings during the build because not all of the code supplied by Raspberry Pi compiles without warnings. You will probably want to add additional C source files to your project. You will also need to add the names of those files to a list in CMakeLists.txt. Look for the add_executable() line: add_executable(${PROJECT_NAME} ) and add the file names to , which starts out with just one file. If you need to link with any libraries other than basic ones, add them to the list in target_link_libraries(${PROJECT_NAME} ) makefile -------- For your convenience, the Pico Build Kit supplies a makefile with targets for building, installing, debugging, that simply the development cycle. There is no requirement to build your project with 'make', and you are free to run the commands to build your project manually, or by any other method. Look in the PicoBuildKit/config directory, and you will see the files makefile makefile.FreeRTOS 'makefile' is for single- and multicore projects, and makefile.FreeRTOS is copied to 'makefile' in your source directory for FreeRTOS projects. There are some things you may want (or need) to customize in your makefile as you develop your project, and the supplied makefile is just a starting point. One thing you may want to change is to configure it for the number of cores your computer's CPU has. If you do not already know the number, try either of these commands: $ nproc $ lscpu | grep "^CPU(s):" | sed -e 's/^[^0-9]*//' Then, in the makefile, look for the line MAKE_OPTS=-j4 and change the "4" to the number of cores in your computer. The -j option specifies how many concurrent threads for the compiler to run, and it is ok to set it higher than the number of cores you have. The 'newpico' program sets the name of the directory and the C source file to the name you gave it as the project name. If you want to rename the C file, you will also need to edit the makefile and CMakeLists.txt file to match. Look in makefile for the following line: PROJECT_NAME= where is your project name. Replace the original with your new name. The targets in the makefile can be used as follows: make init This deletes any previous build and creates a new one from scratch. Use 'make init' after running 'usepico' to change to a different Pico board model (Pico or Pico 2) or Pico architecture (RP2040 or RP2350). 'make init' runs Cmake, then changes to the build directory and runs 'make'. After it completes, the outputs (.elf, .uf2, and other files) will be in the build directory, and are ready to be installed and run on your device. make If you just need to recompile after making some source file edits, just use 'make'. make install make picp These targets are aliases of each other, and are for copying your .uf2 file to the device over its USB port. See the documentation for the 'picp' program for details. make ocdinstall make debug These are for use with the Raspberry Pi Debug cable. They are documented in the section about shell scripts, titled "Support for the Raspberry Pi Debug Cable". make clean This removes the contents of the build directory. You might want to do this, for example, just before archiving your project's source files. make back This will make a backup of your source and configuration files to the (hidden) .bak directory. As you add files to your project, add their names to the list in the makefile. Also, the .bak directory contains a script named 'new', which archives the backed-up files there to a directory, to create a backup point. To use this simple backup and archiving method, first run $ make back then cd to the .bak directory and run 'new' to archive the files $ cd .bak $ new A directory named 00001 is created and the backup files are moved to it. Now you can make more backups, and when you reach a milestone, or are just "paranoid", you can run 'new' to create a archives named sequentially. Again, remember to add file names to the lists in the makefile and .bak/new as you add files to your project. FreeRTOSConfig.h ---------------- If you are using FreeRTOS in your project, you will need a FreeRTOSConfig.h file in the same directory as your source code. When you create a new FreeRTOS project with 'newpico', it copies one file each for the RP2040 and RP2350 into the config directory of your project, then adds a symbolic link from one of them to FreeRTOSConfig.h, in accordance with the architecture you specified with the 'usepico' command. As explained earlier, if you run 'usepico' in your project directory, it will manage that symlink to keep it pointed to the version that matches your device's architecture. If you edit and modify FreeRTOSConfig.h, you will need to update the other file as appropriate. The files provided in the Pico Build Kit are modified versions of the ones found in the Raspberry Pi FreeRTOS distribution located at https://github.com/raspberrypi/FreeRTOS-Kernel. I suggest taking a look at FreeRTOSConfig.h to see the changes I made. For example, I set configCPU_CLOCK_HZ to 125 MHz for the Pico 1 and 150 MHz for the Pico 2. If you try overclocking, it is a very good idea to change this setting in your FreeRTOSConfig.h. Also, I chose 1000 Hz (1 KHz) for configTICK_RATE_HZ for finer-grained multitasking. You might want to set it back to the original 100 Hz if your app is not as demanding. There may be other settings you want to return to their original values, or customize yourself. I had to disable some things just to get the Raspberry Pi SDK code to compile. I suspect this may change in future releases of the Pico C SDK or Raspberry Pi's release of FreeRTOS. Project Management ------------------ If you modify anything in CMakeLists.txt, FreeRTOSConfig.h, or the makefile, remember to add the modification the corresponding files in the config directory so you can easily change project types or architectures later. Finally ------- If you find a problem and especially if you have a fix, you can contact me at jay@jayts.com or use my website's Contact form. Also, I very much appreciate donations! It will help support me and my work. You can use any of these: Venmo @Jay-Ts Paypal jay@jayts.com Bitcoin bc1qdgv2auhdg6mhtekgz7eh5p0whm3k7prrqvl395 I hope this helps you.