[{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003cp\u003eThis is for folks interested in learning about Zephyr. The first section shows, step by step, how to work through the Zephyr Getting Started Guide to install Zephyr on Linux, build the hello world sample, and run it on an Adafruit QT Py ESP32-S3. The second part has notes for tuning the default settings to use fewer resources for faster CI builds.\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"user_image","content":"https://cdn-learn.adafruit.com/user_assets/assets/000/001/506/original/zephyr-hello-world-3.jpeg?1736804469","metadata":{"caption":""}},{"element_type":"product","content":"https://www.adafruit.com/product/5426","metadata":{}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003ch1\u003eWhat are Zephyr and West?\u003c/h1\u003e\n\u003cp\u003eThe Zephyr Real Time Operating System (RTOS) provides an abstraction layer that helps make it easier to port applications like CircuitPython to boards from various manufacturers.\u003c/p\u003e\n\u003cp\u003eIn theory, using an RTOS makes it easier to implement features using audio synthesis, graphic displays, HTTPS, MQTT, BLE, etc. By building on top of Zephyr APIs, rather than vendor-specific SDK APIs, application code can ignore some of the differences between microcontroller families. Zephyr helps with low-level hardware details and coordinating CPU time for concurrent tasks including application logic, hardware IO, network stacks, and number crunching.\u003c/p\u003e\n\u003cp\u003eZephyr has a command line tool called\u0026nbsp;\u003ccode\u003ewest\u003c/code\u003e to manage and coordinate the many tasks involved in working on a Zephyr project. Once you install west, you can do \u003ccode\u003ewest help\u003c/code\u003e to see documentation on the available sub-commands.\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003ch1\u003eDifferences from Official Getting Started Guide\u003c/h1\u003e\n\u003col\u003e\n\u003cli\u003eThe official Zephyr \u003ca href=\"https://docs.zephyrproject.org/latest/develop/getting_started/index.html\" target=\"_blank\"\u003eGetting Started Guide\u003c/a\u003e\u0026nbsp;describes a lot of options, sidebars, and choices to make. Also, it suggests using west commands with defaults that use a lot of bandwidth and disk space.\u003c/li\u003e\n\u003cli\u003eThis guide focuses on the linear, step by step procedure to install Zephyr efficiently on Debian 12 (Bookworm) and build firmware for an Adafruit QT Py ESP32-S3. This procedure will probably also work on Ubuntu 22 LTS or 24 LTS.\u003c/li\u003e\n\u003cli\u003eThis guide assumes you are already familiar with using a Linux command line shell to install packages and work with Python virtual environments.\u003c/li\u003e\n\u003cli\u003eThis guide includes notes on reducing resource use when using\u0026nbsp;\u003ccode\u003ewest init\u003c/code\u003e, \u003ccode\u003ewest update\u003c/code\u003e, and \u003ccode\u003ewest sdk install\u003c/code\u003e. I expect these notes might help people who want to write GitHub CI actions to build firmware with Zephyr.\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch1\u003eInstall Debian 12 Distro Packages\u003c/h1\u003e\n\u003cp\u003eThese instructions should work to install package dependencies on Debian 12. If you want to use a different OS, you might check the official getting started guide for notes on minimum required versions of Python, CMake, etc.\u003c/p\u003e\n\u003cp\u003eDebian shell commands to install package dependencies:\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"code","content":"sudo apt update\nsudo apt upgrade\nsudo apt install git cmake make ninja-build gperf ccache dfu-util \\\n device-tree-compiler wget xz-utils file openocd \\\n python3-dev python3-pip python3-setuptools python3-tk python3-wheel \\\n python3-venv gcc gcc-multilib g++-multilib libsdl2-dev libmagic1","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003ch1\u003ePip Install West in Virtual Environment\u003c/h1\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003cp\u003eThis is similar to the official guide, but I've added options to limit the depth of \u003ccode\u003egit clone\u003c/code\u003e. Using limited depth cloning saves bandwidth, time, and disk space.\u003c/p\u003e\n\u003cp\u003eDebian shell commands to create a top-level workspace directory called \u003ccode\u003ezephyr-workspace\u003c/code\u003e\u0026nbsp;and install \u003ccode\u003ewest\u003c/code\u003e in a Python virtual environment:\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"code","content":"cd ~/code   # or whatever directory you want to use\npython3 -m venv zephyr-workspace/.venv\nsource zephyr-workspace/.venv/bin/activate\npip install west\ncd zephyr-workspace\nwest init -o=--depth=1\nwest update -o=--depth=500\nwest zephyr-export\nwest packages pip --install","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003ch1\u003eInstall Zephyr SDK Toolchains\u003c/h1\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"text","content":"\n  \n  \n  \n  \n        \u003cp\u003eThe official guide suggests using\u0026nbsp;\u003ccode\u003ewest sdk install\u003c/code\u003e with no options. But, that takes 9 GB of disk space. I've added options here to only install the toolchains for ESP32-S3 and ARM, which cover many of Adafruit's boards.\u003c/p\u003e\n\u003cp\u003eDebian shell commands to create a top-level workspace directory called \u003ccode\u003ezephyr-workspace\u003c/code\u003e\u0026nbsp;and install \u003ccode\u003ewest\u003c/code\u003e in a Python virtual environment:\u003c/p\u003e\n      \n\n\n\n","metadata":{}},{"element_type":"code","content":"cd ~/code/zephyr-workspace/zephyr\nwest sdk install --no-toolchains\nwest sdk install --toolchains xtensa-espressif_esp32s3_zephyr-elf\nwest sdk install --toolchains arm-zephyr-eabi","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n        \u003cp\u003eDoing it this way uses about 1.7 GB for\u0026nbsp;\u003ccode\u003e~/zephyr-sdk-0.17.0\u003c/code\u003e (instead of 9 GB).\u003c/p\u003e\n\u003ch1\u003eBuild and Run Hello World\u003c/h1\u003e\n\u003cp\u003eThis builds one of the sample projects from the zephyr repo for Adafruit QT Py ESP32-S3 with 8MB Flash and no PSRAM.\u003c/p\u003e\n\u003cp\u003eFor specifying the board variant and CPU qualifiers, check the documentation at the Zephyr board page \u003ca href=\"https://docs.zephyrproject.org/latest/boards/adafruit/qt_py_esp32s3/doc/index.html\"\u003efor QT Py ESP32-S3\u003c/a\u003e:\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e8MB flash / No PSRAM:\u0026nbsp; \u003ccode\u003e-b adafruit_qt_py_esp32s3/esp32s3/procpu\u003c/code\u003e\n\u003c/li\u003e\n\u003cli\u003e4MB flash / 2MB PSRAM: \u003ccode\u003e-b adafruit_qt_py_esp32s3@psram/esp32s3/procpu\u003c/code\u003e\n\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eDebian shell commands to build firmware (assumes venv is already active):\u003c/p\u003e\n      \n\n\n\n\n","metadata":{}},{"element_type":"code","content":"cd ~/code/zephyr-workspace/zephyr\nwest blobs fetch hal_espressif     # only need to run fetch once\nwest build -p always -b adafruit_qt_py_esp32s3/esp32s3/procpu samples/hello_world","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003cp\u003eTo flash the firmware:\u003c/p\u003e\n\u003col\u003e\n\u003cli\u003eHold BOOT button on QT Py ESP32-S3\u003c/li\u003e\n\u003cli\u003ePress and release RESET button while still holding BOOT down\u003c/li\u003e\n\u003cli\u003eRelease BOOT button\u003c/li\u003e\n\u003cli\u003eRun\u0026nbsp;\u003ccode\u003ewest flash\u003c/code\u003e, wait for it to finish\u003c/li\u003e\n\u003cli\u003eReset board or power cycle it by unplugging the USB cable\u003c/li\u003e\n\u003c/ol\u003e\n\u003cp\u003eTo see output:\u003c/p\u003e\n\u003col\u003e\n\u003cli\u003eRun\u0026nbsp;\u003ccode\u003ewest espressif monitor\u003c/code\u003e\u0026nbsp;(Ctrl+] to exit monitor)\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch1\u003e\n\u003cbr\u003eHello World Sample Output\u003c/h1\u003e\n\u003cp\u003eThis is what I got from\u0026nbsp;\u003ccode\u003ewest espressif monitor\u003c/code\u003e:\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"code","content":"(.venv) $ west espressif monitor\nSerial port /dev/ttyACM0\nConnecting...\nDetecting chip type... ESP32-S3\n--- idf_monitor on /dev/ttyACM0 115200 ---\n--- Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H ---\nESP-ROM:esp32s3-20210327\nBuild:Mar 27 2021\nrst:0x15 (USB_UART_CHIP_RESET),boot:0x8 (SPI_FAST_FLASH_BOOT)\nSaved PC:0x400490cc\nSPIWP:0xee\nmode:DIO, clock div:2\nload:0x3fc8d5a0,len:0x1798\nload:0x40374000,len:0x9580\n0x40374000: _WindowOverflow4 at /home/sam/code/zephyr-workspace/zephyr/arch/xtensa/core/window_vectors.S:56\n\nSHA-256 comparison failed:\nCalculated: d8bf627803a97d93b575d89be58fe15d03159cb115a83c18972a42e6d1c1cbc1\nExpected: 00000000a0520000000000000000000000000000000000000000000000000000\nAttempting to boot anyway...\nentry 0x403778f8\n0x403778f8: __start at /home/sam/code/zephyr-workspace/zephyr/soc/espressif/common/loader.c:253\n\nI (64) soc_init: ESP Simple boot\nI (64) soc_init: compile time Jan 12 2025 01:58:38\nW (64) soc_init: Unicore bootloader\nI (65) spi_flash: detected chip: gd\nI (67) spi_flash: flash io: dio\nW (70) spi_flash: Detected size(8192k) larger than the size in the binary image header(2048k). Using the size in the binary image header.\nI (82) soc_init: chip revision: v0.2\nI (85) flash_init: Boot SPI Speed : 40MHz\nI (89) flash_init: SPI Mode       : DIO\nI (92) flash_init: SPI Flash Size : 8MB\nI (96) soc_random: Enabling RNG early entropy source\nI (101) boot: DRAM: lma 0x00000020 vma 0x3fc8d5a0 len 0x1798   (6040)\nI (107) boot: IRAM: lma 0x000017c0 vma 0x40374000 len 0x9580   (38272)\n0x40374000: _WindowOverflow4 at /home/sam/code/zephyr-workspace/zephyr/arch/xtensa/core/window_vectors.S:56\n\nI (113) boot: IRAM: lma 0x0000ad58 vma 0x00000000 len 0x52a0   (21152)\nI (119) boot: IMAP: lma 0x00010000 vma 0x42000000 len 0x3a9c   (15004)\n0x42000000: _stext at ??:?\n\nI (125) boot: IRAM: lma 0x00013aa4 vma 0x00000000 len 0xc554   (50516)\nI (132) boot: DMAP: lma 0x00020000 vma 0x3c010000 len 0x1110   (4368)\nI (138) boot: Image with 6 segments\nI (141) boot: DROM segment: paddr=00020000h, vaddr=3c010000h, size=01110h (  4368) map\nI (149) boot: IROM segment: paddr=00010000h, vaddr=42000000h, size=03A9Ah ( 15002) map\nI (168) soc_random: Disabling RNG early entropy source\nI (168) boot: Disabling glitch detection\nI (168) boot: Jumping to the main image...\nI (193) heap_runtime: ESP heap runtime init at 0x3fc915d8 size 352 kB.\n*** Booting Zephyr OS build 99a63a776980 ***\nHello World! adafruit_qt_py_esp32s3/esp32s3/procpu","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003cp\u003eThe hello world code that generated the message is on github at:\u003c/p\u003e\n\u003cp\u003e\u0026nbsp;\u003ca href=\"https://github.com/zephyrproject-rtos/zephyr/blob/99a63a776980f855493ceb99036a5974a2b68fb5/samples/hello_world/src/main.c\"\u003ezephyrproject-rtos/zephyr/samples/hello_world/src/main.c\u003c/a\u003e\u003c/p\u003e\n\u003cp\u003e\u0026nbsp;\u003c/p\u003e\n\u003ch1\u003eCI Notes\u003c/h1\u003e\n\u003cp\u003eThis section might be useful for people who want to write CI actions to build CircuitPython on Zephyr.\u003c/p\u003e\n\u003cp\u003eThe full Zephyr install with all the hardware libraries and compilers is about 15 GB. But, you can customize the defaults to use fewer resources.\u003c/p\u003e\n\u003ch2\u003e\n\u003cbr\u003eOptimizing west init and west update\u003c/h2\u003e\n\u003cp\u003eThe west init command sets up a Zephyr workspace according to options given in a manifest file. The default manifest file comes from \u003ca href=\"https://github.com/zephyrproject-rtos/zephyr\"\u003ehttps://github.com/zephyrproject-rtos/zephyr\u003c/a\u003e, and it includes a lot of stuff for many different hardware platforms.\u003c/p\u003e\n\u003cp\u003eFor building CI systems using west, you may want to consider using options to limit the git clone depth and to specify a custom manifest file. For details, see\u0026nbsp;\u003ccode\u003ewest help init\u003c/code\u003e and \u003ccode\u003ewest help update\u003c/code\u003e.\u003c/p\u003e\n\u003cp\u003eWhen I ran \u003ccode\u003ewest init\u003c/code\u003e with the default options, it cloned a new \u003ccode\u003ezephyr\u003c/code\u003e repo under the top-level workspace directory, downloading about 690 MB, which expanded to about 1.1 GB on disk.\u003c/p\u003e\n\u003cp\u003eUsing\u0026nbsp;\u003ccode\u003ewest init -o=--depth=1\u003c/code\u003e\u0026nbsp;to limit the clone depth cut the download to 87 MiB, which expand to 452 MB on disk.\u003c/p\u003e\n\u003cp\u003eWhen I ran \u003ccode\u003ewest update\u003c/code\u003e it cloned many git repositories into the bootloader, tools, and modules directories under the top-level workspace directory. The total disk space using default options was about 5 GB.\u003c/p\u003e\n\u003cp\u003eWhen I switched to using\u0026nbsp;\u003ccode\u003ewest update -o=--depth=500\u003c/code\u003e to limit the clone depth, it cut the disk space down to about 4.6 GB. It would probably be possible to save more bandwidth and disk space with a custom manifest file that omits unnecessary hal repos.\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"alert","content":"\u003cp\u003eUsing depth=1 for \u003ccode class=\"inline\"\u003ewest update\u003c/code\u003e causes errors. My guess is that the errors probably have to do with pinned dependencies that want specific commit hashes which are behind the HEAD of certain repos.\u003c/p\u003e","metadata":{"class":"element alert-element build-alert alert-warning","markdown":"Using depth=1 for `west update` causes errors. My guess is that the errors probably have to do with pinned dependencies that want specific commit hashes which are behind the HEAD of certain repos.","alert_type":"warning"}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003cp\u003eThese are the new directories created in the workspace by west update:\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"code","content":"(.venv) $ du -sh *\n15M\tbootloader\n4.6G\tmodules\n20M\ttools\n452M\tzephyr\n(.venv) $ tree -L 1 bootloader/ tools/; tree -L 2 modules/\nbootloader/\n└── mcuboot\ntools/\n├── edtt\n└── net-tools\n\n5 directories, 0 files\nmodules/\n├── bsim_hw_models\n│   └── nrf_hw_models\n├── crypto\n│   ├── mbedtls\n│   └── tinycrypt\n├── debug\n│   ├── mipi-sys-t\n│   ├── percepio\n│   └── segger\n├── fs\n│   ├── fatfs\n│   └── littlefs\n├── hal\n│   ├── adi\n│   ├── altera\n│   ├── ambiq\n│   ├── atmel\n│   ├── cmsis\n│   ├── espressif\n│   ├── ethos_u\n│   ├── gigadevice\n│   ├── infineon\n│   ├── intel\n│   ├── libmetal\n│   ├── microchip\n│   ├── nordic\n│   ├── nuvoton\n│   ├── nxp\n│   ├── openisa\n│   ├── quicklogic\n│   ├── renesas\n│   ├── rpi_pico\n│   ├── silabs\n│   ├── st\n│   ├── stm32\n│   ├── tdk\n│   ├── telink\n│   ├── ti\n│   ├── wch\n│   ├── wurthelektronik\n│   └── xtensa\n├── lib\n│   ├── acpica\n│   ├── cmsis_6\n│   ├── cmsis-dsp\n│   ├── cmsis-nn\n│   ├── gui\n│   ├── hostap\n│   ├── liblc3\n│   ├── loramac-node\n│   ├── nrf_wifi\n│   ├── open-amp\n│   ├── openthread\n│   ├── picolibc\n│   ├── uoscore-uedhoc\n│   └── zcbor\n└── tee\n    ├── tf-a\n    └── tf-m\n\n60 directories, 0 files","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n  \n        \u003ch2\u003eOptimizing west sdk install\u003c/h2\u003e\n\u003cp\u003eWhen I ran\u0026nbsp;\u003ccode\u003ewest sdk install\u003c/code\u003e with the default options, it installed 9 GB of toolchain files in \u003ccode\u003e~/zephyr-sdk-0.17.0.\u003c/code\u003e\u003c/p\u003e\n\u003cp\u003eThis is the disk usage that resulted from the default \u003ccode\u003ewest sdk install\u003c/code\u003e:\u003c/p\u003e\n      \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","metadata":{}},{"element_type":"code","content":"(.venv) $ cd ~/zephyr-sdk-0.17.0/\n(.venv) $ du -sh .\n9.0G\t.\n(.venv) $ du -sh *\n259M\taarch64-zephyr-elf\n304M\tarc64-zephyr-elf\n660M\tarc-zephyr-elf\n1.1G\tarm-zephyr-eabi\n36K\tcmake\n4.0K\tenvironment-setup-x86_64-pokysdk-linux\n330M\tmicroblazeel-zephyr-elf\n322M\tmips-zephyr-elf\n330M\tnios2-zephyr-elf\n976M\triscv64-zephyr-elf\n4.0K\tsdk_toolchains\n4.0K\tsdk_version\n8.0K\tsetup.sh\n428M\tsparc-zephyr-elf\n431M\tsysroots\n4.0K\tversion-x86_64-pokysdk-linux\n310M\tx86_64-zephyr-elf\n239M\txtensa-amd_acp_6_0_adsp_zephyr-elf\n195M\txtensa-dc233c_zephyr-elf\n197M\txtensa-espressif_esp32s2_zephyr-elf\n202M\txtensa-espressif_esp32s3_zephyr-elf\n198M\txtensa-espressif_esp32_zephyr-elf\n214M\txtensa-intel_ace15_mtpm_zephyr-elf\n215M\txtensa-intel_ace30_ptl_zephyr-elf\n205M\txtensa-intel_tgl_adsp_zephyr-elf\n215M\txtensa-mtk_mt8195_adsp_zephyr-elf\n214M\txtensa-nxp_imx8m_adsp_zephyr-elf\n216M\txtensa-nxp_imx8ulp_adsp_zephyr-elf\n214M\txtensa-nxp_imx_adsp_zephyr-elf\n205M\txtensa-nxp_rt500_adsp_zephyr-elf\n216M\txtensa-nxp_rt600_adsp_zephyr-elf\n204M\txtensa-nxp_rt700_hifi1_zephyr-elf\n216M\txtensa-nxp_rt700_hifi4_zephyr-elf\n194M\txtensa-sample_controller32_zephyr-elf\n194M\txtensa-sample_controller_zephyr-elf\n43M\tzephyr-sdk-x86_64-hosttools-standalone-0.9.sh","metadata":{"language":"terminal","linenums":false}},{"element_type":"text","content":"\n        \u003cp\u003eInstead of using the default sdk install, you can save bandwidth, download time, decompression time, and disk space by installing specific toolchains.\u003c/p\u003e\n\u003cp\u003eTo install one or more specific toolchains, do:\u003c/p\u003e\n\u003cp\u003e\u003ccode\u003ewest sdk install --toolchains LIST_OF_TOOLCHAIN_NAMES\u003c/code\u003e\u003c/p\u003e\n\u003cp\u003eTo see the available toolchain names, look at the GitHub \u003ccode\u003ezephyrproject-rtos/sdk-ng\u003c/code\u003e repository \u003ca href=\"https://github.com/zephyrproject-rtos/sdk-ng/releases\"\u003ereleases page\u003c/a\u003e. For example, the current stable \u003ca href=\"https://github.com/zephyrproject-rtos/sdk-ng/releases/tag/v0.17.0\"\u003eZephyr SDK 0.17.0\u003c/a\u003e release includes toolchains\u0026nbsp;\u003ccode\u003extensa-espressif_esp32s3_zephyr-elf\u003c/code\u003e, \u003ccode\u003earm-zephyr-eabi\u003c/code\u003e, etc.\u003c/p\u003e\n\u003cp\u003e\u0026nbsp;\u003c/p\u003e\n\u003cp\u003eThe command line help system for\u0026nbsp;\u003ccode\u003ewest sdk\u003c/code\u003e\u0026nbsp;acts a bit strange:\u003c/p\u003e\n\u003col\u003e\n\u003cli\u003e[update 2/3/2025: this has been fixed] The implementation of \u003ccode\u003ewest sdk\u003c/code\u003e comes from code in the \u003ccode\u003ezephyr\u003c/code\u003e repository which is auto-detected by west (see \u003ccode\u003ezephyr/scripts/west-commands.yml\u003c/code\u003e) . If your working directory is somewhere outside of\u0026nbsp;\u003ccode\u003e~/code/zephyr-workspace/zephyr\u003c/code\u003e, then\u0026nbsp;\u003ccode\u003ewest help sdk\u003c/code\u003e and \u003ccode\u003ewest sdk install --help\u003c/code\u003e\u0026nbsp;won't work.\u003c/li\u003e\n\u003cli\u003eThe sdk help commands may trigger an error message if you try to use them before you've installed either the \"full\" or the \"minimal\" sdk.\u003c/li\u003e\n\u003c/ol\u003e\n\u003cp\u003eTo avoid hassles, you can just read the source code for the help messages at\u0026nbsp; \u003ccode\u003ezephyr/scripts/west_commands/sdk.py\u003c/code\u003e. Or, to get the command line help working before you've installed any toolchains, you can install the minimal SDK with:\u003c/p\u003e\n\u003cp\u003e\u003ccode\u003ewest sdk install --no-toolchains\u003c/code\u003e\u003c/p\u003e\n\u003cp\u003eAfter the minimal SDK is installed, you can use these to read command line options documentation:\u003c/p\u003e\n\u003cp\u003e\u003ccode\u003ewest sdk --help\u003c/code\u003e\u003cbr\u003e\u003ccode\u003ewest sdk install --help\u003c/code\u003e\u003c/p\u003e\n      ","metadata":{}}]