Dear All,
I came across initial function as the below,
void UartStdOutInit(void){ CMSDK_UART2->BAUDDIV = 16; CMSDK_UART2->CTRL = 0x41; // High speed test mode, TX only CMSDK_GPIO1->ALTFUNCSET = (1<<5); return;
}
At the first time this function is called for initializing uart port.
But I can't understand what CMSDK_GPIO1->ALTFUNCSET = (1<<5); instruction do ?
In the example system we multiplexed the GPIO1 pin 5 with UART2 TX data. And that UART is used for stdout (i.e. printf). So we need to set this bit to allow the testbench to capture the printf output.