docs/psoc6/quickref.rst: Adding spaces for readability. #2370
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: psoc6 port | |
on: | |
push: | |
pull_request: | |
paths: | |
- '.github/workflows/*.yml' | |
- 'tools/**' | |
- 'py/**' | |
- 'extmod/**' | |
- 'shared/**' | |
- 'lib/**' | |
- 'drivers/**' | |
- 'ports/psoc6/**' | |
jobs: | |
server-build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
board: | |
- CY8CPROTO-062-4343W | |
- CY8CPROTO-063-BLE | |
outputs: | |
commit_sha: ${{ steps.commit_sha.outputs.sha_short }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install packages | |
run: source tools/ci.sh && ci_psoc6_setup | |
- name: Build | |
run: source tools/ci.sh && ci_psoc6_build ${{ matrix.board }} | |
# Steps only relevant for Infineon fork | |
# with self-hosted runner available | |
- name: Gets commit SHA | |
if: success() && github.repository_owner == 'infineon' | |
id: commit_sha | |
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT | |
- name: Save firmware bin | |
if: success() && github.repository_owner == 'infineon' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: mpy-psoc6_${{ matrix.board }}_${{ steps.commit_sha.outputs.sha_short }} | |
path: ports/psoc6/build/firmware.hex | |
# Jobs only relevant for Infineon fork | |
on-target-test: | |
if: github.repository_owner == 'infineon' | |
runs-on: self-hosted | |
needs: server-build | |
continue-on-error: true | |
strategy: | |
matrix: | |
board: | |
- CY8CPROTO-062-4343W | |
- CY8CPROTO-063-BLE | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Download binaries | |
uses: actions/download-artifact@v4 | |
- name: Container setup | |
run: | | |
echo ${{ secrets.SELF_HOSTED_PASSWORD }} | sudo -S chmod 666 /var/run/docker.sock | |
source tools/ci.sh && ci_psoc6_setup | |
- name: Setup devices | |
run: | | |
cp mpy-psoc6_${{ matrix.board }}_${{ needs.server-build.outputs.commit_sha }}/firmware.hex . | |
source tools/ci.sh && ci_psoc6_flash_multiple_devices ${{ matrix.board }} firmware.hex tools/psoc6/${{ runner.name }}-devs.yml | |
- name: Run psoc6 tests | |
run: | | |
devs=($(python tools/psoc6/get-devs.py port -b ${{ matrix.board }} -y tools/psoc6/${{ runner.name }}-devs.yml)) | |
devs0=($(python tools/psoc6/get-devs.py port -b ${{ matrix.board }} -y tools/psoc6/${{ runner.name }}-devs.yml --hw-ext 0.4.0.a)) | |
devs1=($(python tools/psoc6/get-devs.py port -b ${{ matrix.board }} -y tools/psoc6/${{ runner.name }}-devs.yml --hw-ext 0.4.0.b)) | |
cd tests | |
echo " >> Filesystem tests" | |
./psoc6/run_psoc6_tests.sh -c -v --dev0 ${devs[0]} | |
echo " >> Multi network tests" | |
./psoc6/run_psoc6_tests.sh -c --psoc6-multi --dev0 ${devs[0]} --dev1 ${devs[1]} | |
echo " >> PSoC6 single board tests" | |
./psoc6/run_psoc6_tests.sh -c --psoc6 --dev0 ${devs[0]} | |
echo " >> PSoC6 extended hardware tests" | |
./psoc6/run_psoc6_tests.sh -c --psoc6-hwext --dev0 ${devs0[0]} | |
echo " >> PSoC6 i2c tests" | |
if [ "${{ matrix.board }}" == "CY8CPROTO-062-4343W" ]; then | |
i2c_dev=${devs1[0]} | |
else | |
if [ "${{ matrix.board }}" == "CY8CPROTO-063-BLE" ]; then | |
i2c_dev=${devs0[0]} | |
fi | |
fi | |
./psoc6/run_psoc6_tests.sh -c -u --dev0 ${i2c_dev} | |
echo " >> PSoC6 spi tests" | |
./psoc6/run_psoc6_tests.sh -c -r --dev0 ${devs0[0]} --dev1 ${devs1[0]} | |
echo " >> PSoC6 i2s tests" | |
./psoc6/run_psoc6_tests.sh -c -s --dev0 ${devs0[0]} --dev1 ${devs1[0]} | |
echo " >> PSoC6 bitstream tests" | |
./psoc6/run_psoc6_tests.sh -c -b --dev0 ${devs0[0]} --dev1 ${devs1[0]} | |
echo " >> PSoC6 watchdog tests" | |
./psoc6/run_psoc6_tests.sh -c --psoc6-wdt --dev0 ${devs[0]} | |
- name: Container teardown | |
if: failure() || success() | |
run: | | |
source tools/ci.sh && ci_psoc6_teardown | |
release: | |
runs-on: ubuntu-latest | |
needs: [server-build, on-target-test] | |
strategy: | |
matrix: | |
board: | |
- CY8CPROTO-062-4343W | |
- CY8CPROTO-063-BLE | |
if: startsWith(github.ref, 'refs/tags/v') && github.repository_owner == 'infineon' | |
steps: | |
- name: Download binaries | |
uses: actions/download-artifact@v4 | |
- name: Prepare release assets | |
run: | | |
cd mpy-psoc6_${{ matrix.board }}_${{ needs.server-build.outputs.commit_sha }} | |
mv firmware.hex ../mpy-psoc6_${{ matrix.board }}.hex | |
- name: Build release changelog | |
id: build_changelog | |
uses: mikepenz/release-changelog-builder-action@v3 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
name: Micropython PSoC6 ${{ github.ref_name }} | |
files: mpy-psoc6_${{ matrix.board }}.hex | |
body: ${{steps.build_changelog.outputs.changelog}} |