MPC5675K - Software hanging on reading data flash sector

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

MPC5675K - Software hanging on reading data flash sector

ソリューションへジャンプ
2,012件の閲覧回数
mohammedshibin
Contributor I

Hai all,

My application is hanging while I am trying to read data flash sector 1(0x0080_4000) of MCU. All other sectors are working fine.

I have already performed around 10000 write cycle to sector 1. I am reading the sector using an 'unsigned long' pointer.

Please help me to identify the reason. Any help will be appreciated.

Thank you.

0 件の賞賛
返信
1 解決策
1,777件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

It is caused by ECC error, most likely. Each word in data flash memory has hidden 7bit ECC syndrome. The ECC mechanism provides correction of single-bit faults and reporting of multiple-bit errors.

ECC error can occur if:

- erase or program operation is terminated by unexpected reset, so the flash is left in undefined state

- if we programmed word in data flash that is not fully erased (different from 0xFFFFFFFF)

- if we performed too many erase/program cycles (flash wear-out)

In case of single-bit fault, the ECC circuitry automatically corrects the data. In case of multiple-bit error, the flash controller returns bus error and exception is triggered. Take a look at this document and examples for details:

https://community.freescale.com/docs/DOC-103300

The solution is to erase whole flash block. Then it can be programmed and read again.

Regards,

Lukas

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
1,778件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

It is caused by ECC error, most likely. Each word in data flash memory has hidden 7bit ECC syndrome. The ECC mechanism provides correction of single-bit faults and reporting of multiple-bit errors.

ECC error can occur if:

- erase or program operation is terminated by unexpected reset, so the flash is left in undefined state

- if we programmed word in data flash that is not fully erased (different from 0xFFFFFFFF)

- if we performed too many erase/program cycles (flash wear-out)

In case of single-bit fault, the ECC circuitry automatically corrects the data. In case of multiple-bit error, the flash controller returns bus error and exception is triggered. Take a look at this document and examples for details:

https://community.freescale.com/docs/DOC-103300

The solution is to erase whole flash block. Then it can be programmed and read again.

Regards,

Lukas

0 件の賞賛
返信
1,777件の閲覧回数
mohammedshibin
Contributor I

Hi,

Same code is working fine in another board. What could be the reason for hanging in the other board?

0 件の賞賛
返信