25.3.4.1.2 RS-485 Mode

RS-485 is a communication standard supported by the USART peripheral. It is a physical interface that defines the setup of a communication circuit. Data are transmitted using differential signaling, which makes communication robust against noise. RS-485 is enabled by setting the Communication Signals (CSIG) bit field in the Control A (USARTn.CTRLA) register to RS485.

The RS-485 mode supports external line driver devices that convert a single USART transmission into corresponding differential pair signals. It implements automatic control of the AUX1 pin, which can be used to enable transmission or reception for the line driver device. The USART automatically drives the XDIR pin high while the USART is transmitting and pulls it low when transmission is complete. An example of circuit is shown in the figure below.

Figure 25-9. RS-485 Bus Connection

RS-485 mode is compatible with One-Wire mode. One-Wire mode enables an internal connection between the TXD pin and the USART receiver, allowing the TXD pin to function as a combined TxD/RxD line. The RXD pin will be disconnected from the USART receiver and may be controlled by another peripheral. An example of such a circuit is shown in the figure below.

Figure 25-10. RS-485 with Loop-Back Mode Connection