Atmel ARM-Based Evaluation Kit for SAM4S16C, 32-Bit ARM® Cortex® Microcontroller ATSAM4S-WPIR-RD ATSAM4S-WPIR-RD Datenbogen

Produktcode
ATSAM4S-WPIR-RD
Seite von 1231
357
SAM4S Series [DATASHEET]
Atmel-11100G-ATARM-SAM4S-Datasheet_27-May-14
Write the data to be programmed in the latch buffer.
Write the programming command in EEFC_FCR. This will automatically clear the FRDY bit in EEFC_TSR.
When Flash programming is completed, the FRDY bit in EEFC_FSR rises. If an interrupt has been enabled 
by setting the bit FRDY in EEFC_FMR, the interrupt line of the EEFC is activated.
Three errors can be detected in EEFC_FSR after a programming sequence: 
Command Error: a bad keyword has been written in EEFC_FCR.
Lock Error: the page to be programmed belongs to a locked region. A command must be run previously to 
unlock the corresponding region.
Flash Error: when programming is completed, the WriteVerify test of the Flash memory has failed.
Only one page can be programmed at a time. It is possible to program all the bits of a page (full page 
programming) or only some of the bits of the page (partial page programming). 
Depending on the number of bits to be programmed within the page, the EEFC adapts the write operations 
required to program the Flash. 
When the Programming Page command is given, the EEFC starts the programming sequence and all the bits 
written at 0 in the latch buffer are cleared in the Flash memory array. 
During programming, i.e. until FDRY rises, access to the Flash is not allowed.
Full Page Programming
To program a full page, all the bits of the page must be erased before writing the latch buffer and launching the WP 
command. The latch buffer must be written in ascending order, starting from the first address of the page. See 
Partial Page Programming
To program only part of a page using the WP command, the following constraints must be respected:
Data to be programmed must be contained in integer multiples of 64-bit address-aligned words.
64-bit words can be programmed only if all the corresponding bits in the Flash array are erased (at logical 
value 1).
See 
Programming Bytes
Individual bytes can be programmed using the partial page programming mode. In this case, an area of 64 bits 
must be reserved for each byte, as shown in