this is refer to discuss no 17250
I just want to share how to set the UART2 & UART3 register, after reading further the datasheet, the UART2 & UART3 can you enable with set the Power Connection Register.
/* power UP UART2 & UART3 */ LPC_SC->PCONP |= 0x03000000;
and then you can set-up the uart2 or uart3 register without hang. and the port works correctly.
LPC_PINCON->PINSEL0 |= 0x00500000; /* RxD2 is P0.11 and TxD2 is P0.10 */
LPC_UART2->LCR = 0x83;
LPC_UART2->DLL = 9; /* 115200 Baud Rate @ 25.0 MHZ PCLK */
LPC_UART2->FDR = 0x21; /* FR 1,507, DIVADDVAL = 1, MULVAL = 2 */
LPC_UART2->DLM = 0;
LPC_UART2->LCR = 0x03;
LPC_PINCON->PINSEL0 |= 0x00000000A; /* RxD3 is P0.0 and TxD2 is P0.1 */
LPC_UART3->LCR = 0x83;
LPC_UART3->DLL = 9; /* 115200 Baud Rate @ 25.0 MHZ PCLK */
LPC_UART3->FDR = 0x21; /* FR 1,507, DIVADDVAL = 1, MULVAL = 2 */
LPC_UART3->DLM = 0;
LPC_UART3->LCR = 0x03;