S12ZVCA EEPROM write problem

cancel
Showing results for 
Search instead for 
Did you mean: 

S12ZVCA EEPROM write problem

117 Views
s_kim1
Contributor III

Hello,
I am a developer developing with S12ZVCA192 MCU.

I want to save the flag value to EEPROM.

But there is a problem.

I can't check the EEPROM Memory value with Debug.

I want to check the data I have stored in EEPROM.

1. I simply stored the data as IEE1_SetByte. (0x09)
2. After IEE1_SetByte, it was confirmed that the data was saved with IEE1_GetByte.
3. Edit the code to clear the IEE1_SetByte part.
4. Debug and read data with IEE1_GetByte. (I think 0x09 should be stored in EEPROM.)
5. The data has changed. (0x09 -> 0xFF)
6. The problem is unknown.
7. Is the data not saved?
8. Is the data initialized during Debug?

I can't confirm what the problem is.

I'll add the source code and pictures.

Please check and point out if there is a problem with the values ​​I have set.

1) Execute IEE1_SetByte and then execute IEE1_GetByte
Confirm that the data(0x09)is saved

Screenshot_96.png

2) Clear IEE1_SetByte and execute IEE1_GetByte
check that the data(0xFF) has changed

Screenshot_97.png

thanks,

Tags (4)
0 Kudos
2 Replies

90 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @s_kim1,

Can you use the Memory Browser as it was discussed here:

https://community.nxp.com/t5/S12-MagniV-Microcontrollers/Debugger-EEPROM-Read-S12ZVML128/m-p/1007936

 

BR, Daniel

0 Kudos

99 Views
kef2
Senior Contributor IV

That's known old Codewarrior bug. On S12ZVC it always shows first (hm, perhaps first 64) EEPROM locations as erased to 0xFF. I'm not sure which forums contains my question about the same, it was asked couple years ago. You may use expressions or some other means to read right values. Try adding *(char*)0x10020 to expressions.

Edward

0 Kudos