Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
04/16/06 18:07
Modified:
  04/16/06 18:12

Read: times


 
#114343 - Did you read this
Responding to: ???'s previous message
Right from the datasheet
<pre>
EEPROM Data
Memory
This feature is available only for the AT89C51ED2 device.
The 2K bytes on-chip EEPROM memory block is located at addresses 0000h to 07FFh
of the XRAM/ERAM memory space and is selected by setting control bits in the EECON
register.
A read or write access to the EEPROM memory is done with a MOVX instruction.
Write Data
Data is written by byte to the EEPROM memory block as for an external RAM memory.
The following procedure is used to write to the EEPROM memory:
• Check EEBUSY flag
• If the user application interrupts routines use XRAM memory space: Save and
disable interrupts.
• Load DPTR with the address to write
• Store A register with the data to be written
• Set bit EEE of EECON register
• Execute a MOVX @DPTR, A
• Clear bit EEE of EECON register
• Restore interrupts.
• EEBUSY flag in EECON is then set by hardware to indicate that programming is in
progress and that the EEPROM segment is not available for reading or writing.
• The end of programming is indicated by a hardware clear of the EEBUSY flag.
Figure 38 represents the optimal write sequence to the on-chip EEPROM data memory.
Read Data :
The following procedure is used to read the data stored in the EEPROM memory:
• Check EEBUSY flag
• If the user application interrupts routines use XRAM memory space: Save and
disable interrupts.
• Load DPTR with the address to read
• Set bit EEE of EECON register
• Execute a MOVX A, @DPTR
• Clear bit EEE of EECON register
• Restore interrupts.


List of 10 messages in thread
TopicAuthorDate
AT89C51ED2 Internal EEPROM            01/01/70 00:00      
   Datasheet            01/01/70 00:00      
      EEPROM            01/01/70 00:00      
         Mr MUHAMMED            01/01/70 00:00      
            Keil            01/01/70 00:00      
         Did you read this            01/01/70 00:00      
            Easter Gift            01/01/70 00:00      
               Thanks            01/01/70 00:00      
               muhammed            01/01/70 00:00      
                  difference            01/01/70 00:00      

Back to Subject List