LPC55S69 : erased flash state

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

LPC55S69 : erased flash state

1,148 Views
EugeneHiihtaja
Senior Contributor I

Hello !

1.

Do I understand right  and FLASH API is designed for be called from secure side only ?

#define BOOTLOADER_API_TREE_POINTER ((bootloader_tree_t *)0x130010f0U)

#define VERSION1_FLASH_API_TREE BOOTLOADER_API_TREE_POINTER->flashDriver.version1FlashDriver

But all FLASH API required Non secure address range e.g started from 0 ?

Does it matter what kind of attributes has erased flash sector , Secure or Not secure ?

2. When I read erased flash memory it has value 0x00, not 0xFF what is typical value ?

3. FLASH API in UM might have wrong parameters explanation:

Erase:

lengthInBytes The length, given in bytes (not words or long words) to be erased. Must be word-aligned.

Program :

lengthInBytes The length in bytes (not words or long words) to be erased; the length must also be 512bytes-aligned.

I think erasing can be done on sector 512 byte basic.

But I  expect it should be possible to write by 4 byte aligned chunks. But I have HardFault if I write less than 512 bytes.

Can I program one dword ( 4 bytes ) at once ?

Regards,

Eugene

Labels (1)
0 Kudos
4 Replies

911 Views
soledad
NXP Employee
NXP Employee

Hi,

Please check the following document:

https://community.nxp.com/docs/DOC-345272 

Regards

Soledad

0 Kudos

911 Views
soledad
NXP Employee
NXP Employee

Hi, 

Please check the following thread and let me know if this helps, 

https://community.nxp.com/thread/521240 

Regards 

Soledad

0 Kudos

911 Views
EugeneHiihtaja
Senior Contributor I

Hi soledad‌ !

I have got modified driver already and it perform basic functions.

But I should be able to write small chunk of data 4-128 bytes and looks like I can write 512 byte chunk only.

I will try to do read/modify/write operation but in your specification amount of partial writes is not specified.

E.g how many times I can write the same page before it should be erased.

And looks like erased page has value 0x00 and it is not clear if I can move bits from 0 to 1 or vise versa.

In UM mentioned that prefetch bit should be disabled while FLASH_Erase/Program operation.

But what about Verify ? Should I disable Acceleration bit as well ?

What about interrupt disabling ? Firmware executed from flash memory and may be I should disable those

and may be during verify as well ?

Regards,

Eugene

0 Kudos

911 Views
EugeneHiihtaja
Senior Contributor I

Hi soledad‌ !

can it be so that fix is need for version 2 of flash board.

But my A2 board returns version 3 :

https://community.nxp.com/thread/521240 

I have added more comments to this thread.

Regards,

Eugene

0 Kudos