-
Notifications
You must be signed in to change notification settings - Fork 29
87 lines (79 loc) · 3.07 KB
/
ArduinoBuild.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# ArduinoBuild.yml
#
# Github workflow script that compiles all examples from the OpenMRNLite
# Arduino library.
#
# Copyright (C) 2021 Balazs Racz
#
# Name of workflow
name: ArduinoBuild
on:
push:
paths:
- '**.ino'
- '**rduino**'
- '**ArduinoBuild.yml'
pull_request:
jobs:
build-stm32:
name: Build Arduino STM32 examples
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@master
- name: Generate OpenMRNLite library
run: |
mkdir --parents $HOME/Arduino/libraries/OpenMRNLite
$GITHUB_WORKSPACE/arduino/libify.sh $HOME/Arduino/libraries/OpenMRNLite $GITHUB_WORKSPACE -f
rm -f $GITHUB_WORKSPACE/arduino/examples/Stm*/build_opt.h
- name: Compile STM32 examples
uses: ArminJo/arduino-test-compile@v3
with:
platform-url: https://raw.githubusercontent.com/stm32duino/BoardManagerFiles/master/STM32/package_stm_index.json
arduino-board-fqbn: STM32:stm32:Nucleo_144:pnum=NUCLEO_F767ZI,upload_method=MassStorage,xserial=generic,usb=CDCgen,xusb=FS,opt=osstd,rtlib=nano
sketch-names: Stm32*.ino
build-properties: '{ "All": "-DHAL_CAN_MODULE_ENABLED" }'
debug-compile: true
required-libraries: OpenMRNLite
build-esp32:
name: Build Arduino ${{ matrix.target }} examples
runs-on: ubuntu-latest
strategy:
max-parallel: 2
matrix:
target: [esp32, esp32c3, esp32s2]
steps:
- name: Checkout
uses: actions/checkout@master
- name: Generate OpenMRNLite library
run: |
mkdir --parents $HOME/Arduino/libraries/OpenMRNLite
$GITHUB_WORKSPACE/arduino/libify.sh $HOME/Arduino/libraries/OpenMRNLite $GITHUB_WORKSPACE -f
rm -f $GITHUB_WORKSPACE/arduino/examples/Stm*/build_opt.h
- name: Compile ESP32 examples
uses: ArminJo/arduino-test-compile@v3
with:
platform-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
arduino-board-fqbn: esp32:esp32:node32s
sketch-names: ESP32CanLoadTest.ino,ESP32IOBoard.ino,ESP32SerialBridge.ino,ESP32WifiCanBridge.ino
debug-compile: true
required-libraries: OpenMRNLite
if: ${{ matrix.target == 'esp32' }}
- name: Compile ESP32-C3 examples
uses: ArminJo/arduino-test-compile@v3
with:
platform-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
arduino-board-fqbn: esp32:esp32:esp32c3
sketch-names: ESP32C3CanLoadTest.ino,ESP32C3IOBoard.ino
debug-compile: true
required-libraries: OpenMRNLite
if: ${{ matrix.target == 'esp32c3' }}
- name: Compile ESP32-S2 examples
uses: ArminJo/arduino-test-compile@v3
with:
platform-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
arduino-board-fqbn: esp32:esp32:esp32s2
sketch-names: ESP32S2CanLoadTest.ino,ESP32S2IOBoard.ino
debug-compile: true
required-libraries: OpenMRNLite
if: ${{ matrix.target == 'esp32s2' }}