In ADuCM302x and ADuCM4050, the UART baud rate is derived from the PCLK (Peripheral Clock) frequency as per the equation below.
The fractional baud rate generator as indicated by the equation above, provides the option to configure a precise baud rate. However, for a moment, let's consider a simplified equation, by bypassing the fractional baud rate generator.
This equation gives us the UART symbol/baud rate. If you are looking for data throughput, this would depend on the number of data bits (between 5 and 8 bits), as well as number of parity bits and stop bits used. The range of resulting word size (data + parity + start and stop bits) would be between 7 and 12 bits. As an example, for baud rate of 1.5 Mbps, the throughput would be 150K words/second for a 10-bit word size comprising of 8 bits of data, 1 start bit and 1 stop bit with no parity.
For max PCLK frequencies of 26MHz (maximum PCLK frequency in case of ADuCM302x) and 52MHz (maximum PCLK frequency in case of ADuCM4050) and parameters OSR = 0 and DIV = 1, the simplified equation above actually translates to maximum UART baud rates of 6.5Mbps and 13Mbps for ADuCM302x and ADuCM4050 respectively. Now, it is important to note that these are the theoretical maximum baud rates. The practical UART baud rate that can be achieved in a system will depend on several factors, some of which are listed below for your consideration.
1. MCU Data handling capacity
This depends on how many DMA channels you might be using. Or if you are using the interrupt mode to transmit bursts of data, whether the MCU core can process the interrupts in time, to avoid missing data.
2. UART Receiver handling capacity
The baud rate you can use depends on the max baud rate that the UART receiver can support. For instance, if you use an FTDI chip based UART-to-USB adapter for logging UART data on a PC, then you would need to consider the maximum UART baud rate supported by the FTDI chip as well.
3. Error budget, Accuracy of Clock Source and Oversampling
, where ‘S’ is the oversampling ratio. See this academic paper for reference.
For example, when S = 4, the error budget would be ~2.85%. When S = 8, the error budget would be ~4.35%. This oversampling ratio will determine the value of the ‘OSR’ parameter you select. S = 2^(OSR + 2). Higher the OSR you need to set (depending on the error budget in your system, as determined mainly by clock source accuracy), lower the UART baud rate you might be able to use.
Note: some of the equations and calculations above might be approximations (for some example UART configurations) and are meant more to provide a feel for the variables involved.