rusefi/.github/workflows/hardware-ci.yaml

96 lines
3.2 KiB
YAML
Raw Normal View History

2021-07-24 13:23:03 -07:00
name: HW CI
on: [push, pull_request]
jobs:
build-firmware:
2021-06-21 05:56:23 -07:00
strategy:
# Let all builds finish even if one fails early
fail-fast: false
matrix:
2024-02-18 22:47:43 -08:00
build-target: [f407-discovery, proteus_f4, proteus_f7]
2021-06-21 05:56:23 -07:00
include:
- build-target: f407-discovery
runs-on: hw-ci-f4-discovery
test-suite: com.rusefi.HwCiF4Discovery
folder: config/boards/f407-discovery
openocd-script: ../.github/workflows/openocd_ci_f4_discovery.cfg
serial-device: /dev/serial/by-id/usb-rusEFI_LLC_rusEFI_Engine_Management_ECU_2B003B000A51343033393930-if01
2021-06-21 05:56:23 -07:00
2024-02-18 22:47:43 -08:00
- build-target: proteus_f4
runs-on: hw-ci-proteus
test-suite: com.rusefi.HwCiProteus
folder: config/boards/proteus
openocd-script: ../.github/workflows/openocd_ci_proteus_f4.cfg
serial-device: /dev/serial/by-id/usb-rusEFI_LLC_rusEFI_Engine_Management_ECU_41003D000451383037343335-if01
2024-02-18 21:28:27 -08:00
- build-target: proteus_f7
runs-on: hw-ci-proteus-f7
test-suite: com.rusefi.HwCiProteus
folder: config/boards/proteus
openocd-script: ../.github/workflows/openocd_ci_proteus_f7.cfg
serial-device: /dev/serial/by-id/usb-rusEFI_LLC_rusEFI_Engine_Management_ECU_38002D0005504B4634303120-if01
2023-07-23 20:03:49 -07:00
2021-06-21 05:56:23 -07:00
runs-on: ${{matrix.runs-on}}
steps:
- uses: actions/setup-java@v4
2023-07-02 15:51:45 -07:00
with:
distribution: 'zulu'
java-version: '11'
- uses: actions/checkout@v4
- name: Checkout Submodules
run: |
git submodule update --init --depth=1 firmware/ChibiOS
git submodule update --init --depth=1 firmware/ChibiOS-Contrib
git submodule update --init --depth=1 firmware/libfirmware
git submodule update --init --depth=1 firmware/ext/lua
git submodule update --init --depth=1 firmware/ext/uzlib
git submodule update --init --depth=1 firmware/controllers/lua/luaaa
git submodule update --init --depth=1 firmware/controllers/can/wideband_firmware
git submodule update --init --depth=1 java_console/peak-can-basic
- name: Identify Agent
run: uname -a
2023-06-25 08:03:46 -07:00
- name: Acquire GCC
uses: carlosperate/arm-none-eabi-gcc-action@v1
with:
2024-01-02 14:34:33 -08:00
release: '12.3.Rel1'
# Make sure the compiler works
- name: Test/Identify Compiler
run: arm-none-eabi-gcc -v
- name: Build Firmware
2023-07-03 21:05:54 -07:00
run: .github/workflows/hw-ci/build_for_hw_ci.sh ${{matrix.folder}} ${{matrix.build-target}}
- name: Check for STLINK
run: lsusb | grep 'ST-LINK\|STLINK'
- name: OpenOCD wipe & flash STM32
2023-07-04 06:49:16 -07:00
run: .github/workflows/hw-ci/openocd_wipe_and_flash.sh ${{matrix.openocd-script}}
2024-02-18 04:51:44 -08:00
- name: Show USB status
2024-02-18 22:07:27 -08:00
run: |
lsusb
ls -l /dev/serial/by-id/
2024-02-18 04:51:44 -08:00
2023-11-01 13:27:34 -07:00
- name: Upload build bin artifact
uses: actions/upload-artifact@v4
2023-11-01 13:27:34 -07:00
with:
name: rusefi_hw-ci-${{matrix.build-target}}.bin
2024-02-05 15:30:07 -08:00
path: ./firmware/build/rusefi*.bin
2023-11-01 13:27:34 -07:00
2023-07-03 21:05:54 -07:00
- name: Set EXTRA env
run: |
echo "HARDWARE_CI_SERIAL_DEVICE=${{matrix.serial-device}}" >> $GITHUB_ENV
# This both compiles and runs HW CI tests
- name: Run Hardware CI
2023-07-04 09:29:07 -07:00
run: .github/workflows/hw-ci/run_hw_ci.sh ${{matrix.test-suite}}