Hi,
I am trying to read a global variable in a task that is modified in a different function. The task seems to block totally, unless a "printf" is inserted into it. This would imply something to do with optimization, but this is turned off, I have also tried debug/release versions. I have also tried "volatile" as per another post, and "static" for the variable.
This is the task
"
volatile int Start=0;
Void tsk0_func(UArg arg0, UArg arg1)
{
int send_message = 0;
while (TRUE) {
Task_sleep(20);
send_message = Start;
UserLogCanc[UserLogCancCnt++] = (Uint32)send_message;
UserLogCancCnt &= 0xFFFF;
//System_printf("Start = %d, send_message = %d.\n", Start, send_message);
//ICM_Send_Message(CORE_2, send_message);
}
}"
Where "Start" is modified by a more complicated function that follows it.
Help!
Thanks :)