nRF Connect SDK Intermediate Lesson 1 Exercise 1 Debugging Issues

Hi

This is my first time using nRF connect and Visual studio but I have been following through first the Fundamentals course on the Dev Academy using the nRF52840 DK with no issues.

However in exercise 1 of lesson 1 of the Intermediate course, when attempting to debug i do not end up in "main" function but in the file ".../zephyr/arch/arm/core/cortex_m/reset.S". I also do not have any of the functions showing in the call stack or any threads in the thread view of the NRF Debug terminal.

The code appears to run correctly if i stop debugging and i get the LEDs toggling and the terminal outputs as expected and i get the same behavior using the solution code so i assume it is something to do with my setup rather than the code itself.

I am connected to the nRF52840 DK directly via USB.

I would be grateful for an suggestions on how to go about resolving this.

  • Hi Edvin,

    I have removed and reinstalled VS code, the command line tools and the jlink drivers you suggested. The only thing of note was that when reinstalling the command line tools it did not prompt me to install a jlink driver so i manually installed the versions you recommended. I also had to add the command line tools and the jlink software to the system Path variables in order for them to be found by VS Code.

    Unfortunately there is no change in the behaviour and still no threads are displayed.

    It should not matter how i am powering and connecting to the dev kit i assume? i am currently just connected and powered over USB.

    Many thanks,

    Tom

  • Hello Tom,

    You should just power it like you usually do when you program the kit. Unfortunately, I am not sure what the issue is, then. But you are able to run a debug session, right? You just don't see the thread information?

    How about debugging with Ozone? Did you try that? I do experience some bugs myself when debugging using VS Code, but most is solved after power cycling the DK, or even deleting the build folder and rebuilding the project.

    BR,
    Edvin

  • Hi Edvin,

    Sorry for the delay in replying.

    Yeah i can run the debug session in VScode but just don't get anything in the thread viewer.

    I have installed Ozone and if i debug with Ozone then i can view the threads and everything appears to work as expected which is good. It still does not answer the problem of it not working in VS code, do you know why one might work and the other not? Either way i can use Ozone for the time being and continue through the Intermediate Dev Academy course.

    Best regards,

    Tom

  • Hello Tom,

    Yes. We have seen some other reports on the same topic as well. We are still investigating. Make sure to regularly update all the extensions/plugins from Nordic, so that you will receive the fix if/when we find it. 

    BR,
    Edvin

Related