cancel
Showing results for 
Search instead for 
Did you mean: 

Firmware update

jampino
Associate II
Posted on October 10, 2017 at 15:58

Hello all,

I would like to udpate the firmware on the BLE, I am using an external processor and BLUENRG-1, both of them are connected by SPI and UART but I will be using SPI. 

I would like to update the firmware, I have got the fw image on the processor. Can anyone advise me how to do it?

Thank you. 

13 REPLIES 13
jampino
Associate II
Posted on October 12, 2017 at 10:00

Hello,

Using first time, the BLUENRG-1 with an external processor using SPI, is it necessarily to download into the BLE any fw or I can just send commands from the external processor to the BLE?

I have been using it with no external processor and works fine but not sure how to make it work with external processor.

Thanks 

Posted on October 12, 2017 at 18:02

Hi,

 if you want to use your BlueNRG-1 chip via SPI with an external microcontroller, you need to load the DTM_SPI.hex firmware image on your BlueNRG-1 chip.

Assuming that you have the STEVAL-IDB007V1 board, and that you have already downloaded the latest version (2.5.0 as of now) of the BlueNRG-1/2 Development Kit (

http://www.st.com/content/st_com/en/products/embedded-software/evaluation-tool-software/stsw-bluenrg1-dk.html

), you can refer to the procedure described in the 'STM32_SPI_protocol_example.html' file in the documentation folder of this package(Docs\STM32_SPI_protocol_example_html\STM32_SPI_protocol_example.html).

You can find the DTM_SPI.hex file for BlueNRG-1 in the BlueNRG-1/2 Development Kit installation directory (Firmware\BLE_Examples\BlueNRG-1\DTM\DTM_SPI.hex).

More details about the SPI protocol used by BlueNRG-1/2 are available in the 'SPI_protocol_specification.html' file (BlueNRG-1_2 DK 2.5.0\Docs\SPI_protocol_specification\SPI_protocol_specification.html).

Best regards,

Antonio

Posted on October 13, 2017 at 09:49

Hello Antonio,

Thank you for your response, I am using a custom board with an stm32F7, I have the DTM_SPI image on the processor fw, so the only way I can download the image into the bluenrg-1, I suppose is going into boot mode and then download the image using the uart, is it right?

I am not really sure the steps I have to follow to download the image into the bluenrg-1, I have not found any docs.

Any help about this?

Thank you

Posted on October 13, 2017 at 18:07

I confirm that you can update the firmware running on the BlueNRG-1 chip by using the bootloader via UART.

The BlueNRG-1 bootloader protocol is described by

http://www.st.com/content/ccc/resource/technical/document/application_note/group0/ed/6f/b7/ec/16/1f/41/1c/DM00294188/files/DM00294188.pdf/jcr:content/translations/en.DM00294188.pdf

 Application Note 'BlueNRG-1 and BlueNRG-2 UART bootloader protocol'.

For example, you can use the procedure described in the '4.2.5 Using BlueNRG-1 Flasher utility with other boards' of the

http://www.st.com/content/ccc/resource/technical/document/user_manual/group0/a3/3a/74/0f/5d/89/44/3d/DM00298232/files/DM00298232.pdf/jcr:content/translations/en.DM00298232.pdf

 User Manual.

If your custom board allows you to access the BlueNRG-1 UART via a COM port on the PC, you can use the BlueNRG-1 Flasher utility for PC, but you have to enter the BlueNRG-1 bootloader mode manually:

  • set the BlueNRG-1 DIO7 pin high and reset the BlueNRG-1 device (keeping the DIO7 pin high).

    After that, the BlueNRG-1 will be in bootloader mode.
Posted on October 16, 2017 at 11:49

Hi Antonio,

Thank you so much for your help!!!

jampino
Associate II
Posted on October 19, 2017 at 13:03

Hello, 

I would like to change the pins on the DTM_SPI firmware as we are using different pins for MOSI/MISO/IRQ in our hardware.

Should I change the firmware on the 

directory (Project

\BLE_Examples\BlueNRG-1\DTM\inc\hw_config.h

) and changed for our current pins. Is this the source code use to generate the DTM_SPI.hex on 

(

Firmware\BLE_Examples\BlueNRG-1\DTM\DTM_SPI.hex

)

Thank you

Posted on October 19, 2017 at 16:39

Yes, I confirm that the DTM_SPI.hex file has been generated by the project that you mentioned and that you can use that .h file to reconfigure the pins (please refer to the BlueNRG-1 datasheet to check which alternate pins you can use).

As for the MISO and MOSI pins, the documentation usually refers to them assuming that BlueNRG-1 is the SPI master. In your case, as you'll be using the SPI peripheral as slave, please pay attention that you don't accidentally swap them.

When rebuilding, make sure that you're using the right configuration for your crystal by setting the correct value for HS_SPEED_XTAL in the preprocessor definitions for your project.

Best regards,

Antonio

Posted on October 20, 2017 at 16:33

Hello Antonio,

Thanks for your response. I have done the changes but I am always getting 0xFF response from the ble.

I have removed from the project the DTM_Updater_SPI.c like it is indicated on the DTM_main.c.

In my hardware the connections and the change I have made on the DTM_SPI firmware are:

         HW              BLUENRG-1

   SPI1_SCK ----- SPI CLK (IO0)

   SPI_MISO ----- SPI OUT PIN (IO10)

   SPI_MOSI ----- SPI IN PIN (IO9)

I have set the HS_SPEED_XTAL as well. I am just trying to send the command aci_hal_write_config_data but always getting 0xFF

Thank you

Posted on October 23, 2017 at 11:40

Hi,

maybe

Marchese.Graziella

‌ has some suggestions about this.

Best regards,

Antonio