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.

debug_msg()

Hi,
Can anyone tell me how to use debug_msg() to print the variables from the application?
I have used debug_msg( 5, 0x04, 3, zclSampleSw_DstAddr.panId, NULL, NULL );
but it is not working to print the pan Id

  • Check if you define MT_TASK and APP_DEBUG in your project.
  • Thank you for the reply.
    After defining both MT_TASK and APP_DEBUG, I am getting the following errors
    1 - cannot open source file "DebugApp.h", which has been called in DebugTrace.c
    and MT.c
    2 - function "DebugApp_SendQuery" declared implicitly

    For
    1 - I have searched through libraries and internet but not finding this DebugApp.h for home automation stack.
    So I commented that header.
    2 - I declared the function "DebugApp_SendQuery"
    as extern uint8 DebugApp_SendQuery( uint16 param1 ); But I was getting a linker error.
    So I commented that function too.

    After this I was able to compile the code but still not able to print msg using debug_msg().
  • I suggest you define MT_DEBUG_FUNC and use API MT_ProcessDebugMsg() to send debug message.