# OTA Firmware Upgrade Using mcumgr
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
The `mcumgr` tool enables over-the-air (OTA) firmware upgrades over the device’s Wi-Fi interface. The QCC730 acts as the simple management protocol (SMP) server, and the `mcumgr` tool runs on the host PC as the client. To perform an OTA update, ensure that the device is connected to a secure network, and then use `mcumgr` commands to upload the new firmware image. This process allows for seamless and reliable updates without the need for physical access and simplifies ongoing maintenance.
## Set up the `mcumgr` tool on the host PC
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
The `mcumgr` tool is free. It's built using Go. You must set up the Go environment on the host PC before using the `mcumgr` tool. Follow the instructions in the following sections to setup the environment and build the `mcumgr` tool on a PC.
### Prepare the Go environment
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
Follow these steps to prepare the Go environment on the host PC:
1. Download the latest Go windows installer for 64bit system from the following website:
[https://go.dev/dl/](https://go.dev/dl/)
2. Run the downloaded .MSI file and follow the installation wizard to install Go.
Accept the default installation path: C:\Program Files\Go.
The installer automatically adds Go to the `Path` environment variable.
3. Verify the installation by running the following command in Command Prompt or PowerShell:
go versionCopy to clipboard
The following is an example output that indicates the installation is successful:
go version go1.25.6 windows/amd64Copy to clipboard
4. Run the following commands to check Go environment:
go env GOPATH
go env GOROOTCopy to clipboard
Typically,
- `GOPATH` is C:\Users\<YourUsername>\go
- `GOROOT` is C:\Program Files\Go
### Install Git
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
Follow these steps to install Git:
1. Download Git for Windows (Git-2.x.x-64-bit.exe) from the following website:
[https://git-scm.com/download/win](https://git-scm.com/download/win)
2. Run downloaded .EXE file to install Git and select the following options in the installation wizard:
- **Use Git from the Windows Command Prompt**
- **Checkout Windows-style, commit Unix-style line endings**
- **Use Windows' default console window**
3. After the installation is complete, run the following command to verify the installation:
git --versionCopy to clipboard
The following is an example output that indicates the installation is successful:
git version 2.x.x.windows.1Copy to clipboard
### Build mcumgr
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
Follow these steps to build the `mcumgr` tool:
1. Run the following command to clone the `mcumgr` repository:
git clone https://github.com/apache/mynewt-mcumgr-cli.gitCopy to clipboard
2. Go to the mynewt-mcumgr-cli folder and build `mcumgr` by using the following commands:
cd mynewt-mcumgr-cli
go buildCopy to clipboard
Note: Make sure the Go environment is set up before running these commands.
3. Add the location of the generated `mcumgr` executable to the `Path` environment variable.
## Prepare OTA images for QCC730
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
You can use the gen\_fw\_upgrade\_img.py script to combine the SBL and APP images. The following table lists the options of this command.
| Options | Description |
| --- | --- |
| --xml XML | The XML file for the firmware upgrade image generator.
The project path is: modules\hal\qcom\qfdt\fw\_upgrade.xml |
| --output OUTPUT | The output file. |
| -d BUILD\_DIR | Build directory to search for ELF files, similar with the `west build` options |
| -b BOARD | Board name (for example, qcc730mi, qcc730evbx) to determine SBL filename, similar with the `west build` options. |
| --secure-boot | List current image status. |
| -v {0,1,2,3,4,5} | Verbosity levels. A higher level includes all lower levels.
For example, selecting level 3 includes messages from levels 0, 1, 2, and 3.
`0`: Critical
`1`: Error
`2`: Warning
`3`: Info [Default]
`4`: Debug
`5`: Everything |
**Examples**:
- In qapp\qcli\_app, use the following command to generate all needed files:
west build -b qcc730mi -d build/qcc730miCopy to clipboard
- To generate normal SBL/APP images, use the following command:
python ..\..\modules\hal\qcom\qfdt\gen_fw_upgrade_img.py –xml ..\..\modules\hal\qcom\qfdt\fw_upgrade.xml -b qcc730mi -d build/qcc730mi –output build\qcc730mi\zephyr\ota.bin -v 5Copy to clipboard
- To generate secure SBL/APP images, use the following command:
python ..\..\modules\hal\qcom\qfdt\gen_fw_upgrade_img.py –xml ..\..\modules\hal\qcom\qfdt\fw_upgrade.xml -b qcc730mi -d build/qcc730mi –output build\qcc730mi\zephyr\ota.bin -v 5 –secure-bootCopy to clipboard
## Use `mcumgr` for OTA firmware upgrade
Source: [https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html)
The following procedure shows how to use the `mcumgr` tool to perform OTA firmware upgrade for QCC730:
1. Connect both the QCC730 and the host PC to the same AP.
You can use the following shell commands to connect QCC730 to an AP:
- For an open Wi-Fi system:
wifi connect -b Copy to clipboard
- For an AP that uses WPA2 with PSK:
wifi connect -s -b -k 1 -p Copy to clipboard
In these commands:
- ``: The SSID of the AP you are trying to connect to
- ``: 2.4 GHz or 5 GHz band
- `2`: 2.4 GHz
- `5`: 5 GHz
- ``: Passphrase of the AP
For more information about the `wifi connect` command, see [connect](https://docs.qualcomm.com/doc/80-Y8730-5/topic/qcli-demo.html#qcli_wifi_connect).
2. Ensure the IP addresses are assigned to both QCC730 and host PC.
3. Perform OTA firmware upgrade for QCC730. Follow the examples in [Table : OTA firmware upgrade command examples](https://docs.qualcomm.com/doc/80-Y8730-5/topic/ota_firmware_upgrade_using_mcumgr.html#use_mcumgr_for_ota_firmware_upgrade__tbl_example_ota_firmware_upgrade_commands)
Note:
- In these examples, the QCC730 IP address is 192.168.1.15 for demonstration purpose.
- Ensure QCC730 reconnects to the AP after reboot.
Table : OTA firmware upgrade command examples
| Options | Description | Example |
| --- | --- | --- |
| conn add | Add the connection profile | mcumgr.exe conn add udp15 type=udp connstring="[192.168.1.15]:1337"Copy to clipboard |
| Echo | A simple test to verify the connection with the target | mcumgr.exe -c udp15 echo helloCopy to clipboard |
| Image upload | Upload the `ota.bin` to the target. The QCC730 reboots automatically after the upload is complete. | mcumgr.exe -c udp15 image upload build\qcc730mi\zephyr\ota.bin
880.86 KiB / 880.86 KiB [===================================================================] 100.00% 3.91 KiB/s 3m45s
DoneCopy to clipboard |
| Image confirm | Confirm the trial image. The QCC730 reboots automatically after the command is done. | mcumgr.exe -c udp15 image confirm
DoneCopy to clipboard |
| image list | List current image status. | mcumgr.exe -c udp15 image list
Images:
image=0 slot=0
version: 4.0.0
bootable: true
flags: active confirmed
hash: Unavailable
image=0 slot=1
version:
bootable: false
flags:
hash: Unavailable
Split status: N/A (0)Copy to clipboard |
Last Published: Jul 30, 2026
[Previous Topic
WPA2/WPA3-Enterprise Wi-Fi](https://docs.qualcomm.com/bundle/publicresource/80-Y8730-5/topics/wpa2_wpa3_enterprise_wi_fi.md) [Next Topic
Peripheral tests](https://docs.qualcomm.com/bundle/publicresource/80-Y8730-5/topics/peripheral_test.md)