MC9S12XHZ512 EEPROM  data storage Problem

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MC9S12XHZ512 EEPROM  data storage Problem

Jump to solution
1,334 Views
SARY
Contributor III

hi

 CAn anyone tell how to read and write data from the above microcontroller?

what command need to be send for reading data from EEPROM?

 

SARY

Labels (1)
1 Solution
546 Views
isionous
Contributor III

Reading from internal EEPROM is like reading from RAM or FLASH. "ldd $0C00" would read a word from EEPROM assuming that $0C00 is an address in EEPROM.  If you are writing in C and there is a variable in the EEPROM, just read from the variable like any other variable.

 

The EPAGE register controls which page of EEPROM is put into the EEPROM window (which is probably at $0800 for your device).

View solution in original post

0 Kudos
2 Replies
547 Views
isionous
Contributor III

Reading from internal EEPROM is like reading from RAM or FLASH. "ldd $0C00" would read a word from EEPROM assuming that $0C00 is an address in EEPROM.  If you are writing in C and there is a variable in the EEPROM, just read from the variable like any other variable.

 

The EPAGE register controls which page of EEPROM is put into the EEPROM window (which is probably at $0800 for your device).

0 Kudos
546 Views
SARY
Contributor III

hi

Thanks for your help.There was some address problem .

I Changed thhe address and now its working fine.

Now I m able to read and write data from the EEPROM.

 

SARY

0 Kudos