English
Language : 

SAM7X256_14 Datasheet, PDF (125/662 Pages) ATMEL Corporation – ARM-based Flash MCU
Table 20-20. Read Command (Continued)
Read/Write
DR Data
Read
Memory [address+4]
...
...
Read
Memory [address+(Number of Words to Read - 1)* 4]
20.3.4.2 Flash Write Command
This command is used to write the Flash contents. The address transmitted must be a valid Flash address in the memory
plane.
The Flash memory plane is organized into several pages. Data to be written is 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 than the current one
 at the end of the number of words transmitted
The Write Page command (WP) is optimized for consecutive writes. Write handshaking can be chained; an internal
address buffer is automatically increased.
Table 20-21. Write Command
Read/Write
DR Data
Write
(Number of Words to Write) << 16 | (WP or WPL or EWP or EWPL)
Write
Address
Write
Memory [address]
Write
Memory [address+4]
Write
Memory [address+8]
Write
Memory [address+(Number of Words to Write - 1)* 4]
Flash Write Page and Lock command (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.
Flash Erase Page and Write command (EWP) is equivalent to the Flash Write Command. However, before
programming the load buffer, the page is erased.
Flash Erase Page and Write the Lock command (EWPL) combines EWP and WPL commands.
20.3.4.3 Flash Full Erase Command
This command is used to erase the Flash memory planes.
All lock bits must be deactivated before using the Full Erase command. This can be done by using the CLB command.
Table 20-22. Full Erase Command
Read/Write
DR Data
Write
EA
20.3.4.4 Flash Lock Commands
Lock bits can be set using WPL or EWPL commands. They can also be set by using the Set Lock command (SLB). With
this command, several lock bits can be activated at the same time. Bit 0 of Bit Mask corresponds to the first lock bit and
so on.
SAM7X Series [DATASHEET]
6120K–ATARM–11-Feb-14
125