nRF Academy Intermediate Course - Lesson 1 Exercise 1: Issue with Debugging

Hello,

I tried following the exercise until the part where you start a debugging session. I looked at the thread viewer and the result was different than what was on the exercise. The picture below shows that the running thread is the idle thread instead of the main thread. Execution is supposed to break by default at main(). I tried manually putting a breakpoint in the main function but it didn't work either.

After that I tried changing the build configuration and unchecked "Include debug thread information". Somehow this fixed the problem. The result I'm getting in the thread viewer matches what's on the exercise. I can still see the thread names and stack usage even with the "Include debug thread information" unchecked.

Edit: I continued the exercise and am unable to see the details of the message queue in the watch list like in the exercise. Could this be because I unchecked "Include debug thread information"?

Parents
  • Hello,

    I suspect that the behavior you are seeing is based on what you selected when you clicked "start debug session". Can you plaese let me know, right before you click "Debug", Did you use the build folder, or the application name below that?

    Which one of the red arrows was selected?

    And after you changed your build configuration, was the application built again? And was it flashed again?

    Best regards,

    Edvin

Reply
  • Hello,

    I suspect that the behavior you are seeing is based on what you selected when you clicked "start debug session". Can you plaese let me know, right before you click "Debug", Did you use the build folder, or the application name below that?

    Which one of the red arrows was selected?

    And after you changed your build configuration, was the application built again? And was it flashed again?

    Best regards,

    Edvin

Children
  • Hello Edvin,

    I used the application name below the build folder (bottom red arrow) when I started the debugging session and I also do the same for flashing. Is there a difference between using one vs the other? 

    I right click the build folder, remove the build configuration and make another one. Sometimes if I just edit the build configuration it will keep telling me to do a pristine build even after doing a pristine build already. I don't know what's causing this so I just remove the build config and make a new one if I want to make changes.

    For this exercise, I usually just press debug without flashing after making changes. Although at some point I did try flashing first before using the debugger but I didn't notice any difference.

    Thank you

Related