On the mc9s12hy64 ,The flash address from 0xFE00 to FFFF, when I erase this page ,the MCU is Locked

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

On the mc9s12hy64 ,The flash address from 0xFE00 to FFFF, when I erase this page ,the MCU is Locked

611 Views
hongjianzhang
Contributor III

I want to develop a bootloader ,I want to update the entry address of the app, but when I erase the address of this page, the MCU will be locked, can this page be erased safely?  

Labels (1)
0 Kudos
2 Replies

412 Views
lama
NXP TechSupport
NXP TechSupport

Hi,

It is absolutely normal behavior. The addresses described in data sheet at Table 15-3. Flash Configuration Field shows that 3_FF0C contains flash configuration field. The field is copied to FSEC register during reset. So if you erase this address to FF then you set security of the MCU. You should immediately rewrite the flash field do unsecured state before reset. Note that there is a bootloader you can use AN4258 for your purposes.

http://www.nxp.com/assets/documents/data/en/application-notes/AN4258.pdf

SW files

http://cache.freescale.com/files/microcontrollers/doc/app_note/AN4258SW.zip

BTW; It is not standard and suitable approach to erase last sectors of the flash because there could be affected reset vector.

Best regards,

Ladislav

0 Kudos

412 Views
hongjianzhang
Contributor III

Thank you for your advice, I'll try to use it

0 Kudos