ARM Semi-Hosting question

Sysprogs forums Forums VisualGDB ARM Semi-Hosting question

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #20389
    sidprice
    Participant

    I am using the above to help debug and trace my project code, however I am not sure what to do for my production code.

    In the settings for my embedded project I can disable semi-hosting, do I also need to remove the “printf” calls that were sending output through the debug pod using semi-hosting?

    Thank you,

    Sid

    #20391
    support
    Keymaster

    Hi,

    Yes, you would need to remove the calls to printf(). The easiest way to do this would be via using conditional compilation, e.g.

    #ifdef _DEBUG
    #define LOG(...) printf(__VA_ARGS)
    #else
    #define LOG(...)
    #endif
    #20394
    sidprice
    Participant

    Excellent, thanks again,

    Sid

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.