Loopback Initialization And Configuration; Initialization And Configuration; Uart And Sci Connections For Loopback Mode - Texas Instruments Concerto F28M35 Series Technical Reference Manual

Table of Contents

Advertisement

www.ti.com
Figure 21-6. UART and SCI Connections for Loopback Mode

21.4.1 Loopback Initialization and Configuration

To enable M3 UART4 to C28 SCI-A loopback, follow these steps:
1. Enable and configure the M3 UART4 module by following the steps outlined in
2. Enable internal loopback mode by setting SERPLOOP[UART4TOSCIA] = 1 on the M3 subsystem.
3. Enable and configure the C28 SCI-A module as described in the Enhanced SCI Module Overview
section of the C28 Serial Communications Interface (SCI) chapter.
To disable loopback between the M3 and C28, set SERPLOOP[UART4TOSCIA] = 0.

21.5 Initialization and Configuration

To enable and initialize the UART, the following steps are necessary:
The peripheral clock must be enabled by setting the UART0, UART1, or UART2 bits in the RCGC1
register (see the System Control and Interrupts chapter).
The clock to the appropriate GPIO module must be enabled via the RCGC2 register in the System
Control module (see the System Control and Interrupts chapter).
Set the GPIO AFSEL bits for the appropriate pins (see the GPIOs chapter). To determine which GPIOs
to configure, see the GPIOs chapter.
Configure the GPIO current level and/or slew rate as specified for the mode selected (see the GPIOs
chapter).
Configure the PMCn fields in the GPIOPCTL register to assign the UART signals to the appropriate
pins (see the GPIOs chapter).
To use the UARTs, the peripheral clock must be enabled by setting the UART0, UART1, or UART2 bits in
the RCGC1 register (see the System Control and Interrupts chapter). In addition, the clock to the
appropriate GPIO module must be enabled via the RCGC2 register in the System Control and Interrupts
chapter. To find out which GPIO port to enable, refer to the GPIOs chapter.
This section discusses the steps that are required to use a UART module. For this example, the UART
clock is assumed to be 20 MHz, and the desired UART configuration is:
115200 baud rate
Data length of 8 bits
One stop bit
No parity
SPRUH22I – April 2012 – Revised November 2019
Submit Documentation Feedback
M3 GPIO Mux
0
Rx
1
Tx
SERPLOOP[UART4TOSCIA]
M3 Universal Asynchronous Receivers/Transmitters (UARTs)
Copyright © 2012–2019, Texas Instruments Incorporated
M3 UART4 to C28 SCI-A Internal Loopback
C28 GPIO Mux
Tx
0
Rx
1
Section
21.5.
1459

Advertisement

Table of Contents
loading

Table of Contents