STMicroelectronics BlueNRG-X User Manual

UM2406

User manual

The BlueNRG-X Flasher SW package

Introduction

This document describes the BlueNRG-X Flasher SW package (STSW-BNRGFLASHER) which provides the Flasher Utility PC application.

The BlueNRG-X Flasher Utility is a standalone PC application, which allows the BlueNRG-1, BlueNRG-2 and BlueNRG-LP Bluetooth low energy systems-on-chip Flash to be read, mass erased, written and programmed.

Besides, it supports interface to the BlueNRG-LP, BlueNRG-1, BlueNRG-2 Flash through UART mode using the internal device UART bootloader. It also supports interface to the BlueNRG-LP, BlueNRG-1, BlueNRG-2 Flash through SWD mode by using the standard SWD interface through standard HW programming/debugging tools (CMSIS-DAP, ST-Link/V2 and J-Link).

Finally, it also allows a MAC address to be stored on a specific Flash location selected by the user on both UART and SWD mode.

The BlueNRG-X Flasher SW package also provides a standalone flasher launcher utility which allows the flash programming, reading, mass erase and memory content verification. The flasher launcher utility requires a PC DOS window only.

Note:

The BLUENRG-X term refers the BlueNRG-LP, BlueNRG-1 and BlueNRG-2 devices. Any specific difference is

 

highlighted whenever it is needed.

UM2406 - Rev 6 - December 2020

www.st.com

For further information contact your local STMicroelectronics sales office.

 

 

 

UM2406

Getting started

1Getting started

This section describes all system requirements to run the BlueNRG-X Flasher Utility PC application, as well as the relative SW package installation procedure.

1.1System requirements

The BlueNRG-X Flasher Utility has the following minimum requirements:

PC with Intel® or AMD® processor running one of the following Microsoft® operating systems:

Windows 10

Windows 7

At least 128 MB of RAM

USB ports

40 MB of free hard disk space

Adobe Acrobat Reader 6.0 or later

Note:

Recommended display scale and settings are up to 125%

1.2SW package setup

User can run this Utility by clicking on the BlueNRG-X Flasher Utility icon under: Start → ST BlueNRG -X Flasher Utility x.x.x → BlueNRG-X Flasher Utility.

Figure 1. BlueNRG-X Flasher Utility

UM2406 - Rev 6

page 2/26

 

 

UM2406

Toolbar interface

2Toolbar interface

In the toolbar section of the BlueNRG-X Flasher - Utility main window, user can perform the following operations:

Load an existing .bin or .hex (Intel extended) file (from File menu: open file.. option)

Save the current memory image in a .bin File (from File menu: save file as option). The start address and the size of the memory section to be saved to file are selectable from the ‘Device Memory’ tab

Close an existing .bin or .hex file (from File menu: close file option)

Set ST Link frequency (from Tools menu: Settings... option)

Enable or disable log files creation in UART/SWD modality (from Tools menu: Settings... option). If log files are saved, it is possible to set the level of debug information to save (for SWD only). All log files will be saved under path: {Installation Path}\ST\BlueNRG-X Flasher Utility x.x.x\Logs\”

Mass erase (from Tools menu: mass erase option)

Verify Flash content (from Tools menu: verify flash content option)

Get application version (from Help menu: about option)

Flash (from Tools menu: Flash option)

Erase device sectors (from Tools menu: Erase Pages...option)

Compare the device memory with the selected image file (from Tools menu: Compare Device Memory with a file option). The two image files are displayed on "Compare Device Memory to File" tab and the related differences are highlighted in red

Compare two files (from Tools menu, Compare two files... option)

The user can also select two image files and compare them. The two image files are displayed on "Compare Two Files" tab and the related differences are highlighted in red. *.bin and *.hex files format are supported.

Figure 2. Compare Two Files tab

UM2406 - Rev 6

page 3/26

 

 

UM2406

Toolbar interface

In the upper section of the BlueNRG-X Flasher – Utility main window, user can select the image file through the ‘Select Image File’ button.

All these options are available both on UART and SWD mode.

User needs to enable access to the selected mode (UART or SWD), by opening, respectively, the associated COM port for UART mode, or by connecting an SWD HW programming/debugging tool to the device SWD lines.

UM2406 - Rev 6

page 4/26

 

 

UM2406

UART main window

3UART main window

In the UART main window tab of the BlueNRG-X Flasher Utility main window, user can select the COM port to be used to interface the device through the 'List of COM Ports' section.

The serial baudrate used for the BlueNRG-X evaluation board is 460800 bps.

Figure 3. Flasher Utility UART main window

3.1UART mode: how to run

Image file selection

