Barebones starting point for building Golioth examples using the
"manifest repository" approach that places the example in an app
folder that is a sibling to the deps
folder where all dependencies are
installed.
Vendor | Model | Zephyr name |
---|---|---|
Espressif | ESP32-DevkitC | esp32_devkitc_wrover |
Nordic | nRF9160 DK | nrf9160dk_nrf9160_ns |
NXP | i.MX RT1024 Evaluation Kit | mimxrt1024_evk |
:important: Do not clone this repo using git. Zephyr's
west
meta tool should be used to set up your local workspace.
cd ~
mkdir golioth-example-download-photo
python -m venv golioth-example-download-photo/.venv
source golioth-example-download-photo/.venv/bin/activate
pip install wheel west
Run one of these two initializations based on your target board:
# Initalize for Zephyr
cd ~/golioth-example-download-photo
west init -m [email protected]:golioth/example-download-photo.git --mf west-zephyr.yml .
Fetch dependencies and configure the build environment
west update
west zephyr-export
pip install -r deps/zephyr/scripts/requirements.txt
Prior to building, update VERSION
file to reflect the firmware
version number you want to assign to this build.
Then run the following commands to build and program the firmware based on the device you are using.
west build -p -b <my_board_name> --sysbuild app
west flash
Configure PSK-ID and PSK using the device shell based on your Golioth credentials and reboot:
uart:~$ settings set golioth/psk-id <my-psk-id@my-project>
uart:~$ settings set golioth/psk <my-psk>
uart:~$ kernel reboot cold
This example implements the following Golioth services:
- Runtime credentials
- Backend Logging
- Device Settings
- OTA Firmware Update
west build -b native_sim example-download-photo
or
west build -b native_sim/native/64 example-download-photo
west build -b xiao_esp32s3 example-download-photo --sysbuild
west flash
west build -b xiao_esp32s3 example-download-photo --sysbuild --shield seeed_xiao_round_display
west flash