We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
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 ?
Could you please let me know why does ALTFUNCSET set to bit 5?
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.