This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

RTOS/AM5728: Log print function

Part Number: AM5728
Other Parts Discussed in Thread: SYSBIOS

Tool/software: TI-RTOS

Hi,

Does sysbios' Log_print function support "% c" or "% s"?

It seems that the following code does not output it.

Log_print1(Diags_INFO, "message recieved IPU :%c", msg->value);
Log_print1(Diags_INFO, "message recieved IPU :%s", msg->values);

"% d", "% x" can be used.
Does it need to add a definition in something *. Cfg file


Best Regards,
Shigehiro Tsuda

  • Hi,

    Yes, %c and %s are supported. Please refer to the SYS/BIOS API Reference for format details. Note: you have to be careful with the %s. Only the address of the string is stored in the Log record, not the actual string. So the string must be persistent or at least still valid when ROV looks at it.

    For example, I added the following in an example and it showed up fine in ROV.

    Log_print3(Diags_USER1, "%c, %s, %d", '!', (IArg)"howdy", 2);