LPC55Sxx FLASH read && JLINK programming

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

LPC55Sxx FLASH read && JLINK programming

ソリューションへジャンプ
660件の閲覧回数
hskating
Contributor I

Recently, I have encountered two issues. One is that when the project is in mass production, there are about ten boards. After using JLink to write the firmware onto the LPC5528, when powering on again, there will be a situation where reading a sector with a data size of 256 bytes from the flash will return FLASH->STARTA failure. The development uses Zephyr, and the function is in the position of drivers/flash/soc_flash_mcux.c in the flash_mcux_read() of is_area_readable() and the returned status is FLASH_INT_STATUS_ERR_MASK or FLASH_INT_STATUS_ECC_ERR_MASK. However, I referred to the flash reading operation in the dsbl engineering of LPC55S69, which is consistent with the logic in Zephyr, as shown in the first attached image. But in the document: AN12949 Flash Programming Tips for LPC5500 Series, I also found that there is a flash read operation as shown in the second attached image. So are the final functional effects of these two functions the same? How should I solve this problem? The other issue is that the sample template developed in Zephyr uses LPC55s28, but in fact it is LPC5528. Then in the production bin file and hex file, the offset of the hex file starts from 0x1000 0000. When I use the bin file and download it starting from 0x0, it is also the same. Is there a difference? I saw in the LPC55S6x/LPC55S2x/LPC552x User manual that 0x1000 0000 is the secure part and 0x0 is the ordinary part. The configuration of j-flash is as shown in the third image. Please help solve this quickly because the project has already started mass production and I'm worried that there will be more defects later. thank you.

0 件の賞賛
返信
1 解決策
590件の閲覧回数
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @hskating 

Please fully erase the 10 units, then program a simple SDK example first for testing.
Thank you.
 
BR
Alice
 

 

元の投稿で解決策を見る

0 件の賞賛
返信
3 返答(返信)
616件の閲覧回数
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @hskating 

If the flash is read after erased but before any write operation, an ECC error will occur. Please verify that the entire read flash range has been written to.

For your second question, in your specific case, if you are using an LPC5528, please program it starting from address 0x0.

 

BR

Alice

0 件の賞賛
返信
606件の閲覧回数
hskating
Contributor I
Thank you for your reply. However, regarding the first issue, about 10 pieces were like this during the mass production process. This process involves first programming using JLink, then powering on and starting the chip. It was discovered that in the read area of the flash, there were already data, but it would encounter errors or ECC failure situations. The others that were normal would continue to function normally. So this has confused me. I also used the "reset 0" to reprogram the flash, but the effect was the same.
0 件の賞賛
返信
591件の閲覧回数
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @hskating 

Please fully erase the 10 units, then program a simple SDK example first for testing.
Thank you.
 
BR
Alice
 

 

0 件の賞賛
返信