Skip to content

Fix two outdated links to the previous led_matrix_fw name of this repo #309

Fix two outdated links to the previous led_matrix_fw name of this repo

Fix two outdated links to the previous led_matrix_fw name of this repo #309

Workflow file for this run

name: Firmware
on:
push:
branches:
- main
- dev-*
paths-ignore:
- '*.py'
- 'inputmodule-control/**'
pull_request:
branches:
- '*'
paths-ignore:
- '*.py'
- 'inputmodule-control/**'
env:
CARGO_TERM_COLOR: always
CARGO_NET_GIT_FETCH_WITH_CLI: true
jobs:
building:
name: Building
runs-on: [ubuntu-latest]
steps:
- uses: actions/checkout@v3
- name: Setup Rust toolchain
run: rustup show
- run: cargo install cargo-make
- run: cargo install flip-link
# Debug version
- run: cargo make --cwd b1display
- run: cargo make --cwd c1minimal
- run: cargo make --cwd ledmatrix
- run: cargo make --cwd qtpy
# Release version
- run: cargo make --cwd ledmatrix build-release
- run: cargo make --cwd ledmatrix build-release-10k
- run: cargo make --cwd ledmatrix build-release-evt
- run: cargo make --cwd b1display build-release
- run: cargo make --cwd c1minimal build-release
- run: cargo make --cwd qtpy build-release
- name: Convert to UF2 format
run: |
sudo apt-get update
sudo apt-get install -y libudev-dev
cargo make --cwd b1display uf2
cargo make --cwd c1minimal uf2
cargo make --cwd qtpy uf2
cargo make --cwd ledmatrix build-release-10k-uf2
cargo make --cwd ledmatrix build-release-evt-uf2
cargo make --cwd ledmatrix uf2
- name: Convert to bin format
run: |
sudo apt-get update
sudo apt-get install -y llvm
cargo make --cwd b1display bin
cargo make --cwd qtpy bin
cargo make --cwd c1minimal bin
cargo make --cwd ledmatrix bin
- name: Upload ledmatrix files
uses: actions/upload-artifact@v3
with:
name: ledmatrix_fw_${{github.sha}}
path: |
# Main firmware
target/thumbv6m-none-eabi/release/ledmatrix.bin
target/thumbv6m-none-eabi/release/ledmatrix.uf2
# EVT 10k resistor
target/thumbv6m-none-eabi/release/ledmatrix_10k.uf2
# EVT (27k) resistor
target/thumbv6m-none-eabi/release/ledmatrix_evt.uf2
- name: Upload b1display files
uses: actions/upload-artifact@v3
with:
name: b1display_fw_${{github.sha}}
path: |
target/thumbv6m-none-eabi/release/b1display.bin
target/thumbv6m-none-eabi/release/b1display.uf2
- name: Upload c1minimal files
uses: actions/upload-artifact@v3
with:
name: c1minimal_fw_${{github.sha}}
path: |
target/thumbv6m-none-eabi/release/c1minimal.bin
target/thumbv6m-none-eabi/release/c1minimal.uf2
linting:
name: Linting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Rust toolchain
run: rustup show
- run: cargo install cargo-make
- run: |
sudo apt-get update
sudo apt-get install -y libudev-dev
cargo make clippy --cwd b1display
cargo make clippy --cwd qtpy
cargo make clippy --cwd c1minimal
cargo make clippy --cwd ledmatrix
# fl16-inputmodules/src/serialnum.rs
# is currently used by all firmwares to show their firmware version.
# But it shows the version of the fl16-inputmodules package.
# So that needs to be the same as the firmware version.
- name: Check versions of all packages are the same
run: |
cargo pkgid -p fl16-inputmodules | cut -d "#" -f2 >> versions.tmp
cargo pkgid -p b1display | cut -d "#" -f2 >> versions.tmp
cargo pkgid -p qtpy | cut -d "#" -f2 >> versions.tmp
cargo pkgid -p c1minimal | cut -d "#" -f2 >> versions.tmp
cargo pkgid -p ledmatrix | cut -d "#" -f2 >> versions.tmp
uniq -c versions.tmp | [ $(wc -l) -eq 1 ]
formatting:
name: Formatting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Rust toolchain
run: rustup show
- run: |
cargo fmt -p b1display -- --check
cargo fmt -p c1minimal -- --check
cargo fmt -p ledmatrix -- --check
cargo fmt -p qtpy -- --check
cargo fmt -p fl16-inputmodules -- --check