380
XMEGA B [DATASHEET]
8291B–AVR–01/2013
Alternative 1:
Fill the flash page buffer
Perform a flash page erase
Perform a flash page write
Alternative 2:
Fill the flash page buffer
Perform an atomic page erase and write
Alternative 3, fill the buffer after a page erase:
Perform a flash page erase
Fill the flash page buffer
Perform a flash page write
The NVM command set supports both atomic erase and write operations, and split page erase and page write
commands. This split commands enable shorter programming time for each command, and the erase operations can be
done during non-time-critical programming execution. When using alternative 1 or 2 above for self-programming, the
boot loader provides an effective read-modify-write feature, which allows the software to first read the page, do the
necessary changes, and then write back the modified data. If alternative 3 is used, it is not possible to read the old data
while loading, since the page is already erased. The page address must be the same for both page erase and page write
operations when using alternative 1 or 3.
30.7.2 EEPROM Programming Sequence
Before programming an EEPROM page with the tagged data bytes stored in the EEPROM page buffer, the selected
locations in the EEPROM page must be erased. Programming an unerased EEPROM page will corrupt its content. The
EEPROM page buffer must be loaded before any page erase or page write operations:
Alternative 1:
Fill the EEPROM page buffer with the selected number of bytes
Perform a EEPROM page erase
Perform a EEPROM page write
Alternative 2:
Fill the EEPROM page buffer with the selected number of bytes
Perform an atomic EEPROM page erase and write
30.8
Protection of NVM
To protect the flash and EEPROM memories from write and/or read, lock bits can be set to restrict access from external
programmers and the application software. Refer to
“LOCKBITS – Lock Bit register” on page 30
available lock bit settings and how to use them.
30.9
Preventing NVM Corruption
During periods when the V
CC
voltage is below the minimum operating voltage for the device, the result from a flash
memory write can be corrupt, as supply voltage is too low for the CPU and the flash to operate properly.To ensure that
the voltage is sufficient enough during a complete programming sequence of the flash memory, a voltage detector using
the POR threshold (V
POT+
) level is enabled. During chip erase and when the PDI is enabled the brownout detector (BOD)
is automatically enabled at its configured level.
Содержание XMEGA B
Страница 320: ...320 XMEGA B DATASHEET 8291B AVR 01 2013 Table 25 12 7 segments Character Table...
Страница 321: ...321 XMEGA B DATASHEET 8291B AVR 01 2013 Table 25 13 14 segments Character Table...
Страница 322: ...322 XMEGA B DATASHEET 8291B AVR 01 2013 Table 25 14 16 segments Character Table...
Страница 412: ...412 XMEGA B DATASHEET 8291B AVR 01 2013...
Страница 413: ...413 XMEGA B DATASHEET 8291B AVR 01 2013...
Страница 414: ...414 XMEGA B DATASHEET 8291B AVR 01 2013...