Cannot open source file "sdkconfig.h" (dependency of "stdio.h")

I have created an espidf project in Platformio running Visual Studio code.
I have taken the hello_world example from the esp-idf example files.

I am getting the error that stdio.h file cannot be found. I can compile, run and debug the hello_world app just fine.

I have searched the esp-idf folders and can find the stdio.h file but not the stdio.c file.

I have searched the Library Manager for stdio library, but cannot find it.

In order to address the “cannot open source file” error how can I include the stdio library into the platformio lib folder? Since the program compiles and runs it is somewhere in the esp-idf toolchain. I would like to fix this issue so I do not get the stdio.h error.

Thanks

Joe

After working on this problem, this morning, I found a solution. This works for Windows 11, using Visual Studio Code and the Platformio extension. I used the hello_world example as a test.

Create the example project from the EP-IDF examples. from the Expressif extension in Visual Studio Code.

Rename the main folder to src, this is the folder that contains your hello_world_main.c file.

Add a platformio.ini file to your project.

Select the Gear icon and select the Setting link.
Search for “C_Cpp.default.includePath

Add the path to your esp-idf components folder :i.e

C:\Users<user name>\esp\v5.2.1\esp-idf\components
(or wherever you installed your esp-idf)

Save the project and restart Visual Studio Code.

Your #include issues are now resolved.

You can build, upload, run and even debug the esp-idf project using either a built in jtag debugger or a esp-prog jtag debugger.

Great! Anyway this works for me (as long as it takes).