MCUmgr SMP OTA Tool — Browser-Based Firmware Update for Zephyr Devices

Update firmware on any Zephyr + MCUboot BLE device directly from your browser. Erase, upload, confirm, and reset — individually or as a full DFU flow. Works with nRF52, STM32WB, ESP32-C3, and more.

⚠ Web Bluetooth required. Use Chrome or Edge on desktop. Firefox and Safari are not supported.

Connect

Full DFU

select .bin file

How it works

MCUmgr speaks SMP (Simple Management Protocol) over BLE, UART, or USB. This tool implements the BLE transport using the Web Bluetooth API, no host tools, no cable, just Chrome or Edge.

SMP messages are CBOR-encoded with an 8-byte header carrying the group ID (OS=0, Image=1), command ID, sequence number, and payload length. BLE responses may arrive across multiple notifications. The tool reassembles fragments by comparing received bytes against the declared payload length in the header.

MCUboot slot mechanics

MCUboot splits flash into two image slots:

  • Slot 0 (primary): running image
  • Slot 1 (secondary): staging area for new firmware

Full DFU sequence:

  1. Erase slot 1 — takes 30–60 s on most MCUs. Flash sectors are large and slow.
  2. Upload — firmware written in chunks over BLE. Chunk size controls throughput.
  3. Confirm — sends {"hash": <sha256_of_slot1>, "confirm": true}, marking slot 1 for boot. On reset, MCUboot swaps it into slot 0.
  4. Reset — device reboots, MCUboot performs the swap, new image runs.

To test a new image before committing, turn Auto-confirm OFF and confirm manually after verifying the device behaves correctly.

Chunk size vs. transfer speed

Chunk size is the raw firmware bytes per BLE write. Larger chunks mean fewer round trips, but the chunk plus SMP overhead must fit in the negotiated ATT MTU and the device’s CONFIG_MCUMGR_BUF_SIZE.

Chunk sizeBLE 4.2 (23B ATT MTU)BLE 5.0 + DLE (251B ATT MTU)~200 KB firmware
64 Bworksworks~3 min
128 Bworksworks~1.5 min
244 Bmay failworks~52 s

Default is 128 B, safe on all BLE versions. The tool auto-tunes chunk size on first upload by halving on timeout until the device responds.

BLE requirements

Your Zephyr app needs one of these, depending on version:

# Zephyr 3.3+
CONFIG_MCUMGR_TRANSPORT_BLE=y
# Zephyr < 3.3
CONFIG_MCUMGR_TRANSPORT_BT=y

Without this the SMP GATT service won’t appear and the connection will fail.

The tool scans for any BLE device and connects to the SMP service UUID 8d53dc1d-1db7-4cd3-868b-8a527460aa84.

Browser support: Chrome and Edge on desktop only. Firefox and Safari do not implement the Web Bluetooth API. Chrome on Android works but has not been tested with this tool.

WebAssembly: SMP packet encoding and CBOR parsing run in a Rust WASM module compiled with wasm-pack. No server involved — everything runs locally in your browser.

Supported devices

Any MCU running Zephyr RTOS with MCUboot and BLE SMP transport enabled:

  • Nordic nRF52 series (nRF52840, nRF52833, nRF52832)
  • Nordic nRF91 series (nRF9160-DK via external BLE)
  • STM32WB series (STM32WB55, STM32WB35)
  • ESP32-C3 / ESP32-S3 (with Zephyr port)
  • Raspberry Pi RP2040 (with Zephyr + Bluetooth module)

Common issues

Erase timeout. On MCUs with larger flash sectors, erase can take over 60 s. If you see SMP timeout during erase, go to Advanced Settings and raise the erase timeout to 90–120 s.

Upload stuck at 0 %. Slot 1 was not erased first, or the MCU ran out of flash write buffers. Erase before uploading.

Confirm fails with “No image in slot 1”. Confirm reads the image list to get slot 1’s SHA-256 hash. If the upload was incomplete or the hash field is missing from the response, it has nothing to confirm. Re-erase and re-upload.

Device disconnects on reset. The BLE connection drops when the device reboots. That’s the reset working. The tool ignores this on the Reset operation.

Frequently asked questions

Which devices are supported? +

Any MCU running Zephyr RTOS with MCUboot and BLE SMP transport enabled — nRF52840, nRF52832, nRF52833, STM32WB55, ESP32-C3, RP2040, and others. The device must have CONFIG_MCUMGR_TRANSPORT_BT=y (or CONFIG_MCUMGR_TRANSPORT_BLE=y) in its Kconfig.

Why does erase take so long? +

Flash sectors on most MCUs are 4–64 KB and must be erased in full before writing. Erasing a 380 KB slot (e.g. nRF52840 MCUboot default) takes 30–60 seconds — this is a hardware constraint, not a protocol limitation.

How long does a full firmware update take? +

Roughly erase time (30–60 s) plus upload time plus a few seconds for confirm and reset. Upload speed depends on chunk size and BLE connection interval. At 128-byte chunks a 200 KB image takes about 90 seconds; at 244 bytes it drops to around 52 seconds.

What does Confirm do exactly? +

Confirm sends an MCUmgr image-state write with {"hash": <slot1-sha256>, "confirm": true}. MCUboot interprets this as "on next boot, swap to this image and mark it permanent." Without confirm, MCUboot will test-boot the image once and revert to slot 0 if the app does not self-confirm.

Why Chrome and Edge only? +

This tool uses the Web Bluetooth API, which is only available in Chromium-based browsers. Firefox ships it behind a flag (disabled by default) and Safari does not support it at all.

What BLE SMP UUID should my firmware expose? +

Your firmware must advertise the SMP service UUID 8d53dc1d-1db7-4cd3-868b-8a527460aa84 — this is what the tool scans for when connecting. Inside that service, the characteristic UUID is da2e7828-fbce-4e01-ae9e-261174997c48, which is used for reading, writing, and notifications.

Newsletter

The embedded engineer's weekly cheat sheet

Register tricks, timing gotchas, and tool updates. One email per week. No fluff.

No spam. Unsubscribe anytime.