I want to program the internal 4 MByte Flash of the LPC54018M via IAP. In the SDK there is the "boards\lpcxpresso54s018m\driver_examples\iap\iap_basic" example, but it doesn't include IAP_PrepareSectorForWrite/IAP_EraseSector functions. These APIs don't work after adding into the example, even though running in on-chip SRAM. Does LPC54018M have IAP FLASH functions?
IAP example
PartID: 1FD4018
The major version is: 1501
The minor version is: 0
Unique ID: 0000
IAP_PrepareSectorForWrite return 0x27d9
IAP_EraseSector return 0x27d9
Solved! Go to Solution.
Hi S.z. Liang
LPC540xx, unlike LPC546xx, doesn't integrate IAP prepare sectors for write operation and erase sector command.
Actually, According to LPC540xx UM, There are only 4 IAP commands valid.
If we check LPC546xx UM, more IAP commands are supported:
That's different.
Have a great day,
Jun Zhang
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi Jun,
I am going to build LPC54S018J4M a internal flash erase/ write function with iap. But as previous question, clarified the iap only 4 command for the chip. could you help to explain how to do a erase/ write bootloader to SRAM through IAR + J-Link for the chip? SPIFI command or other?
I try to use access 0x40080000 (SPIFI command registers), but return me as 0s ~~ Why? any procedure need to enable r/w for this registers?
Thanks, Spring ~~
Hi S.z. Liang
LPC540xx, unlike LPC546xx, doesn't integrate IAP prepare sectors for write operation and erase sector command.
Actually, According to LPC540xx UM, There are only 4 IAP commands valid.
If we check LPC546xx UM, more IAP commands are supported:
That's different.
Have a great day,
Jun Zhang
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Isn't the 54018 a flashless part? That explains why it has no IAP...
Hi
I understood your mentioned "LPC54018M" as "LPC54018JxM", right?
LPC54018JxM has Internal Serial Flash but other LPC540xx doesn't have internal Flash.
So LPC54018JxM has flash. But as LPC54018JxM flash is a internal serial flash, ( encapsulating a SPIFI flash inside the package), It's different with other on chip flash chips. So I am with your angle of view to understand this issue.
Have a great day,
Jun Zhang
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------