Figure 32-12. LIN Break and Sync Fields
Break Field
Sync Field
8 bit times
After a break field is detected and the start bit of the Sync Field is detected, a counter is started. The
counter is then incremented for the next 8 bit times of the Sync Field. At the end of these 8 bit times, the
counter is stopped. At this moment, the 13 most significant bits of the counter (value divided by 8) give
the new clock divider (BAUD.BAUD), and the 3 least significant bits of this value (the remainder) give the
new Fractional Part (BAUD.FP).
When the Sync Field has been received, the clock divider (BAUD.BAUD) and the Fractional Part
(BAUD.FP) are updated after a synchronization delay. After the Break and Sync Fields are received,
multiple characters of data can be received.
32.6.3.5. RS485
RS485 is available with the following configuration:
•
USART frame format (CTRLA.FORM = 0x00 or 0x01)
•
RS485 pinout (CTRLA.TXPO=0x3).
The RS485 feature enables control of an external line driver as shown in the figure below. While
operating in RS485 mode, the transmit enable pin (TE) is driven high when the transmitter is active.
Figure 32-13. RS485 Bus Connection
TXD
TE
USART
RXD
Differential
Bus
The TE pin will remain high for the complete frame including stop bit(s). If a Guard Time is programmed in
the Control C register (CTRLC.GTIME), the line will remain driven after the last character completion. The
following figure shows a transfer with one stop bit and CTRLC.GTIME=3.
Figure 32-14. Example of TE Drive with Guard Time
TXD
Start
Stop
Data
GTIME=3
TE
The Transmit Complete interrupt flag (INTFLAG.TXC) will be raised after the guard time is complete and
TE goes low.
32.6.3.6. ISO 7816 for Smart Card Interfacing
The SERCOM USART features an ISO/IEC 7816-compatible operating mode. This mode permits
interfacing with smart cards and Security Access Modules (SAM) communicating through an ISO 7816
link. Both T=0 and T=1 protocols defined by the ISO 7816 specification are supported.
ISO 7816 is available with the following configuration:
•
ISO 7816 format (CTRLA.FORM = 0x07)
•
Inverse transmission and reception (CTRLA.RXINV=1 and CTRLA.TXINV=1)
•
Single bidirectional data line (CTRLA.TXPO and CTRLA.RXPO configured to use the same data
pin)
•
Even parity (CTRLB.PMODE=0)
Atmel SAM L22G / L22J / L22N [DATASHEET]
Atmel-42402E-SAM L22G / L22J / L22N_Datasheet_Complete-07/2016
612