Pooh said:
The on-chip 512 bytes of user Eeprom is treated as 'XDATA' - auxilliary
data type.
• XDATA
‘External’ Data or Auxiliary RAM. Duplicates the classic 80C51 64 kB memory
space addressed via the MOVX instruction using the SPTR, R0, or R1. All or
part
of this space could be implemented on-chip. The P89LPC932 has 512 bytes of
on-chip XDATA memory.
Page 19 of the data sheet.
See your compiler for the correct method to address this area of memory.
Some familiarity with 80C51 processor types will be assumed.
Oops - spoke too soon.
8.26 Data EEPROM
The P89LPC932 has 512 bytes of on-chip Data EEPROM. The Data EEPROM is
SFR based, byte readable, byte writable, and erasable (via row fill and sector
fill). The
user can read, write and fill the memory via SFRs and one interrupt. This Data
EEPROM provides 100,000 minimum erase/program cycles for each byte.
• Byte Mode: In this mode, data can be read and written one byte at a time.
• Row Fill: In this mode, the addressed row (64 bytes) is filled with a single
value.
The entire row can be erased by writing 00h.
• Sector Fill: In this mode, all 512 bytes are filled with a single value. The
entire
sector can be erased by writing 00h.
After the operation finishes, the hardware will set the EEIF bit, which if
enabled will
generate an interrupt. The flag is cleared by software.
Page 41. That sounds delightfully vague.
Ok - you nead the *USER MANUAL*. The datasheet isn't enough.
Page 115 on tells you how to use it. You need to know how to access the SFRs.
Do you have this level of experience with the 80C51 architecture ? You need to
tell your compiler about the special function registers i.e. their addresses.
I think I'll stick with external serial Eeproms ! ;-)
Graham