Skip to content

Commit 27ca2e6

Browse files
committed
Add "smoke test" firmware compilation CI workflows
On every push or pull request that affects firmware or bootloader source files, and periodically, compile them.
1 parent 66adc09 commit 27ca2e6

File tree

2 files changed

+108
-0
lines changed

2 files changed

+108
-0
lines changed
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Compile Bootloader
2+
3+
# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows
4+
on:
5+
push:
6+
paths:
7+
- ".github/workflows/compile-bootloader.yml"
8+
- "extras/D11-Bootloader/**"
9+
pull_request:
10+
paths:
11+
- ".github/workflows/compile-bootloader.yml"
12+
- "extras/D11-Bootloader/**"
13+
schedule:
14+
# Run every Tuesday at 8 AM UTC to catch breakage caused by changes to external resources (libraries, platforms).
15+
- cron: "0 8 * * TUE"
16+
workflow_dispatch:
17+
repository_dispatch:
18+
19+
jobs:
20+
build:
21+
name: ${{ matrix.board.fqbn }}
22+
runs-on: ubuntu-latest
23+
24+
strategy:
25+
fail-fast: false
26+
27+
matrix:
28+
board:
29+
- fqbn: arduino:samd:mkrmotorshield:bootloader=0kb,pinmap=complete,lto=disabled
30+
platforms: |
31+
# Install MattairTech_Arduino:samd via Boards Manager for the toolchain
32+
- name: MattairTech_Arduino:samd
33+
source-url: https://www.mattairtech.com/software/arduino/package_MattairTech_index.json
34+
# This needs to match with the version of MattairTech_Arduino:samd the Arduino fork is based on in order to get the right tool versions
35+
version: 1.6.16
36+
# Install the platform with Motor Carrier support
37+
- name: arduino:samd
38+
source-url: https://github.com/arduino/ArduinoCore-samd.git
39+
version: mkrmotorcarrier
40+
41+
steps:
42+
- name: Checkout repository
43+
uses: actions/checkout@v2
44+
45+
- name: Compile bootloader
46+
uses: arduino/compile-sketches@v1
47+
with:
48+
github-token: ${{ secrets.GITHUB_TOKEN }}
49+
fqbn: ${{ matrix.board.fqbn }}
50+
platforms: ${{ matrix.board.platforms }}
51+
libraries: |
52+
- name: Sodaq_wdt
53+
sketch-paths: |
54+
- extras/D11-Bootloader
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Compile Firmware
2+
3+
# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows
4+
on:
5+
push:
6+
paths:
7+
- ".github/workflows/compile-firmware.yml"
8+
- "extras/D11-Firmware/**"
9+
pull_request:
10+
paths:
11+
- ".github/workflows/compile-firmware.yml"
12+
- "extras/D11-Firmware/**"
13+
schedule:
14+
# Run every Tuesday at 8 AM UTC to catch breakage caused by changes to external resources (libraries, platforms).
15+
- cron: "0 8 * * TUE"
16+
workflow_dispatch:
17+
repository_dispatch:
18+
19+
jobs:
20+
build:
21+
name: ${{ matrix.board.fqbn }}
22+
runs-on: ubuntu-latest
23+
24+
strategy:
25+
fail-fast: false
26+
27+
matrix:
28+
board:
29+
- fqbn: arduino:samd:mkrmotorshield:bootloader=0kb,pinmap=complete,lto=disabled
30+
platforms: |
31+
# Install MattairTech_Arduino:samd via Boards Manager for the toolchain
32+
- name: MattairTech_Arduino:samd
33+
source-url: https://www.mattairtech.com/software/arduino/package_MattairTech_index.json
34+
# This needs to match with the version of MattairTech_Arduino:samd the Arduino fork is based on in order to get the right tool versions
35+
version: 1.6.16
36+
# Install the platform with Motor Carrier support
37+
- name: arduino:samd
38+
source-url: https://github.com/arduino/ArduinoCore-samd.git
39+
version: mkrmotorcarrier
40+
41+
steps:
42+
- name: Checkout repository
43+
uses: actions/checkout@v2
44+
45+
- name: Compile firmware
46+
uses: arduino/compile-sketches@v1
47+
with:
48+
github-token: ${{ secrets.GITHUB_TOKEN }}
49+
fqbn: ${{ matrix.board.fqbn }}
50+
platforms: ${{ matrix.board.platforms }}
51+
libraries: |
52+
-
53+
sketch-paths: |
54+
- extras/D11-Firmware/D11-Firmware.ino

0 commit comments

Comments
 (0)