#define for Debug Mode?

Sysprogs forums Forums VisualGDB #define for Debug Mode?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #12823
    codex653
    Participant

    Hi,

    I’m curious if there is some kind of macro or define statement that would allow me to structure certain portions of my code to execute under the OpenOCD debugger with VisualGDB. Ideally it would be something like:

    if (IN_DEBUG_MODE)
    
    {
    
           //Execute debug specific code here that won't run normally
    
           // like the printf() statement to the ARM Semihosting Console
    
    }
    #12832
    support
    Keymaster

    Hi,

    Please try using #ifdef DEBUG.

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