Tool/software: TI-RTOS
I made the Uart receiving task polling method, and I wrote the code to collect the received data into a package and make it into another task.
Data is received and processed, but occasionally, Uart data is missed due to task priority in Uart task. At this time, we are processing in another task.
1. Can Uart support Blocking Task in TI BIOS?
2. Is it possible to handle SW interrupt instead of polling method for Uart ?
3. I am wondering if there is any sample code or reference Data in questions 1 and 2 above.
Below is a part of the code.
Thank you
main()
{
...
Error_init(&eb);
Task_Params_init(¶ms);
params.priority = 1;
task = Task_create(recvSerial, ¶ms, &eb);
if (task == NULL) {
System_printf("Task_create() failed!\n");
BIOS_exit(0);
}
...
}
void recvSerial()
{
unsigned char recv = 0;
while (1)
{
ret = platform_uart_read(&recv, 1000);
...
Mailbox_post(cmdMbx, &stCmdMsg, BIOS_NO_WAIT);
...
Task_sleep(1);
}
}