Reputation: 71
I'm using visual studio code version(1.59.1) for ESP-IDF version (4.3).I have added in c_cpp_properties.json
file all paths in includepath
but I still have the same all error gone except this one:
(can't open source file "sys/reent.h" (dependency of freertos/FreeRTOS.h)).
In visual studio terminal it gives me error when I try to use (idf.py
command)
'idf.py' is not recognized as an internal or external command, and sometimes it give me python can't open the file where the script exist.
Upvotes: 4
Views: 3163
Reputation: 126
I follow this solution by modifying c_cpp_properties.json.
My version:
{
"configurations": [
{
"name": "Win32",
"includePath": [
"${workspaceFolder}/**",
"${config:idf.espIdfPath}/components/**",
"${config:idf.espIdfPathWin}/components/**"
],
"browse": {
"path": [
"${config:idf.espIdfPath}/components",
"${config:idf.espIdfPathWin}/components",
"${workspaceFolder}"
],
"limitSymbolsToIncludedHeaders": false
},
"defines": [
"_DEBUG",
"UNICODE",
"_UNICODE"
],
"windowsSdkVersion": "10.0.20348.0",
"cStandard": "c17",
"cppStandard": "c++17",
"compilerPath": "${config:idf.toolsPath}/tools/xtensa-esp32-elf/esp-2022r1-11.2.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc",
"compileCommands": "${workspaceFolder}/build/compile_commands.json",
}
],
"version": 4
}
Upvotes: 0
Reputation: 11
First open esp-idf terminal then execute "idf.py build" or other idf commands. Once build success "sys/reent.h" error will gone
Upvotes: 1