Use the ‘Select Image File’ button on the main page (or the File> Open File... option or clicking on Image File tab) to load an existing .bin or .hex file. The full path of the selected file appears next to the button and the ‘Flash’ button becomes active at the end of file loading.

The 'List of COM Ports' tab displays all the connected devices on PC USB ports. The 'Select All', Unselect All' and "Invert All' buttons allow to define which connected devices (all, none or some of them) should be the target of the utility operations. This allows to perform same operation (i.e. Flash programming) on multiple devices.

By default, the ‘Mass erase’ option on "Actions" section is not checked, and only the required memory pages are erased and written with the file content. When this option is checked, the memory Flash phase is preceded by a full mass erase.

The ‘Verify’ option forces a check to ensure that the memory content has been written correctly.

Check the ‘Update Device Memory’ option to update the ‘Device Memory’ table after an operation on Flash memory.

The readout protection option enables the readout protection of the device after flash programming.

Check the "Auto Baudrate' option only if an HW reset is performed on the board in order to force the 'Auto Baudrate' operation. By default, the 'Auto Baudrate' option is not checked.

‘Image File’ tab

The selected file name, size and parsed contents to be flashed to the device memory can be viewed in the ‘Image File’ tab.

UM2406 - Rev 6

page 5/26

 

 

UM2406

UART mode: how to run

Figure 4. Flasher utility UART mode: image file

'Device Memory’ tab

Select this tab to view the memory contents of a connected device (through the Read button) and the log about the performed operations on the selected device.

Figure 5. Flasher utility UART mode: device memory

Click the ‘Read’ button to transfer the memory segment defined by ‘Start Address and Size’ into the table. To read the entire Flash memory, check the option "Entire Memory".

The first column gives the base address of the following 16 bytes in a row (e.g., row 0x10040050, column 4 holds the hexadecimal byte value at 0x10040054.

User can change byte values by double-clicking a cell and entering a new hexadecimal value; edited bytes appear in red.

Click the ‘Write’ button to flash the entire page with the new byte values into the device memory.

UM2406 - Rev 6

page 6/26

 

 

STMicroelectronics BlueNRG-X User Manual

UM2406

UART mode: how to run

The ‘Flash’ button allows Flash programming operation to start with the selected option. If the ‘MAC address checkbox is selected user can specify the Flash address where to store the selected MAC address. The MAC address is programmed after image file programming, when the ‘Flash’ button is selected.

Figure 6. Flasher utility UART mode: changing memory fields

'Compare Device Memory to File’ tab

User can compare the current Device memory with the selected image file. The two image files are displayed and the related differences are highlighted in red.

*.bin and *.hex files format are supported.

Figure 7. Compare Device Memory to File

Using the BlueNRG-X Flasher Utility with other boards

UM2406 - Rev 6

page 7/26

 

 

UM2406

UART mode: how to run

The BlueNRG-X Flasher Utility automatically detects the BlueNRG-1, BlueNRG-2, BlueNRG-LP evaluation boards (displayed as STDK) connected to PC USB ports, and uses an auxiliary STM32 (driven by the GUI) to reset the device and put it into UART bootloader mode. The application also works with custom boards providing simple UART access to the connected device, but user must put the device in bootloader mode manually. Upon the selection of any non-STEVAL COM port, the following pop-up appears

Figure 8. Flasher Utility UART mode: UART ‘Comport Setting’ pop-up

 

When this pop-up appears, user must set the BlueNRG-LP pin PA10 high and perform a reset cycle of the

 

BlueNRG-LP device (keeping the PA10 high) or must set the BlueNRG-1, BlueNRG-2 pin DIO7 high and reset the

 

BlueNRG-1, BlueNRG-2 device (keeping the DIO7 high); the device should now be in bootloader mode.

 

User can also set a preferred baudrate for the UART in the pop-up window and then press OK to return to the

 

GUI.

Note:

User must avoid resetting the device while using the BlueNRG-X Flasher Utility unless the "ComPort Setting"

 

pop-up is active. If the device is reset, user must toggle the COM port to use the Flasher Utility again.

Note:

When custom boards are used by providing UART access to the BlueNRG-1, BlueNRG-2, BlueNRG-LP devices

 

through a USB FTDI interface, user should double check the latency associated to the USB FTDI PC driver

 

allowing the connected port as an USB Virtual COM to be recognized. On typical USB-FTDI PC driver, just

 

double check the related device USB driver settings from Properties, Port Settings, Advanced and make sure

 

latency timer value is set to 1 ms. This setting is strongly recommended in order to speed up the Flash

 

operations on custom boards.

UM2406 - Rev 6

page 8/26

 

 

Loading...
+ 18 hidden pages