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.

System_printf will not output from different source file

System_printf is behaving differently in different source files. I am calling System_printf followed by a System_flush to output debug messages to the CCS console. This method works when I am in main.c. However, when I move to a different source file via function call and attempt to call System_printf followed by a System_flush I get garbage on the console or nothing at all.

I looked at several System_printf related topics and none of them mentioned my specific issue. I tried some of the suggestions those topics had such as increasing the SysMin.bufSize and including the proper xdc runtime files in the individual source files and none of them worked.

Thanks in advance!

-Matt

  • Matt,

    Can I get more information about your setup? What TI-RTOS and XDCTools are you using? What device are you running on? Are you using TI compilers or GCC?

    Thanks,

    Moses

  • Matt,
    it's possible that the code is overwriting the SysMin instance that you are using or the buffer where SysMin keeps the messages. You can debug what's happening if you open ROV and look at the address for 'outBuf' in the Module tab. That address shouldn't change throughout the execution. In the OutputBuffer tab, you can check if the strings from System_printf are being replicated correctly in the OutputBuffer tab.