Part Number: TM4C123GH6PM
Tool/software: Code Composer Studio
Hey! So I have what's hopefully a quick question. I successfully used UART0 to send data to PuTTY. Then I tried to use another UART in order to send data to my Analog Discovery module (as a first stage before sending data to an ESP8266 Wifi module). However, I am not getting any data on my Analog Discovery. I am confident that the Analog is set up correctly because I have used it for a similar task in a previous project.
Below is the code where I configure the UART module. I am using UART7 in the code below simply because I tried going through all of the others already. The code is a modification of the TI usb_dev_gamepad.c example code.
void ConfigureUART(void)
{
//
// Enable the GPIO Peripheral used by the UART.
//
SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOE);
//
// Enable UART7
//
SysCtlPeripheralEnable(SYSCTL_PERIPH_UART7);
UARTDisable(UART7_BASE);
//
// Configure GPIO Pins for UART mode.
//
GPIOPinConfigure(GPIO_PE0_U7RX);
GPIOPinConfigure(GPIO_PE1_U7TX);
GPIOPinTypeUART(GPIO_PORTE_BASE, GPIO_PIN_0 | GPIO_PIN_1);
//
// Use the internal 16MHz oscillator as the UART clock source.
//
UARTClockSourceSet(UART7_BASE, UART_CLOCK_PIOSC);
//
// Initialize the UART for console I/O.
//
UARTStdioConfig(0, 115200, 16000000);
UARTEnable(UART7_BASE);
}
And here is the section of code where the data is sent
void sendData()
{
UARTprintf("%d.%d%d%d\n", ones, tenths, hundredths, thousandths);
}
Thanks!