Rainbow-electronics ATmega161L Manual de usuario Pagina 122

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 159
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 121
122
ATmega161(L)
1228CAVR08/02
Programming the EEPROM The programming algorithm for the EEPROM Data memory is as follows (refer to Pro-
gramming the Flash for details on command, address and data loading):
1. A: Load Command 0001 0001.
2. H: Load Address High Byte ($00 - $01)
3. B: Load Address Low Byte ($00 - $FF)
4. E: Load Data Low Byte ($00 - $FF)
L: Write Data Low Byte
1. Set BS to 0. This selects low data.
2. Give WR
a negative pulse. This starts programming of the data byte. RDY/BSY
goes low.
3. Wait until to RDY/BSY
goes high before programming the next byte.
(See Figure 78 for signal waveforms.)
The loaded command and address are retained in the device during programming. For
efficient programming, the following should be considered:
The command needs to be loaded only once when writing or reading multiple
memory locations.
Address High byte only needs to be loaded before programming a new 256-word
page in the EEPROM.
Skip writing the data value $FF, that is, the contents of the entire EEPROM after a
Chip Erase.
These considerations also apply to Flash, EEPROM and Signature bytes reading.
Figure 78. Programming the EEPROM Waveforms
$11 ADDR. HIGH ADDR. LOW DATA LOWDATA
XA1
XA2
BS1
XTAL1
RDY/BSY
RESET
WR
OE
+12V
BS2
PAGEL
Vista de pagina 121
1 2 ... 117 118 119 120 121 122 123 124 125 126 127 ... 158 159

Comentarios a estos manuales

Sin comentarios