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.

CCS/TM4C123GH6PM: System_flush without disabling interrupts

Part Number: TM4C123GH6PM

Tool/software: Code Composer Studio

Hi,

I'm working on a project using the TM4C123GXL launchpad board and its in-circuit-debugger, using CCS 7.3 and TI-RTOS.

I've found the System_printf() function to be very convenient for debugging, though I've found that calling system_flush() disables interrupts for a long while (about 70 ms).

Is there a way to use the system_printf facility without disabling interrupts?

(System_printf is like magic to me, I have no clue how it is communicating with the debugger).

If there's no way to use it without disabling interrupts, I'll switch to using a UART to output diagnostic data.

Thanks,

Nathan

  • Hi Nathan,

    When you call System_flush (and I'm assuming you are using SysMin at the System proxy in the .cfg file), the internal buffer is flushed to CIO. This can cause a break-point to occur to allow CCS to read the buffer. Note: printf has this same issue. Here are more details on it: processors.wiki.ti.com/.../Tips_for_using_printf

    When you use System_printf (and again I'm assuming you are using SysMin at the System proxy in the .cfg file), the resulting string is held in an internal buffer (size is dictated by SysMin.bufSize in the .cfg). You can view the string in Tools->ROV->SysMin->OutputBuffer or, as you have been doing, calling System_flush to send the data to the CCS console.

    You can plug in a UART to send the data to a UART. Take a look at the UARTConsole example. The .cfg plugs in UARTUtils_systemPutch for the putch function when sends the character out the UART Note: the putch function is called within the System_printf function. For SysMin, the putch function justs puts the character into the internal buffer.

    Todd