lpc1763, 115200 baudrate

Discussion created by lpcware Employee on Jun 15, 2016
Content originally posted in LPCWare by alexxx on Fri Jun 21 01:17:03 MST 2013


I am using LPC1763, and I am not able to configure UART3 in 115200 baud. UART0 and UART2 are working fine with 57600 and 38400 respectively. The strange thing is that when I configure UART3 in 57600 baud, it works OK. I keep tx and rx lines of UART3 shorted, so there is echo. Terminal software confirms that the bytes are OK.

But when I configure UART3 in 115200, then I read garbage from the echo. But my terminal PC software receives the characters send by UART3 OK, in 115200 rate. So transmission is OK in 115200 (terminal software receives OK) but I read garbage from the echo.

My external crystal is 24MHz, and I use the CMSIS libraries of IAR compiler, so code shouldn't be a problem. However, I debugged the code and baudrate registers seem to take proper values during UART3 initialization.

Thanks in advance.


EDIT: Values used from IAR library for UART3 115200 initialization are: DLM=0, DLL=2, DIV=5, MUL=8, which gives actual baud = 115384. That gives a bitrate offset of less than 0.2%, which should work OK.