nRF5 SDK v11.0.0
Running the serial bootloader example
This example requires one of the following SoftDevices: S130, S132, S332

Important: Before you run this example, make sure to program a SoftDevice.

Instead of using BLE as transport protocol, you can also use serial transport. The SDK provides two example applications for serial (HCI) transport, one for a single-bank update and another for a dual-bank update. See Dual-bank and single-bank updates for more information about these update types.

The general setup and the process of programming the SoftDevice and bootloader are as described in Running the BLE bootloader example. However, you cannot use the Master Control Panel to perform a Device Firmware Update. Instead, nRFgo Studio provides a tool that is similar to the Advanced: IronPython script for DFU for BLE.

Updating the device firmware

Program the SoftDevice and bootloader as described in Programming the DFU bootloader, but use one of the examples for serial transport. The examples for serial transport do not actually require any SoftDevice functions, but installing the SoftDevice provides the Master Boot Record, which is required for running the bootloader.

You can find the source code and project file of the examples in the following folder: <InstallFolder>\examples\dfu\bootloader

The tool that you use to update the device firmware is delivered with nRFgo Studio. To use it, ensure that you have installed nRFgo Studio v1.18 or later. By default, the script is located in the C:\Program Files (x86)\Nordic Semiconductor\nRFgo Studio\ folder.

As test images, you can use the firmware images that are provided in the folders <BaseFolder>\dfu\hci_dfu_send_hex\test_images_single_bank_update or test_images_dual_bank_update, respectively. If you are using the repository distribution variant of the SDK, <BaseFolder> is <InstallFolder>\examples. Use the images for the example that you are running. You cannot update a single-bank bootloader to a dual-bank bootloader or vice versa.

The script uses the following syntax:

nrfutil.exe dfu serial --package <> --port <com_port> [--flowcontrol] [--baudrate <baud_rate>]

Use nrfutil.exe --help to display usage information.

Verifying the transferred firmware

If you used one of the provided example image files, you can verify that the Device Firmware Update completed as expected as follows:

Image Verification
With the updated bootloader, LED 4 is lit instead of LED 3 when the device is in bootloader mode.
Check the data at location 0x00003000 by issuing the following command:
nrfjprog –memrd 0x3000 –w 32 –n 16
The data has changed to FFFFFF10 51B1E5DB 0001B000 FFFFFFFF. Before the update, the last two bytes were 0078 for the S130 SoftDevice 2.0.0-7.alpha or 0079 for the S132 SoftDevice 2.0.0-7.alpha (other SoftDevices might have a different value). Open the Master Control Panel. The device is advertising as "Dfu_HRM".

Documentation feedback | Developer Zone | Updated