MC9S08PL4 EEPROM use

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

MC9S08PL4 EEPROM use

跳至解决方案
1,227 次查看
leslie
Contributor II

Hi,

I am trying to use the EEPROM in the MC9S08PL4 to remember some settings, but...

When I try to erase one sector, the result in the FSTAT is: only ACCERR is HI.

I tried not to protect the EEPROM by leaving EEPROT erased (FF7D), so that DPOPEN would be HI.

Also FSEC's last bit is LO (FF7F), so SEC[1:0] would be 10b, not secured.

There is a byte called FOPT, that the Reference Manual (Rev.5) doesn't say much about.

My CYCLONE programmer offers securing the MCU, but I don't use that option.

Why do I have no access?

Is there a collection of sample programs, or white paper, or true explanation on how to do it? Production started and the poor thing still can't remember its settings.

HELP PLEASE!

0 项奖励
回复
1 解答
1,216 次查看
leslie
Contributor II

Thank you Vincente,

I got the solution last night. The Reference Manual says global address [23] is used to make a difference between flash and EEPROM. I was stupid enough to follow... maybe it is true only for some commands.

It's all ok now. Yuppieeeee

在原帖中查看解决方案

0 项奖励
回复
2 回复数
1,218 次查看
vicentegomez
NXP TechSupport
NXP TechSupport

Hi

 

Maybe the following application note can help you.

https://www.nxp.com/docs/en/application-note/AN4570.pdf

 

There is also a sample code on the S08PT labs on

https://www.nxp.com/docs/en/supporting-information/TWR-S08PT60-LABS.zip

 

I hope this will help you

 

have a good day

 

0 项奖励
回复
1,217 次查看
leslie
Contributor II

Thank you Vincente,

I got the solution last night. The Reference Manual says global address [23] is used to make a difference between flash and EEPROM. I was stupid enough to follow... maybe it is true only for some commands.

It's all ok now. Yuppieeeee

0 项奖励
回复