Hi there,
I have just updated the flashless LPC54S018 MCU on some existing boards. A new batch is.
I am now using the parts with the internal serial flash, the J4M variant.
The boards can be configured to run with either internal or external QSPI flash and both configurations works when I program them using a debug tool like MCUXpresso.
I also have a DFU based bootloader that I use for production programming. That works fine as well but only with boards configured for external flash.
Writing to internal flash fails however.
As far as I can tell the internal flash is a Winbond W25Q part. So there should be no difference between the configurations.
The bootloader code is based on the polling spifi example from the SDK.
It turns out that the example have the same issue, i.e. it works fine with external flash but fails when using internal flash.
Just wondering if anyone has a clue if there is some subtle initialization detail that I am missing when using internal flash.
I must be missing something as internal flash is definitely working and the JLink Flash driver can clearly load code.
Best Regard,
Mike
Hi Edwin,
Neither the example in the link you sent or the lpcxpresso54S018m_spifi_polling_transfer example from the SDK work.
I created a very simple test program to try to isolate the issue. I have attached the code.
It works fine when my board is configured with external flash (W25Q128) but fails with the internal flash which my code
reports with a JEDEC ID of 0xef4016 (W25Q32JVIQ).
I know both configuration actually work as I can download code with MCUXpresso in either configuration but erasing and writing to internal flash from my SRAM based bootloader or the test code below fails.
I still cannot figure out what the issue is. Hopefully someone else can shed some light.
Can anyone confirm if they have been able to get the SDK spifi examples working on a part with internal serial flash.
I am using the LPC54S018J4M.
Best regards,
Mike
Hi @definium,
Please try using the following example code to erase and program the internal flash of the LPC54018JxM: LPC54018JxM:XIP erase and program internal SPIFI Flash - NXP Community.
BR,
Edwin.