Skip to content

Commit

Permalink
Added support for Teensy CI (#5)
Browse files Browse the repository at this point in the history
* Added support for Teensy CI

* Updates

* Update
  • Loading branch information
pablogs9 authored Oct 26, 2020
1 parent 68ffb28 commit 7954b55
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ jobs:
with:
path: checkout/

- name: Build OpenCR
- name: Build OpenCR and Teensy 3.2/4.1
run: |
apt update
apt install -y git curl lib32z1 wget
apt install -y git curl lib32z1 wget libfontconfig libxft2 xz-utils rsync
curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh | sh
mkdir -p /github/home/Arduino/libraries/micro_ros_arduino-0.0.1/
cp -R checkout/* /github/home/Arduino/libraries/micro_ros_arduino-0.0.1/
Expand All @@ -28,6 +28,21 @@ jobs:
- https://raw.githubusercontent.com/ROBOTIS-GIT/OpenCR/master/arduino/opencr_release/package_opencr_index.json''' > arduino-cli.yaml
export PATH=$PATH:/github/workspace/bin:/__w/micro_ros_arduino/micro_ros_arduino/bin
arduino-cli core install OpenCR:OpenCR -v
wget https://downloads.arduino.cc/arduino-1.8.13-linux64.tar.xz
tar -xf arduino-1.8.13-linux64.tar.xz
wget https://www.pjrc.com/teensy/td_153/TeensyduinoInstall.linux64
chmod 755 TeensyduinoInstall.linux64
./TeensyduinoInstall.linux64 --dir=arduino-1.8.13
# Faking loader
TRUE_PATH=$(which true)
rm -rf arduino-1.8.13/hardware/tools/teensy_post_compile
cp $TRUE_PATH arduino-1.8.13/hardware/tools/teensy_post_compile
cp -R arduino-1.8.13/hardware/teensy/ /github/home/.arduino15/packages/
rsync -a arduino-1.8.13/hardware/tools/ /github/home/.arduino15/packages/tools/
rm -rf arduino-1.8.13
curl https://raw.githubusercontent.com/micro-ROS/micro_ros_arduino/foxy/extras/library_generation/platform_teensy.txt > /github/home/.arduino15/packages/teensy/avr/platform.txt
arduino-cli core update-index
arduino-cli lib update-index
arduino-cli compile --fqbn OpenCR:OpenCR:OpenCR /github/home/Arduino/libraries/micro_ros_arduino-0.0.1/examples/micro-ros_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy31 /github/home/Arduino/libraries/micro_ros_arduino-0.0.1/examples/micro-ros_publisher -v
arduino-cli compile --fqbn teensy:avr:teensy41 /github/home/Arduino/libraries/micro_ros_arduino-0.0.1/examples/micro-ros_publisher -v

0 comments on commit 7954b55

Please sign in to comment.