summaryrefslogtreecommitdiff
path: root/.github/workflows
diff options
context:
space:
mode:
authorHiFiPhile <[email protected]>2024-07-28 11:59:52 +0200
committerHiFiPhile <[email protected]>2024-07-28 11:59:52 +0200
commitf48a4567a6f97c6f814ad6cd3de544bcce42e585 (patch)
tree2b5e4d18f4d1ac827f97531db6729ecb13583189 /.github/workflows
parentb0f5422262a26fb1ab496e33bb8009efb6660788 (diff)
parentcfbdc44a8d099240ad5ef208bd639487c2f28153 (diff)
Merge branch 'master' of https://github.com/hathach/tinyusb into rx_fb
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/build.yml10
-rw-r--r--.github/workflows/build_renesas.yml66
-rw-r--r--.github/workflows/ci_set_matrix.py9
-rw-r--r--.github/workflows/hil_test.yml35
4 files changed, 32 insertions, 88 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 78d95fbbc..712c7dd43 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -51,14 +51,15 @@ jobs:
# Build CMake
# ---------------------------------------
cmake:
+ # if: false
needs: set-matrix
uses: ./.github/workflows/build_util.yml
strategy:
fail-fast: false
matrix:
toolchain:
+ # - 'arm-clang' is built by circle-ci
- 'aarch64-gcc'
- # - 'arm-clang' # clang is built by circle-ci
- 'arm-gcc'
- 'msp430-gcc'
- 'riscv-gcc'
@@ -73,18 +74,19 @@ jobs:
# Build Make
# ---------------------------------------
make:
- #if: github.event_name == 'pull_request'
+ # if: false
needs: set-matrix
uses: ./.github/workflows/build_util.yml
strategy:
fail-fast: false
matrix:
toolchain:
+ # 'arm-clang' is built by circle-ci
- 'aarch64-gcc'
- # - 'arm-clang' # clang is built by circle-ci
- 'arm-gcc'
- 'msp430-gcc'
- 'riscv-gcc'
+ - 'rx-gcc'
with:
build-system: 'make'
toolchain: ${{ matrix.toolchain }}
@@ -112,6 +114,7 @@ jobs:
# Build Espressif
# ---------------------------------------
espressif:
+ # if: false
uses: ./.github/workflows/build_util.yml
strategy:
fail-fast: false
@@ -131,6 +134,7 @@ jobs:
# Build IAR on HFP self-hosted
# ---------------------------------------
arm-iar:
+ # if: false
if: github.repository_owner == 'hathach'
needs: set-matrix
runs-on: [self-hosted, Linux, X64, hifiphile]
diff --git a/.github/workflows/build_renesas.yml b/.github/workflows/build_renesas.yml
deleted file mode 100644
index 3d2cbab28..000000000
--- a/.github/workflows/build_renesas.yml
+++ /dev/null
@@ -1,66 +0,0 @@
-name: Build Renesas
-
-on:
- workflow_dispatch:
- push:
- paths:
- - 'src/**'
- - 'examples/**'
- - 'lib/**'
- - 'hw/**'
- - 'tools/get_deps.py'
- - '.github/workflows/build_renesas.yml'
- pull_request:
- branches: [ master ]
- paths:
- - 'src/**'
- - 'examples/**'
- - 'lib/**'
- - 'hw/**'
- - 'tools/get_deps.py'
- - '.github/workflows/build_renesas.yml'
-
-concurrency:
- group: ${{ github.workflow }}-${{ github.ref }}
- cancel-in-progress: true
-
-jobs:
- build-rx:
- runs-on: ubuntu-latest
- strategy:
- fail-fast: false
- matrix:
- family:
- # Alphabetical order
- - 'rx'
- steps:
- - name: Checkout TinyUSB
- uses: actions/checkout@v4
-
- - name: Set Toolchain URL
- run: echo >> $GITHUB_ENV TOOLCHAIN_URL=http://gcc-renesas.com/downloads/get.php?f=rx/8.3.0.202004-gnurx/gcc-8.3.0.202004-GNURX-ELF.run
-
- - name: Cache Toolchain
- uses: actions/cache@v4
- id: cache-toolchain
- with:
- path: ~/cache/
- key: ${{ runner.os }}-21-03-30-${{ env.TOOLCHAIN_URL }}
-
- - name: Install Toolchain
- if: steps.cache-toolchain.outputs.cache-hit != 'true'
- run: |
- mkdir -p ~/cache/toolchain/gnurx
- wget --progress=dot:mega $TOOLCHAIN_URL -O toolchain.run
- chmod +x toolchain.run
- ./toolchain.run -p ~/cache/toolchain/gnurx -y
-
- - name: Set Toolchain Path
- run: echo >> $GITHUB_PATH `echo ~/cache/toolchain/*/bin`
-
- - name: Get Dependencies
- run: |
- python3 tools/get_deps.py ${{ matrix.family }}
-
- - name: Build
- run: python3 tools/build.py -s make ${{ matrix.family }}
diff --git a/.github/workflows/ci_set_matrix.py b/.github/workflows/ci_set_matrix.py
index c6f4e8fe2..2a00e5413 100644
--- a/.github/workflows/ci_set_matrix.py
+++ b/.github/workflows/ci_set_matrix.py
@@ -7,14 +7,16 @@ toolchain_list = {
"arm-iar": "",
"arm-gcc": "",
"msp430-gcc": "http://software-dl.ti.com/msp430/msp430_public_sw/mcu/msp430/MSPGCC/9_2_0_0/export/msp430-gcc-9.2.0.50_linux64.tar.bz2",
- "riscv-gcc": "https://github.com/xpack-dev-tools/riscv-none-elf-gcc-xpack/releases/download/v13.2.0-2/xpack-riscv-none-elf-gcc-13.2.0-2-linux-x64.tar.gz"
+ "riscv-gcc": "https://github.com/xpack-dev-tools/riscv-none-elf-gcc-xpack/releases/download/v13.2.0-2/xpack-riscv-none-elf-gcc-13.2.0-2-linux-x64.tar.gz",
+ "rx-gcc": "http://gcc-renesas.com/downloads/get.php?f=rx/8.3.0.202004-gnurx/gcc-8.3.0.202004-GNURX-ELF.run",
}
# family: [supported toolchain]
family_list = {
"broadcom_32bit": ["arm-gcc"],
"broadcom_64bit": ["aarch64-gcc"],
- "ch32v20x ch32v307 fomu gd32vf103": ["riscv-gcc"],
+ "ch32v10x ch32v20x ch32v307 fomu gd32vf103": ["riscv-gcc"],
+ "da1469x": ["arm-gcc"],
"imxrt": ["arm-gcc", "arm-clang"],
"kinetis_k kinetis_kl kinetis_k32l2": ["arm-gcc", "arm-clang"],
"lpc11 lpc13 lpc15": ["arm-gcc", "arm-clang"],
@@ -27,6 +29,7 @@ family_list = {
"nrf": ["arm-gcc", "arm-clang"],
"ra": ["arm-gcc"],
"rp2040": ["arm-gcc"],
+ "rx": ["rx-gcc"],
"samd11 samd21 saml2x": ["arm-gcc", "arm-clang"],
"samd5x_e5x samg": ["arm-gcc", "arm-clang"],
"stm32f0 stm32f1 stm32f2 stm32f3": ["arm-gcc", "arm-clang", "arm-iar"],
@@ -34,7 +37,7 @@ family_list = {
"stm32f7": ["arm-gcc", "arm-clang", "arm-iar"],
"stm32g0 stm32g4 stm32h5": ["arm-gcc", "arm-clang", "arm-iar"],
"stm32h7": ["arm-gcc", "arm-clang", "arm-iar"],
- "stm32l4 stm32u5 stm32wb": ["arm-gcc", "arm-clang", "arm-iar"],
+ "stm32l0 stm32l4 stm32u5 stm32wb": ["arm-gcc", "arm-clang", "arm-iar"],
"xmc4000": ["arm-gcc"],
}
diff --git a/.github/workflows/hil_test.yml b/.github/workflows/hil_test.yml
index 39a9060a2..51227d408 100644
--- a/.github/workflows/hil_test.yml
+++ b/.github/workflows/hil_test.yml
@@ -17,6 +17,9 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
+env:
+ HIL_JSON: test/hil/rpi.json
+
jobs:
# ---------------------------------------
# Build Non Espressif
@@ -36,7 +39,7 @@ jobs:
sudo apt install -y jq
# Non-Espresif boards
- BOARDS_LIST=$(jq -r '.boards[] | select(.flasher != "esptool") | "-b " + .name' test/hil/pi4.json | tr '\n' ' ')
+ BOARDS_LIST=$(jq -r '.boards[] | select(.flasher != "esptool") | "-b " + .name' ${{ env.HIL_JSON }} | tr '\n' ' ')
echo "BOARDS_LIST=$BOARDS_LIST"
echo "BOARDS_LIST=$BOARDS_LIST" >> $GITHUB_ENV
echo "BOARDS_LIST=$BOARDS_LIST" >> $GITHUB_OUTPUT
@@ -57,7 +60,7 @@ jobs:
- name: Upload Artifacts for Hardware Testing
uses: actions/upload-artifact@v4
with:
- name: hil_pi4
+ name: hil_rpi
path: |
cmake-build/cmake-build-*/*/*/*.elf
cmake-build/cmake-build-*/*/*/*.bin
@@ -78,7 +81,7 @@ jobs:
run: |
sudo apt install -y jq
# Espressif boards
- BOARDS_LIST=$(jq -r '.boards[] | select(.flasher == "esptool") | "-b " + .name' test/hil/pi4.json | tr '\n' ' ')
+ BOARDS_LIST=$(jq -r '.boards[] | select(.flasher == "esptool") | "-b " + .name' ${{ env.HIL_JSON }} | tr '\n' ' ')
echo "BOARDS_LIST=$BOARDS_LIST"
echo "BOARDS_LIST=$BOARDS_LIST" >> $GITHUB_ENV
echo "BOARDS_LIST=$BOARDS_LIST" >> $GITHUB_OUTPUT
@@ -102,7 +105,7 @@ jobs:
- name: Upload Artifacts for Hardware Testing
uses: actions/upload-artifact@v4
with:
- name: hil_pi4_esp
+ name: hil_rpi_esp
path: |
cmake-build/cmake-build-*/*/*/*.bin
cmake-build/cmake-build-*/*/*/bootloader/bootloader.bin
@@ -112,14 +115,14 @@ jobs:
# ---------------------------------------
# Hardware in the loop (HIL)
- # Current self-hosted instance is running on an RPI4. For attached hardware checkout test/hil/pi4.json
+ # self-hosted running on an RPI. For attached hardware checkout test/hil/rpi.json
# ---------------------------------------
- hil-pi4:
+ hil-rpi:
if: github.repository_owner == 'hathach'
needs:
- build
- build-esp
- runs-on: [self-hosted, rp2040, nrf52840, esp32s3, hardware-in-the-loop]
+ runs-on: [self-hosted, ARM64, rpi, hardware-in-the-loop]
env:
BOARDS_LIST: "${{ needs.build.outputs.BOARDS_LIST }} ${{ needs.build-esp.outputs.BOARDS_LIST }}"
steps:
@@ -129,12 +132,12 @@ jobs:
rm -rf "${{ github.workspace }}"
mkdir -p "${{ github.workspace }}"
- # USB bus on rpi4 is not stable, reset it before testing
- - name: Reset USB bus
- run: |
- # lsusb -t
- # reset VIA Labs 2.0 hub
- sudo usbreset 001/002
+ # USB bus on rpi is not stable, reset it before testing
+# - name: Reset USB bus
+# run: |
+# # reset VIA Labs 2.0 hub
+# sudo usbreset 001/002
+# lsusb -t
- name: Checkout TinyUSB
uses: actions/checkout@v4
@@ -144,13 +147,13 @@ jobs:
- name: Download Artifacts
uses: actions/download-artifact@v4
with:
- name: hil_pi4
+ name: hil_rpi
path: cmake-build
- name: Download Artifacts
uses: actions/download-artifact@v4
with:
- name: hil_pi4_esp
+ name: hil_rpi_esp
path: cmake-build
- name: Test on actual hardware
@@ -159,4 +162,4 @@ jobs:
echo "::group::{cmake-build contents}"
tree cmake-build
echo "::endgroup::"
- python3 test/hil/hil_test.py $BOARDS_LIST pi4.json
+ python3 test/hil/hil_test.py $BOARDS_LIST ${{ env.HIL_JSON }}