-
Notifications
You must be signed in to change notification settings - Fork 117
executable file
·97 lines (90 loc) · 8.11 KB
/
ci.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
88
89
90
91
92
93
94
95
96
name: CI
on:
pull_request:
branches:
- '**'
jobs:
micro_ros_arduino:
runs-on: ubuntu-20.04
container: ubuntu:20.04
steps:
- uses: actions/checkout@v4
with:
path: checkout/
- name: Build
run: |
apt update
apt install -y git curl lib32z1 wget libfontconfig libxft2 xz-utils rsync python-is-python3 python3-pip
pip3 install pyserial
curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh | sh -s 0.31.0
mkdir -p /github/home/Arduino/libraries/micro_ros_arduino/
cp -R checkout/* /github/home/Arduino/libraries/micro_ros_arduino/
echo '''board_manager:
additional_urls:
- https://raw.githubusercontent.com/ROBOTIS-GIT/OpenCR/master/arduino/opencr_release/package_opencr_index.json
- https://github.com/espressif/arduino-esp32/releases/download/2.0.2/package_esp32_index.json
- https://www.pjrc.com/teensy/package_teensy_index.json
- https://files.seeedstudio.com/arduino/package_seeeduino_boards_index.json''' > arduino-cli.yaml
curl -fsSL https://raw.githubusercontent.com/ROBOTIS-GIT/OpenCR/master/arduino/opencr_release/package_opencr_index.json -o /github/home/.arduino15/package_opencr_index.json
curl -fsSL https://github.com/espressif/arduino-esp32/releases/download/2.0.2/package_esp32_index.json -o /github/home/.arduino15/package_esp32_index.json
curl -fsSL https://www.pjrc.com/teensy/package_teensy_index.json -o /github/home/.arduino15/package_teensy_index.json
curl -fsSL https://files.seeedstudio.com/arduino/package_seeeduino_boards_index.json -o /github/home/.arduino15/package_seeeduino_boards_index.json
export PATH=$PATH:/github/workspace/bin:/__w/micro_ros_arduino/micro_ros_arduino/bin
arduino-cli core install OpenCR:OpenCR -v
arduino-cli core install arduino:samd -v
arduino-cli core install arduino:sam -v
arduino-cli core install arduino:mbed_giga -v
arduino-cli core install arduino:mbed_rp2040 -v
arduino-cli core install arduino:mbed_portenta -v
arduino-cli core install arduino:renesas_uno -v
arduino-cli core install arduino:mbed_nano -v
arduino-cli core install esp32:esp32 -v
arduino-cli core install teensy:[email protected] -v
arduino-cli core install Seeeduino:samd -v
#
# PATCHING TEENSY AND SAM
cat checkout/extras/patching_boards/platform_teensy.txt > /github/home/.arduino15/packages/teensy/hardware/avr/1.59.0/platform.txt
# remove when https://github.com/arduino/ArduinoCore-sam/pull/115 merged
cat checkout/extras/patching_boards/platform_arduinocore_sam.txt > /github/home/.arduino15/packages/arduino/hardware/sam/1.6.12/platform.txt
#
# BUILDING EXAPLE FOR EACH PLATFORM
arduino-cli core update-index
arduino-cli lib update-index
arduino-cli lib install WiFiNINA
arduino-cli lib install "STM32duino X-NUCLEO-IKS01A3"
arduino-cli lib install "Seeed Arduino rpcWiFi" # Dependent libraries(e.g. "Seeed Arduino rpcUnified") will be installed together. See https://wiki.seeedstudio.com/Wio-Terminal-Network-Overview/#needed-libraries-for-wi-fi for more details.
arduino-cli lib install WiFiEspAT
# Build all demos
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_addtwoints_service -v
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_reconnection_example -v
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_subscriber -v
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_subscriber_twist -v
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_tf_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy41 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_time_sync -v
arduino-cli compile --fqbn teensy:avr:teensy41 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_types_handling -v
# Build one demo for each platform
arduino-cli compile --fqbn arduino:mbed_nano:nanorp2040connect /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:mbed_nano:nanorp2040connect /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_decibels -v
arduino-cli compile --fqbn arduino:mbed_nano:nanorp2040connect /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_IMU_ML -v
arduino-cli compile --fqbn arduino:mbed_nano:nanorp2040connect /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi -v
arduino-cli compile --fqbn teensy:avr:teensy31 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy35 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy36 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy41 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy40 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:samd:arduino_zero_native /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:sam:arduino_due_x /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
# arduino-cli compile --fqbn arduino:mbed:envie_m4 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:mbed_portenta:envie_m7 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:mbed_portenta:envie_m7 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi -v
arduino-cli compile --fqbn esp32:esp32:esp32 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn esp32:esp32:esp32 /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi -v
arduino-cli compile --fqbn Seeeduino:samd:seeed_wio_terminal /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi -v
arduino-cli compile --fqbn arduino:mbed_giga:giga /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:mbed_giga:giga /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi -v
arduino-cli compile --fqbn arduino:renesas_uno:minima /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:renesas_uno:unor4wifi /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher -v
arduino-cli compile --fqbn arduino:renesas_uno:unor4wifi /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi -v
# Build micro-ros_publisher-wifi_at for WiFi non-native board with ESP-AT
arduino-cli compile --fqbn arduino:mbed_rp2040:pico /github/home/Arduino/libraries/micro_ros_arduino/examples/micro-ros_publisher_wifi_at -v