Datasheet

122
6120F–ATARM–03-Oct-06
AT91SAM7X512/256/128 Preliminary
20.2.5.2 Flash Write Command
This command is used to write the Flash contents.
The Flash memory plane is organized into several pages. Data to be written are stored in a
load buffer that corresponds to a Flash memory page. The load buffer is automatically flushed
to the Flash:
before access to any page other than the current one
when a new command is validated (MODE = CMDE)
The Write Page command (WP) is optimized for consecutive writes. Write handshaking can
be chained; an internal address buffer is automatically increased.
The Flash command Write Page and Lock (WPL) is equivalent to the Flash Write Command.
However, the lock bit is automatically set at the end of the Flash write operation. As a lock
region is composed of several pages, the programmer writes to the first pages of the lock
region using Flash write commands and writes to the last page of the lock region using a Flash
write and lock command.
n+3 Write handshaking ADDR3 32-bit Flash Address Last Byte
n+4 Read handshaking DATA *Memory Address++
n+5 Read handshaking DATA *Memory Address++
... ... ... ...
Table 20-6. Read Command (Continued)
Step Handshake Sequence MODE[3:0] DATA[15:0]
Table 20-7. Write Command
Step Handshake Sequence MODE[3:0] DATA[15:0]
1 Write handshaking CMDE WP or WPL or EWP or EWPL
2 Write handshaking ADDR0 32-bit Memory Address First byte
3 Write handshaking ADDR1 32-bit Flash Address
4 Write handshaking ADDR2 32-bit Flash Address
5 Write handshaking ADDR3 32-bit Flash Address Last Byte
6 Write handshaking DATA *Memory Address++
7 Write handshaking DATA *Memory Address++
... ... ... ...
n Write handshaking ADDR0 32-bit Memory Address First byte
n+1 Write handshaking ADDR1 32-bit Flash Address
n+2 Write handshaking ADDR2 32-bit Flash Address
n+3 Write handshaking ADDR3 32-bit Flash Address Last Byte
n+4 Write handshaking DATA *Memory Address++
n+5 Write handshaking DATA *Memory Address++
... ... ... ...