How can I initialize the build-in EEPROM on Atmel AT89S8252

Status
Not open for further replies.

MrX

Newbie level 3
Joined
Mar 19, 2003
Messages
3
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
20
I have the AT89S8252, K*il (language C).
I need to place the array with messages in EEPROM.
How can I do it?
 

Hi MrX,

Read careful all topic replies:

**broken link removed**

and this one referenced in the topic above:

**broken link removed**

Regards,
Silvio
 

 

Hi MrX,

https://www.keil.com/support/docs/1106.htm
This is the official answer from K**l knowledge base.

You wrote:
How can I initialize the STRING in EEPROM?

Well, C compilers don't know about EEPROM or RAM or serial EEPROM. If are memory mapped you can access as stated by you:
const char xdata STRING[] = "Hello, World!";

On software the EEPROM space is accessed with MOVX opcode, exactly like for XDATA space. The only difference is that in your access routine you must first configuring the EEMEN bit. As you already did. Thus using a pointer to point to XDATA space (either EEPROM or SRAM) which holds and array it's easy for you.

However, I think the real problem is how your programer device will manage with the EEPROM contiguous stream of 2K hex data and 8K flash data, at burning time.

Regards,
Silviu
 

Thank you.

Thank you.
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…