FreeRTOs stuck at vsprintf
Hi,
I have used STM32l562-edk evk hardware and stm32cubeide for software. I have enable freertos in the project. For debug print message purpose I have created one function named as logPrint.
char g_msg_buf[100];
void logPrint(const char *format, ...)
{
int DataIdx = 0;
int len = 0;
va_list args;
va_start(args, format);
vsprintf(g_msg_buf,format, args);
len = strlen(g_msg_buf);
for (DataIdx = 0; DataIdx < len; DataIdx++) {
ITM_SendChar( g_msg_buf[DataIdx] );
}
va_end (args);
}
When I have run the program and invoke the logPrint function at that time OS stuck at vsprintf.
Observation:
- When I have disable the freeRTOS then function is working properly and i get the data on console.
- When I have enable the freeRTOS then OS stuck at vsprintf.
Please help me to figure out this issue.
