Skip to content

Commit

Permalink
Merge pull request #26 from maehw/main
Browse files Browse the repository at this point in the history
Let CI pipeline take care of firmware builds
  • Loading branch information
Staacks authored Jan 22, 2024
2 parents 0ad6aec + 05396ed commit 9884399
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
33 changes: 33 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Build gbinterceptor firmware
on:
push:
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@main
- name: Setup arm-none-eabi-gcc
uses: carlosperate/arm-none-eabi-gcc-action@v1
- name: Setup ninja
uses: seanmiddleditch/gha-setup-ninja@master
- name: Clone pico-sdk dependency (pinned versions of pico-sdk and tinyusb)
run: |
git clone https://github.com/raspberrypi/pico-sdk --recurse-submodules
cd pico-sdk && sudo git checkout tags/1.5.1 && cd ..
cd pico-sdk/lib/tinyusb && sudo git checkout 0.16.0 && cd ../../..
- name: Build firmware
run: |
arm-none-eabi-gcc --version
cd ./firmware
mkdir build && cd build
cmake .. -G Ninja -DPICO_SDK_PATH=../../pico-sdk
ninja
- name: 'Upload artifacts'
uses: actions/upload-artifact@v3
with:
name: firmware
path: |
./firmware/build/gb_interceptor.*
retention-days: 7
3 changes: 2 additions & 1 deletion firmware/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
#include "pico/multicore.h"
#include "pico/mutex.h"

#include "bsp/board.h"
#include "bsp/rp2040/board.h"
#include "bsp/board_api.h"
#include "tusb.h"
#include "usb_descriptors.h"
#include "hardware/clocks.h"
Expand Down

0 comments on commit 9884399

Please sign in to comment.