Bramble Build
Build the bramble firmware for RP2040.
Arguments
- •
$ARGUMENTS- Hardware variant: SENSOR, IRRIGATION, CONTROLLER, HUB, GENERIC, or ALL (default: ALL)
Instructions
- •
Parse the variant argument
- •If
$ARGUMENTSis "ALL" or empty/not provided, build all variants usingHARDWARE_VARIANT=ALL - •If
$ARGUMENTSmatches a valid single variant (SENSOR, IRRIGATION, CONTROLLER, HUB, GENERIC), build only that variant - •The executable names are
bramble_<variant>(lowercase), e.g.,bramble_sensor
- •If
- •
Build the firmware
All builds use the same
build/directory. CMake supportsHARDWARE_VARIANT=ALLwhich defines all variant targets in a single configure, so-j8parallelizes across all variants automatically.bash~/.pico-sdk/cmake/v3.31.5/bin/cmake -B build -DHARDWARE_VARIANT=<VARIANT> 2>&1 ~/.pico-sdk/cmake/v3.31.5/bin/cmake --build build -j8 2>&1
Where
<VARIANT>is one of: ALL, SENSOR, IRRIGATION, CONTROLLER, HUB, GENERIC. - •
Report results
- •On success: Report which variants built successfully and their output file locations
- •On failure: Report which variants failed and show compiler errors
- •For ALL builds, summarize: "X/5 variants built successfully"
Example Usage
code
/bramble-build # Build ALL variants /bramble-build ALL # Build ALL variants /bramble-build SENSOR # Build only SENSOR variant /bramble-build IRRIGATION # Build only IRRIGATION variant