nRF Connect Example Function "Go to Definition" returns "No definition found... " in VS Code

Hi, 

I started using nRF Connect SDK in VS Code recently. Everything works well, start a new Application, configure a new board, build, and flash. 

While I found "Go to Definition" by right click on the function name or Macro always return "No definition found... ". 

I build a C project with multiple files in VS Code and this feature works well.

It looks like a SDK searching path problem. 

I explored a little bit on the internet, someone suggested to use the command "nRF Connect: Add nRF Connect SDK to Workspace". However, it doesn't work, or maybe I used it in a wrong way. 

Does anybody can help? 

Thanks, 

Ji

Parents
  • Hi,

    You can find more information about VS Code workspaces here.

    Have you installed C/C++ extension?

    Could you provide more information on how you invoked the command "Add nRF Connect SDK to Workspace"? What was the content of your workspace before the command and what is the content of the current workspace (after you run the command)?

    You could use File -> Add Folder to Workspace to add your NCS folder to workspace..

    Best regards,
    Dejan


Reply
  • Hi,

    You can find more information about VS Code workspaces here.

    Have you installed C/C++ extension?

    Could you provide more information on how you invoked the command "Add nRF Connect SDK to Workspace"? What was the content of your workspace before the command and what is the content of the current workspace (after you run the command)?

    You could use File -> Add Folder to Workspace to add your NCS folder to workspace..

    Best regards,
    Dejan


Children
Related