@@ -115,7 +115,91 @@ below to retrieve those files.
115115 It is recommended running the command above after :file: `west update `.
116116
117117Building & Flashing
118- -------------------
118+ *******************
119+
120+ Simple boot
121+ ===========
122+
123+ The board could be loaded using the single binary image, without 2nd stage bootloader.
124+ It is the default option when building the application without additional configuration.
125+
126+ .. note ::
127+
128+ Simple boot does not provide any security features nor OTA updates.
129+
130+ MCUboot bootloader
131+ ==================
132+
133+ User may choose to use MCUboot bootloader instead. In that case the bootloader
134+ must be build (and flash) at least once.
135+
136+ There are two options to be used when building an application:
137+
138+ 1. Sysbuild
139+ 2. Manual build
140+
141+ .. note ::
142+
143+ User can select the MCUboot bootloader by adding the following line
144+ to the board default configuration file.
145+ ```
146+ CONFIG_BOOTLOADER_MCUBOOT=y
147+ ` ``
148+
149+ Sysbuild
150+ ========
151+
152+ The sysbuild makes possible to build and flash all necessary images needed to
153+ bootstrap the board with the ESP32 SoC.
154+
155+ To build the sample application using sysbuild use the command:
156+
157+ .. zephyr-app-commands ::
158+ :tool: west
159+ :app: samples/hello_world
160+ :board: esp_wrover_kit
161+ :goals: build
162+ :west-args: --sysbuild
163+ :compact:
164+
165+ By default, the ESP32 sysbuild creates bootloader (MCUboot) and application
166+ images. But it can be configured to create other kind of images.
167+
168+ Build directory structure created by sysbuild is different from traditional
169+ Zephyr build. Output is structured by the domain subdirectories:
170+
171+ .. code-block ::
172+
173+ build/
174+ ├── hello_world
175+ │ └── zephyr
176+ │ ├── zephyr.elf
177+ │ └── zephyr.bin
178+ ├── mcuboot
179+ │ └── zephyr
180+ │ ├── zephyr.elf
181+ │ └── zephyr.bin
182+ └── domains.yaml
183+
184+ .. note ::
185+
186+ With ``--sysbuild `` option the bootloader will be re-build and re-flash
187+ every time the pristine build is used.
188+
189+ For more information about the system build please read the :ref: `sysbuild ` documentation.
190+
191+ Manual build
192+ ============
193+
194+ During the development cycle, it is intended to build & flash as quickly possible.
195+ For that reason, images can be build one at a time using traditional build.
196+
197+ The instructions following are relevant for both manual build and sysbuild.
198+ The only difference is the structure of the build directory.
199+
200+ .. note ::
201+
202+ Remember that bootloader (MCUboot) needs to be flash at least once.
119203
120204Build and flash applications as usual (see :ref: `build_an_application ` and
121205:ref: `application_run ` for more details).
@@ -149,7 +233,7 @@ message in the monitor:
149233 Hello World! esp32_devkitc_wroom
150234
151235 Debugging
152- ---------
236+ *********
153237
154238ESP32-DEVKITC-WROOM support on OpenOCD is available upstream as of version 0.12.0.
155239Download and install OpenOCD from `OpenOCD `_.
0 commit comments