Skip to main content

How to upload the firmware to Mesh End Node

1. Choose the correct update workflow

WorkflowMain use
FirmwareUpdateUtility User modeNormal APP update through USB serial or PC BLE
FirmwareUpdateUtility Advanced updateFirst-time programming or recovery under instructions from Dragino support

Instructions for FirmwareUpdateUtility and the other desktop tools are available in the Dragino MeshNode repository. The mobile upgrade feature is still under development.

2. Normal APP update

Use FirmwareUpdateUtility in User mode for a normal APP update through USB serial or PC BLE. Follow Developer Instruction section 2 for the complete procedure.

3. Build firmware from source

The firmware is a PlatformIO project targeting STM32WL and built on Windows with VS Code. Follow Developer Instruction section 1 to build the APP firmware from source.

4. First-time programming and firmware recovery

In FirmwareUpdateUtility, Advanced update opens the STM32 Programming workspace for first-time programming and recovery. Use this procedure only when instructed by Dragino support.

4.1 Production/service connection

Use a 3.3 V TTL adapter because 5 V will damage the MCU.

USB-TTLDevice
TXRX
RXTX
GNDGND

4.2 Flash layout

Dragino Mesh Node firmware uses a Bootloader + APP layout on STM32WLE5JC (256 KB flash, 2 KB pages). The APP starts at 0x08007800; a normal APP upgrade only writes from that offset onward.

Warning

Do not erase the factory identity, application version control, or Bootloader regions during a normal APP upgrade. The factory identity page (0x0803E000) holds the DevEUI and root key used for private-key derivation; losing it requires re-provisioning at Dragino's factory. The application version control page (0x0803F000) must also be preserved. STM32 programming, Bootloader programming, and custom Flash addresses are production or service operations. Do not change addresses or use those advanced functions without explicit instructions from Dragino.

4.3 Program with FirmwareUpdateUtility

STM32 Programming uses the STM32 ROM Bootloader over UART and requires switching the device to ISP.

  1. Open the device enclosure.
  2. Switch the device to ISP and press reset.
  3. Connect the USB-TTL adapter to the device serial port and to the PC.
  4. Open FirmwareUpdateUtility, confirm Advanced update, and open STM32 Programming.
  5. Select the correct serial port and click Detect device.
  6. Confirm that the expected chip, DevEUI, and identity status are reported.
  7. Select the programming target and the firmware file or files supplied for the procedure.
  8. Select the Mesh Flash layout. Do not use custom addresses unless Dragino provides them.
  9. Click Preflight and build plan, then review the validated files, addresses, erase ranges, protected areas, and verification operations.
  10. Click Start programming, review the final confirmation, and wait for completion.
  11. Switch the device from ISP back to normal mode and press reset to start the new firmware when required.
Warning

Do not power off the device or disconnect the USB-TTL adapter during programming. FirmwareUpdateUtility protects the factory identity and application version control pages during normal programming. Do not select Allow invalid identity (lab only), custom addresses, or other advanced options unless specifically instructed by Dragino.

5. Upgrade troubleshooting

SymptomLikely causeHow to diagnose / fix
No COM port is listedCable, power, driver, or port conflictCheck the cable, power, and USB serial driver; close other serial software; then click Refresh
USB port opens, but communication failsIncorrect wiring or device stateConfirm the 3.3 V connection and TX/RX wiring, then retry the Device Overview handshake
BLE scan shows no deviceBluetooth is disabled or the device is not advertisingEnable computer Bluetooth, confirm that the device is advertising, move it closer, and scan again
Firmware file is rejectedUnsupported file or incorrect product firmwareConfirm that the firmware belongs to the target product and is a supported .bin, .hex, or .ihex image
Start update remains disabledDevice information has not been read or the connection is incompleteComplete Device Overview and keep the connection open
STM32 detection fails during recoveryDevice is not in STM32 ROM Bootloader modeSwitch the device to ISP, reset it, confirm the correct COM port and wiring, then detect it again
STM32 programming remains disabledDetection or preflight is incompleteDetect the device and run Preflight and build plan after the last input change
The device behaves abnormally after an upgradeFirmware does not match the product model or shipping RegionConfirm that the firmware matches the product model and Region, then rebuild or re-flash the correct file
Device works but factory identity reads all-FFThe factory identity page was erasedContact Dragino for re-provisioning