Continuous Integration and Continuous Delivery (CI/CD) is the process of automating the testing and deployment of a software project. It is often used in large-scale, multi-person projects, but it can be useful in smaller projects and embedded firmware development. This tutorial dives into continuous deployment, which is a logical next step in the continuous delivery process.
We demonstrate how to automatically build Raspberry Pi Pico firmware using Docker and GitHub Actions. The compiled binary is then hosted on a GitHub project releases page for end users to download and immediately flash to their boards.
You can view a written version of this tutorial here: [ Ссылка ]
Code for this tutorial can be found here: [ Ссылка ]
Getting started with the Raspberry Pi Pico PDF: [ Ссылка ]
Previously, we looked at running modularized containers with Docker ([ Ссылка ]) as well as building simple GitHub Actions workflows ([ Ссылка ]). We will build on these concepts by creating an automated build process inside a Docker image.
Often, part of the CI/CD pipeline is to push compiled software to end users. This might include over-the-air updates to smartphones or operating systems, or it could refer to pushing a new version to servers for further testing or final integration (e.g. going live in production). However, this is often difficult in many embedded systems, as many microcontrollers do not include easy over-the-air updating capabilities. A decent substitute is to automatically generate a binary that users can simply flash to their microcontrollers.
The Raspberry Pi Pico build system is incredibly easy to set up on Linux, so we use that as a demonstration when writing a simple Dockerfile. The Docker image needs to install the entire toolchain and build the project. We then use a Docker command to copy out the compiled binary.
With GitHub Actions, we can automate the Docker build process so that the binary can be hosted on the GitHub project page. This allows users to download new versions of the software without needing to compile the project from source (and as a result, needing to install the toolchain themselves).
Product Links:
Raspberry Pi Pico - [ Ссылка ]
Related Videos:
Intro to CI/CD Part 1 - Getting Started with Docker: [ Ссылка ]
Intro to CI/CD Part 2 - Getting Started with GitHub Actions: [ Ссылка ]
Intro to CI/CD Part 3 - Getting Started with Unit Testing: [ Ссылка ]
Related Project Links:
Getting Started with Docker - [ Ссылка ]
Getting Started with GitHub Actions - [ Ссылка ]
Writing C/C++ Unit Tests with CppUTest - [ Ссылка ] 5cf06163537
Related Articles:
How to Install and Get Started with Node-RED - [ Ссылка ]
Learn more:
Maker.io - [ Ссылка ] Digi-Key’s Blog – TheCircuit [ Ссылка ] Connect with Digi-Key on Facebook [ Ссылка ] And follow us on Twitter [ Ссылка ]
00:00 - Intro
00:29 - Overview of Continuous Deployment
04:00 - Create a Raspberry Pi Pico Blinky Program
08:13 - Use Docker to Build the Blinky Program
16:08 - Create a GitHub Actions Workflow to Build the Program
24:54 - Write the CHANGELOG and README
27:08 - Test Continuous Deployment with GitHub Actions
31:24 - Conclusion
![](https://s2.save4k.ru/pic/3ccQ_0YeZX4/maxresdefault.jpg)