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.

printf error in TMS570 with CCSv5

Hi, 

I'm trying to use printf in the Hercules TMS570 with CCSv5.3.0. I started following two guides:

[1] http://processors.wiki.ti.com/index.php/Printf_support_for_MSP430_CCSTUDIO_compiler#Compiling_default_printf.28.29_like_functions

[2] http://processors.wiki.ti.com/index.php/Tips_for_using_printf

The fputs function only shows anything if the stream is  stderr.

The fprintf and printf functions don't work. When I call either one of them,  my program finishes.

Do you know if this is caused by any configuration error? What am I doing wrong?

Thanks in advance!

Emanuel.

  • Emanuel,

    Based on the fact that you references those wiki pages, I assume you have already tried increasing stack and heap sizes and it didn't help?

    Are you working with one of the Hercules example projects or used them as a baseline for your project? If so, check to make sure that the stack is not being overwritten by one of their default source files. The C I/O routines typically require a certain amount of stack and heap space as mentioned in the wiki pages you referenced. If the project has assembly routines that also set the stack pointer, they may be overwriting the stack.