Datasheet

Table Of Contents
read is performed is indicated by the Data Pointer field in the Data Buffer Pointer register
(DATABUFPTR). This field is incremented by one or wrapped by hardware when a read from the DATA
register address is performed. This field can also be programmed, giving the user direct control over
which output buffer register to read from. Note that when AES module is in the CFB operation mode with
the data segment size less than 128 bits, the output data must be read from the first (DATABUFPTR = 0)
and/or second (DATABUFPTR = 1) output buffer registers (see Table 42-1). The Encryption Complete bit
(INTFLAG.ENCCMP) is cleared by hardware after the processed data has been read from the relevant
output buffer registers.
Table 42-1. Relevant Input/Output Data Registers for Different Confidentiality Modes
Confidentiality Mode Relevant Input / Output Data Registers
ECB All
CBC All
OFB All
128-bit CFB All
64-bit CFB First and Second
32-bit CFB First
16-bit CFB First
8-bit CFB First
CTR All
42.6.2.4 Start Modes
The Start mode field in the Control A Register (CTRLA.STARTMODE) allows the selection of encryption
start mode.
1. Manual Start Mode
In the Manual Start Mode the sequence is as follows:
1.1. Write the 128/192/256 bit key in the Key Register (KEYWORD)
1.2. Write the initialization vector or counter in the Initialization Vector Register (INTVECT). The
initialization vector concerns all modes except ECB
1.3. Enable interrupts in Interrupt Enable Set Register (INTENSET), depending on whether an
interrupt is required or not at the end of processing.
1.4. Write the data to be encrypted or decrypted in the Data Registers (DATA).
1.5. Set the START bit in Control B Register (CTRLB.START) to begin the encryption or the
decryption process.
1.6. When the processing completes, the Encryption Complete bit in the Interrupt Flag Register
(INTFLAG.ENCCMP) raises. If Encryption Complete interrupt has been enabled, the
interrupt line of the AES is activated.
1.7. When the software reads one of the Output Data Registers (DATA), INTFLAG.ENCCMP bit
is automatically cleared.
2. Auto start Mode
The Auto Start Mode is similar to the manual one, except in this mode, as soon as the correct
number of input data registers is written, processing is automatically started without setting the
START bit in the Control B Register. DMA operation uses this mode.
SAM D5x/E5x Family Data Sheet
AES – Advanced Encryption Standard
© 2019 Microchip Technology Inc.
Datasheet
DS60001507E-page 1417