I tried to install ESP-IDF and its tools with the Visual Studio Code extension but I got errors because there are spaces in my user name in Windows (I'm using Windows 10).
So I used the online installer version 2.16; it installed all the components in C:\Espressif
. I set the system variable IDF_PATH
to this location.
I open Visual Studio Code and the USE EXISTING SETUP option is available; it says: "We have found ESP-IDF version: 4.4.2 @C:/Espressif/frameworks/esp-idf-v4.4.2/ and ESP-IDF tools in @ C:\Espressif. Click here to use them."
It puts a check mark in:
- Installing IDF Prerequisites...
- Installing ESP-IDF...
- Installing ESP-IDF Tools...
But it fails in Installing Python virtual environment for ESP-IDF...
The output window shows this:
idf_versions.txt has (1) KB
idf_versions.txt progress: 100.00% (0.10 / 0.10) KB
Installing ESP-IDF extension python packages in C:/Espressif/python_env/idf4.4_py3.8_env/Scripts/python.exe ...
ERROR: Could not open requirements file: [Errno 2] No such file or directory: 'c:\\Users\\Axel'
Command failed: "C:/Espressif/python_env/idf4.4_py3.8_env/Scripts/python.exe" -m pip install --upgrade --constraint c:\Users\Axel Bryan\.vscode\extensions\espressif.esp-idf-extension-1.5.0\espidf.constraints.txt --no-warn-script-location -r "c:\Users\Axel Bryan\.vscode\extensions\espressif.esp-idf-extension-1.5.0\requirements.txt"
ERROR: Could not open requirements file: [Errno 2] No such file or directory: 'c:\\Users\\Axel'
I tried tinkering with IDF_PATH
and IDF_TOOLS_PATH
, but it seems that at least one of them should be set to C:\Espressif
to make the USE EXISTING SETUP option appear in VSCode.