Fixes GitHub actions to use board revisions
This commit is contained in:
parent
f476e69229
commit
6969d74a8c
3 changed files with 9 additions and 4 deletions
4
.github/actions/build/action.yml
vendored
4
.github/actions/build/action.yml
vendored
|
|
@ -7,6 +7,9 @@ inputs:
|
|||
board:
|
||||
description: 'Board definition to use'
|
||||
default: bparasite_nrf52840
|
||||
revision:
|
||||
description: 'Board revision use'
|
||||
default: '1.2.0'
|
||||
cmake-extra:
|
||||
description: 'Extra CMake arguments'
|
||||
default: ''
|
||||
|
|
@ -19,5 +22,6 @@ runs:
|
|||
args:
|
||||
- ${{ inputs.sample-dir }}
|
||||
- ${{ inputs.board }}
|
||||
- ${{ inputs.revision }}
|
||||
- ${{ inputs.cmake-extra }}
|
||||
- ${{ inputs.output-bin }}
|
||||
|
|
|
|||
7
.github/actions/build/build.sh
vendored
7
.github/actions/build/build.sh
vendored
|
|
@ -3,11 +3,12 @@ set -eux -o pipefail
|
|||
|
||||
SAMPLE_DIR=$1
|
||||
BOARD=$2
|
||||
CMAKE_EXTRA=$3
|
||||
OUTPUT_BIN=$4
|
||||
REVISION=$3
|
||||
CMAKE_EXTRA=$4
|
||||
OUTPUT_BIN=$5
|
||||
|
||||
cd "${GITHUB_WORKSPACE}/${SAMPLE_DIR}"
|
||||
|
||||
west build --build-dir ./build --pristine --board "${BOARD}" -- $CMAKE_EXTRA
|
||||
west build --build-dir ./build --pristine --board "${BOARD}@${REVISION}" -- $CMAKE_EXTRA
|
||||
|
||||
mv build/zephyr/zephyr.hex build/zephyr/"${OUTPUT_BIN}"
|
||||
|
|
@ -18,7 +18,7 @@ static const struct adc_dt_spec adc_soil_spec =
|
|||
ADC_DT_SPEC_GET_BY_IDX(DT_PATH(zephyr_user), 0);
|
||||
|
||||
static const struct adc_dt_spec adc_batt_spec =
|
||||
ADC_DT_SPEC_GET_BY_IDX(DT_PATH(zephyr_user), 2);
|
||||
ADC_DT_SPEC_GET_BY_IDX(DT_PATH(zephyr_user), 1);
|
||||
|
||||
static int16_t soil_buf;
|
||||
static struct adc_sequence soil_sequence = {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue