Hi. I'm doing the UART example, supposed to be 115200 baud and it is when I use internal osc but when I use the external 25MHz crystal I'm actually getting 74184 baud. (using TivaWare_C_Series-2.1.4.178)
I measured external xtal and it's running at 25MHz exact.
ui32SysClock = SysCtlClockFreqSet((SYSCTL_XTAL_25MHZ | SYSCTL_OSC_MAIN |
SYSCTL_USE_OSC), 25000000);
I verified with debugger that ui32SysClock is set to 25000000.
...
MAP_UARTConfigSetExpClk(UART0_BASE, ui32SysClock, 115200,
(UART_CONFIG_WLEN_8 | UART_CONFIG_STOP_ONE |
UART_CONFIG_PAR_NONE));
Alternatively when I use internal osc, as shown below, then the baudrate is actually 115200 (and ui32SysClock will be set to 16000000 this time).
ui32SysClock = SysCtlClockFreqSet((SYSCTL_XTAL_16MHZ | SYSCTL_OSC_INT |
SYSCTL_USE_OSC), 16000000);
I'm just curious what could be the cause.
I also tried the PLL like so:
ui32SysClock = SysCtlClockFreqSet((SYSCTL_XTAL_25MHZ | SYSCTL_OSC_MAIN |
SYSCTL_USE_PLL | SYSCTL_CFG_VCO_480), 120000000);
System is running much faster of course but the baudrate is actually correct, 115200 and ui32SysClock is set to 120000000.