cancel
Showing results for 
Search instead for 
Did you mean: 

BLE App does not work after changing location in memory above standard 0x080000000

MDec.1
Associate II

Hi all,

From Nucleo STM32WB55 to my own application with the same micro.

I have written an application based on Cable Replacement Service from examples.

I did my PCB and everything works.

Now I have to add my own bootloader with cipher.

Beacause of this I would like to place bootloader at the start of the flash memory and application in higher address, i.e. 0x80010000.

Unfortunatelly after modification in the linker script, everything looks that preloaded BLE stack FW, can't communicate with application.

This is my first STM32 project since 2013 and first with BLE so Iam not a master yet :).

In theory I can change the order - APP first and Bootloader in the higher area, but any crash while upgrading firmware will block everything.

What to do?

Regards

Mariusz D

5 REPLIES 5
MDec.1
Associate II

Hi zbigelpl,

Thank you for help :).

It will be usefull for the future but finally, yesterday afternoon I have found this:

https://www.devcoons.com/howto-stm32-custom-bootloader-application/

After few unsuccessfull trys yesterday, now, in the morning I have modified correctly BL and APP and it works :).

Now next step - write to flash, but

../Application/User/Core/flash.c:37:18: error: 'FLASH_TYPEERASE_SECTORS' undeclared (first use in this function); did you mean 'TYPEERASE_SECTORS'?

   .TypeErase = FLASH_TYPEERASE_SECTORS,

This is from:

https://www.devcoons.com/how-to-write-data-to-the-internal-flash-memory-of-an-stm32/

Investigation in progress...

Regards

Mariusz D

P.S.

zbiglpl looks like Zbig L. from Poland. Am I right?

md

MDec.1
Associate II

Hi,

for STM32WB there is an easiest way - there are ready for use prototypes and they are shown in Examples of the Nucleo board.

Mariusz

zbigelpl
Associate II

Hi again,

Glad to hear you've made some progress!

> zbiglpl looks like Zbig L. from Poland. Am I right?

Correct.

MDec.1
Associate II

Hi,

Today I have prepared sceleton of the BL with active interrupts!

It needs another order of calls than suggested in this example.

Looks crazy, but works.

If you are interested I can give you code when finished.

Regards

MariuszDwawpl