Arduino IDE 2.1.1 ESP32 Compilation error: No connection established

Hello everyone,

I am using Arduino IDE 2.1.1 and ESP32 wroom 32d (Devkit_V4). When I verify my code for arduino uno it works but when i select ESP32 Dev Module it gives me this error: No connection established Compilation error: No connection established. The code i am using is just basic lighting up a rgb diode but even blank sketch wont work.

Have a great day,
DG_tao

Have you selected the correct COM port as well as the board ?

I am pretty sure that i have but i opened the ide to check if i have and the ide wont load its stuck.

In what way is it stuck ?

It wont load. I can see the arduino icon in the center just geting bigger and smaller aka loading

Well, I restarted my pc and for some reason it just started working. Thanks for the help tough. I can verify and upload now. In my opinion the problem is the esp32 board manager and the ide being a bit buggy. So if you have the same problem try restarting your pc, removing the esp32 board manager and installing it again or try reinstalling the ide.

nvm, i removed the esp from the cable and plugged it in again and now it wont detect it(it wont show on ports). I can see it in device manager tough.

it wont detect the uno now eather

i have no idea waht is happening i reinstalled esp32 board manager and then restarted my pc now everything works, but idk if it will occur again.

I quit. Just 5 sec later and it stopped working again.

Hi @dg_tao. I'm sorry you're having trouble with Arduino IDE. If you decide to give it another try eventually, we can take a look at the debug logs Arduino IDE generates to see if the information there indicates what is wrong.

I can provide instructions for obtaining the logs. I only need to know which operating system (e.g., "Windows") you are using.

I am on windows, but i uninstalled ide 2.1.1 and installed it from the microsoft store (ide 1.8.19). Unfortunately that didnt solve my problem. The error i get now is: Arduino: 1.8.19 (Windows Store 1.8.57.0) (Windows 10), Board: "ESP32 Dev Module, Disabled, Disabled, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi/BT), QIO, 80MHz, 4MB (32Mb), 921600, Core 1, Core 1, None, Disabled"

exit status -1073741502

Error compiling for board ESP32 Dev Module.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

OK, the fact that there is also a problem when using Arduino IDE 1.8.19 is interesting information.

I'm going to ask you to post the full verbose output from a compilation.


:exclamation: This procedure is not intended to solve the problem. The purpose is to gather more information.


Please do this:

  1. Select File > Preferences... from the Arduino IDE menus.
    The "Preferences" dialog will open.
  2. Check the box next to "Show verbose output during: ☐ compilation" in the "Preferences" dialog.
  3. Click the OK button.
  4. Select Sketch > Verify/Compile from the Arduino IDE menus.
  5. After the compilation fails you'll see a button on the right side of the orange bar in Arduino IDE: Copy error messages. Click that button.
    This copies the full output to the clipboard.
  6. Open a forum reply here by clicking the Reply button.
  7. Click the <CODE/> icon on the post composer toolbar.
    This will add the forum's code block markup (```) to your reply to make sure the error messages are correctly formatted.
    Code tags icon on toolbar
  8. Press Ctrl+V.
    This will paste the compilation output into the code block.
  9. Move the cursor outside of the code tags before you add any additional text to your reply.
  10. Click the Reply button to post the output.

In case the output is longer than the forum software will allow to be added to a post, you can instead save it to a .txt file and then attach that file to a reply here:

  1. Open any text editor program.
  2. Paste the copied output into the text editor.
  3. Save the file in .txt format.
  4. Open a forum reply here by clicking the Reply button.
  5. Click the "Upload" icon (image) on the post composer toolbar:
    Upload icon on toolbar
    A dialog will open.
  6. In the dialog, select the .txt file you saved.
  7. Click the Open button.
  8. Click the Reply button to publish the post.

Alternatively, instead of using the "Upload" icon on the post composer toolbar as described in steps (5) - (7) above, you can simply drag and drop the .txt file onto the post composer field to attach it.

Ok, here:
text.txt (626.6 KB)

In order to make the information more readily available to the forum helpers, I'll post an extract of the relevant output from @dg_tao's text.txt file here:

Arduino: 1.8.19 (Windows Store 1.8.57.0) (Windows 10), Board: "ESP32 Dev Module, Disabled, Disabled, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi/BT), QIO, 80MHz, 4MB (32Mb), 921600, Core 1, Core 1, None, Disabled"

[...]

"C:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\tools\\xtensa-esp32-elf-gcc\\esp-2021r2-patch5-8.4.0/bin/xtensa-esp32-elf-g++" -DHAVE_CONFIG_H "-DMBEDTLS_CONFIG_FILE=\"mbedtls/esp_config.h\"" -DUNITY_INCLUDE_CONFIG_H -DWITH_POSIX -D_GNU_SOURCE "-DIDF_VER=\"v4.4.5\"" -DESP_PLATFORM -D_POSIX_READER_WRITER_LOCKS "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/newlib/platform_include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/freertos/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/freertos/include/esp_additions/freertos" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/freertos/port/xtensa/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/freertos/include/esp_additions" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_hw_support/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_hw_support/include/soc" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_hw_support/include/soc/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_hw_support/port/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_hw_support/port/esp32/private_include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/heap/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/log/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/lwip/include/apps" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/lwip/include/apps/sntp" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/lwip/lwip/src/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/lwip/port/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/lwip/port/esp32/include/arch" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/soc/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/soc/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/soc/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/hal/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/hal/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/hal/platform_port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_rom/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_rom/include/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_rom/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_common/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_system/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_system/port/soc" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_system/port/public_compat" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/xtensa/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/xtensa/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/driver/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/driver/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_pm/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_ringbuf/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/efuse/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/efuse/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/vfs/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_wifi/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_event/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_netif/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_eth/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/tcpip_adapter/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_phy/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_phy/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_ipc/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/app_trace/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_timer/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/mbedtls/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/mbedtls/mbedtls/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/mbedtls/esp_crt_bundle/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/app_update/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/spi_flash/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bootloader_support/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/nvs_flash/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/pthread/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_gdbstub/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_gdbstub/xtensa" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_gdbstub/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espcoredump/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espcoredump/include/port/xtensa" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/wpa_supplicant/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/wpa_supplicant/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/wpa_supplicant/esp_supplicant/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/ieee802154/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/console" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/asio/asio/asio/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/asio/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/common/osi/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/include/esp32/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/common/api/include/api" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/common/btc/profile/esp/blufi/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/common/btc/profile/esp/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/host/bluedroid/api/include/api" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_common/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_common/tinycrypt/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_core" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_core/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_core/storage" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/btc/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_models/common/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_models/client/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_models/server/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/api/core/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/api/models/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/bt/esp_ble_mesh/api" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/cbor/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/unity/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/unity/unity/src" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/cmock/CMock/src" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/coap/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/coap/libcoap/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/nghttp/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/nghttp/nghttp2/lib/includes" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-tls" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-tls/esp-tls-crypto" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_adc_cal/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_hid/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/tcp_transport/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_http_client/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_http_server/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_https_ota/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_https_server/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_lcd/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_lcd/interface" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/protobuf-c/protobuf-c" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/protocomm/include/common" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/protocomm/include/security" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/protocomm/include/transports" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/mdns/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_local_ctrl/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/sdmmc/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_serial_slave_link/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_websocket_client/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/expat/expat/expat/lib" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/expat/port/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/wear_levelling/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/fatfs/diskio" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/fatfs/vfs" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/fatfs/src" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/freemodbus/freemodbus/common/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/idf_test/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/idf_test/include/esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/jsmn/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/json/cJSON" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/libsodium/libsodium/src/libsodium/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/libsodium/port_include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/mqtt/esp-mqtt/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/openssl/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/perfmon/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/spiffs/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/ulp/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/wifi_provisioning/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/rmaker_common/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_diagnostics/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/rtc_store/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_insights/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/json_parser/upstream/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/json_parser/upstream" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/json_generator/upstream" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_schedule/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp_secure_cert_mgr/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_rainmaker/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/gpio_button/button/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/qrcode/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/ws2812_led" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp_littlefs/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/tool" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/typedef" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/image" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/math" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/nn" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/layer" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/detect" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp-dl/include/model_zoo" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp32-camera/driver/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/esp32-camera/conversions/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/dotprod/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/support/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/support/mem/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/hann/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/blackman/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/blackman_harris/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/blackman_nuttall/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/nuttall/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/flat_top/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/iir/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/fir/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/add/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/sub/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/mul/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/addc/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/mulc/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/sqrt/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/matrix/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/fft/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/dct/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/conv/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/common/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/kalman/ekf/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/espressif__esp-dsp/modules/kalman/ekf_imu13states/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/include/fb_gfx/include" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11/tools/sdk/esp32/qio_qspi/include" -mlongcalls -Wno-frame-address -ffunction-sections -fdata-sections -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=deprecated-declarations -Wno-unused-parameter -Wno-sign-compare -ggdb -freorder-blocks -Wwrite-strings -fstack-protector -fstrict-volatile-bitfields -Wno-error=unused-but-set-variable -fno-jump-tables -fno-tree-switch-conversion -std=gnu++11 -fexceptions -fno-rtti -MMD -c -w -Os -DF_CPU=240000000L -DARDUINO=10819 -DARDUINO_ESP32_DEV -DARDUINO_ARCH_ESP32 "-DARDUINO_BOARD=\"ESP32_DEV\"" "-DARDUINO_VARIANT=\"esp32\"" -DARDUINO_PARTITION_default -DESP32 -DCORE_DEBUG_LEVEL=0 -DARDUINO_RUNNING_CORE=1 -DARDUINO_EVENT_RUNNING_CORE=1 -DARDUINO_USB_CDC_ON_BOOT=0 "@C:\\Users\\danch\\AppData\\Local\\Temp\\arduino_build_39168/build_opt.h" "@C:\\Users\\danch\\AppData\\Local\\Temp\\arduino_build_39168/file_opts" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11\\cores\\esp32" "-IC:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11\\variants\\esp32" "C:\\Users\\danch\\Documents\\ArduinoData\\packages\\esp32\\hardware\\esp32\\2.0.11\\cores\\esp32\\main.cpp" -o "C:\\Users\\danch\\AppData\\Local\\Temp\\arduino_build_39168\\core\\main.cpp.o"

exit status -1073741502

This exit status -1073741502 is a Windows system error code. I used the "Microsoft Error Lookup Tool" to get some more information about it:

PS C:\> Err_6.4.5.exe -1073741502
# for decimal -1073741502 / hex 0xc0000142
  STATUS_DLL_INIT_FAILED                                         ntstatus.h   
# {DLL Initialization Failed}
# Initialization of the dynamic link library %hs failed. The
# process is terminating abnormally.
# as an HRESULT: Severity: FAILURE (1), FACILITY_NULL (0x0), Code 0x142
# for decimal 322 / hex 0x142
  ERROR_DEVICE_NO_RESOURCES                                      winerror.h   
# The target device has insufficient resources to complete
# the operation.
# 2 matches found for "-1073741502"

Unfortunately that information doesn't give me any lead to a solution.

It seems this is occurring when the compilation process attempts to invoke the xtensa-esp32-elf-g++ tool from the ESP32 toolchain. It could be interesting to see if you can reproduce the same problem even when invoking the tool directly. Please try this:

  1. Click the Windows "Start" button.
  2. Type powershell in the search field.
  3. Select "Windows PowerShell ISE" from the search results.
    A "Windows PowerShell ISE" window will open.
  4. Click on the terminal panel of the "Windows PowerShell ISE" window.
    The terminal panel is the part that has the command prompt like PS C:\Users\per>
  5. Type the following command:
    C:\Users\danch\Documents\ArduinoData\packages\esp32\tools\xtensa-esp32-elf-gcc\esp-2021r2-patch5-8.4.0/bin/xtensa-esp32-elf-g++ --help
    
  6. Press the Enter key.

When things are working correctly, we expect this to cause the command line help for the tool to be printed in the PowerShell terminal:

PS C:\> C:\Users\danch\Documents\ArduinoData\packages\esp32\tools\xtensa-esp32-elf-gcc\esp-2021r2-patch5-8.4.0/bin/xtensa-esp32-elf-g++ --help
Usage: xtensa-esp32-elf-g++.exe [options] file...
Options:
  -pass-exit-codes         Exit with highest error code from a phase.
  --help                   Display this information.
  --target-help            Display target specific command line options.
  --help={common|optimizers|params|target|warnings|[^]{joined|separate|undocumented}}[,...].
                           Display specific types of command line options.
  (Use '-v --help' to display command line options of sub-processes).
  --version                Display compiler version information.
  -dumpspecs               Display all of the built in spec strings.
  -dumpversion             Display the version of the compiler.
  -dumpmachine             Display the compiler's target processor.
  -print-search-dirs       Display the directories in the compiler's search path.
  -print-libgcc-file-name  Display the name of the compiler's companion library.
  -print-file-name=<lib>   Display the full path to library <lib>.
  -print-prog-name=<prog>  Display the full path to compiler component <prog>.
  -print-multiarch         Display the target's normalized GNU triplet, used as
                           a component in the library path.
  -print-multi-directory   Display the root directory for versions of libgcc.
  -print-multi-lib         Display the mapping between command line options and
                           multiple library search directories.
  -print-multi-os-directory Display the relative path to OS libraries.
  -print-sysroot           Display the target libraries directory.
  -print-sysroot-headers-suffix Display the sysroot suffix used to find headers.
  -Wa,<options>            Pass comma-separated <options> on to the assembler.
  -Wp,<options>            Pass comma-separated <options> on to the preprocessor.
  -Wl,<options>            Pass comma-separated <options> on to the linker.
  -Xassembler <arg>        Pass <arg> on to the assembler.
  -Xpreprocessor <arg>     Pass <arg> on to the preprocessor.
  -Xlinker <arg>           Pass <arg> on to the linker.
  -save-temps              Do not delete intermediate files.
  -save-temps=<arg>        Do not delete intermediate files.
  -no-canonical-prefixes   Do not canonicalize paths when building relative
                           prefixes to other gcc components.
  -pipe                    Use pipes rather than intermediate files.
  -time                    Time the execution of each subprocess.
  -specs=<file>            Override built-in specs with the contents of <file>.
  -std=<standard>          Assume that the input sources are for <standard>.
  --sysroot=<directory>    Use <directory> as the root directory for headers
                           and libraries.
  -B <directory>           Add <directory> to the compiler's search paths.
  -v                       Display the programs invoked by the compiler.
  -###                     Like -v but options quoted and commands not executed.
  -E                       Preprocess only; do not compile, assemble or link.
  -S                       Compile only; do not assemble or link.
  -c                       Compile and assemble, but do not link.
  -o <file>                Place the output into <file>.
  -pie                     Create a dynamically linked position independent
                           executable.
  -shared                  Create a shared library.
  -x <language>            Specify the language of the following input files.
                           Permissible languages include: c c++ assembler none
                           'none' means revert to the default behavior of
                           guessing the language based on the file's extension.

Options starting with -g, -f, -m, -O, -W, or --param are automatically
 passed on to the various sub-processes invoked by xtensa-esp32-elf-g++.exe.  In order to pass
 other options on to these processes the -W<letter> options must be used.

For bug reporting instructions, please see:
<https://gcc.gnu.org/bugs/>.
PS E:\stuff\todo> C:\Users\per\AppData\Local\Arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\esp-2021r2-patch5-8.4.0\bin\xtensa-esp32-elf-g++ --help
Usage: xtensa-esp32-elf-g++.exe [options] file...
Options:
  -pass-exit-codes         Exit with highest error code from a phase.
  --help                   Display this information.
  --target-help            Display target specific command line options.
  --help={common|optimizers|params|target|warnings|[^]{joined|separate|undocumented}}[,...].
                           Display specific types of command line options.
  (Use '-v --help' to display command line options of sub-processes).
  --version                Display compiler version information.
  -dumpspecs               Display all of the built in spec strings.
  -dumpversion             Display the version of the compiler.
  -dumpmachine             Display the compiler's target processor.
  -print-search-dirs       Display the directories in the compiler's search path.
  -print-libgcc-file-name  Display the name of the compiler's companion library.
  -print-file-name=<lib>   Display the full path to library <lib>.
  -print-prog-name=<prog>  Display the full path to compiler component <prog>.
  -print-multiarch         Display the target's normalized GNU triplet, used as
                           a component in the library path.
  -print-multi-directory   Display the root directory for versions of libgcc.
  -print-multi-lib         Display the mapping between command line options and
                           multiple library search directories.
  -print-multi-os-directory Display the relative path to OS libraries.
  -print-sysroot           Display the target libraries directory.
  -print-sysroot-headers-suffix Display the sysroot suffix used to find headers.
  -Wa,<options>            Pass comma-separated <options> on to the assembler.
  -Wp,<options>            Pass comma-separated <options> on to the preprocessor.
  -Wl,<options>            Pass comma-separated <options> on to the linker.
  -Xassembler <arg>        Pass <arg> on to the assembler.
  -Xpreprocessor <arg>     Pass <arg> on to the preprocessor.
  -Xlinker <arg>           Pass <arg> on to the linker.
  -save-temps              Do not delete intermediate files.
  -save-temps=<arg>        Do not delete intermediate files.
  -no-canonical-prefixes   Do not canonicalize paths when building relative
                           prefixes to other gcc components.
  -pipe                    Use pipes rather than intermediate files.
  -time                    Time the execution of each subprocess.
  -specs=<file>            Override built-in specs with the contents of <file>.
  -std=<standard>          Assume that the input sources are for <standard>.
  --sysroot=<directory>    Use <directory> as the root directory for headers
                           and libraries.
  -B <directory>           Add <directory> to the compiler's search paths.
  -v                       Display the programs invoked by the compiler.
  -###                     Like -v but options quoted and commands not executed.
  -E                       Preprocess only; do not compile, assemble or link.
  -S                       Compile only; do not assemble or link.
  -c                       Compile and assemble, but do not link.
  -o <file>                Place the output into <file>.
  -pie                     Create a dynamically linked position independent
                           executable.
  -shared                  Create a shared library.
  -x <language>            Specify the language of the following input files.
                           Permissible languages include: c c++ assembler none
                           'none' means revert to the default behavior of
                           guessing the language based on the file's extension.

Options starting with -g, -f, -m, -O, -W, or --param are automatically
 passed on to the various sub-processes invoked by xtensa-esp32-elf-g++.exe.  In order to pass
 other options on to these processes the -W<letter> options must be used.

For bug reporting instructions, please see:
<https://gcc.gnu.org/bugs/>.
PS C:\> 

Do you see that expected output when you perform the instructions I provided, or something else? If something else, please post the full output from the PowerShell terminal or any dialogs that might have appeared.

I did it and I think its the same thing:

PS C:\Users\danch> C:\Users\danch\Documents\ArduinoData\packages\esp32\tools\xtensa-esp32-elf-gcc\esp-2021r2-patch5-8.4.0/bin/xtensa-esp32-elf-g++ --help
Usage: xtensa-esp32-elf-g++.exe [options] file...
Options:
  -pass-exit-codes         Exit with highest error code from a phase.
  --help                   Display this information.
  --target-help            Display target specific command line options.
  --help={common|optimizers|params|target|warnings|[^]{joined|separate|undocumented}}[,...].
                           Display specific types of command line options.
  (Use '-v --help' to display command line options of sub-processes).
  --version                Display compiler version information.
  -dumpspecs               Display all of the built in spec strings.
  -dumpversion             Display the version of the compiler.
  -dumpmachine             Display the compiler's target processor.
  -print-search-dirs       Display the directories in the compiler's search path.
  -print-libgcc-file-name  Display the name of the compiler's companion library.
  -print-file-name=<lib>   Display the full path to library <lib>.
  -print-prog-name=<prog>  Display the full path to compiler component <prog>.
  -print-multiarch         Display the target's normalized GNU triplet, used as
                           a component in the library path.
  -print-multi-directory   Display the root directory for versions of libgcc.
  -print-multi-lib         Display the mapping between command line options and
                           multiple library search directories.
  -print-multi-os-directory Display the relative path to OS libraries.
  -print-sysroot           Display the target libraries directory.
  -print-sysroot-headers-suffix Display the sysroot suffix used to find headers.
  -Wa,<options>            Pass comma-separated <options> on to the assembler.
  -Wp,<options>            Pass comma-separated <options> on to the preprocessor.
  -Wl,<options>            Pass comma-separated <options> on to the linker.
  -Xassembler <arg>        Pass <arg> on to the assembler.
  -Xpreprocessor <arg>     Pass <arg> on to the preprocessor.
  -Xlinker <arg>           Pass <arg> on to the linker.
  -save-temps              Do not delete intermediate files.
  -save-temps=<arg>        Do not delete intermediate files.
  -no-canonical-prefixes   Do not canonicalize paths when building relative
                           prefixes to other gcc components.
  -pipe                    Use pipes rather than intermediate files.
  -time                    Time the execution of each subprocess.
  -specs=<file>            Override built-in specs with the contents of <file>.
  -std=<standard>          Assume that the input sources are for <standard>.
  --sysroot=<directory>    Use <directory> as the root directory for headers
                           and libraries.
  -B <directory>           Add <directory> to the compiler's search paths.
  -v                       Display the programs invoked by the compiler.
  -###                     Like -v but options quoted and commands not executed.
  -E                       Preprocess only; do not compile, assemble or link.
  -S                       Compile only; do not assemble or link.
  -c                       Compile and assemble, but do not link.
  -o <file>                Place the output into <file>.
  -pie                     Create a dynamically linked position independent
                           executable.
  -shared                  Create a shared library.
  -x <language>            Specify the language of the following input files.
                           Permissible languages include: c c++ assembler none
                           'none' means revert to the default behavior of
                           guessing the language based on the file's extension.

Options starting with -g, -f, -m, -O, -W, or --param are automatically
 passed on to the various sub-processes invoked by xtensa-esp32-elf-g++.exe.  In order to pass
 other options on to these processes the -W<letter> options must be used.

For bug reporting instructions, please see:
<https://gcc.gnu.org/bugs/>.

The exit status message follows the xtensa-esp32-elf-g++ in the output, which leads me to believe it came from that tool. However, it is also possible it is coming from a tool named arduino-builder that orchestrates the compilation. So we can try the same procedure for that tool. Please try this:

  1. Click the Windows "Start" button.
  2. Type powershell in the search field.
  3. Select "Windows PowerShell ISE" from the search results.
    A "Windows PowerShell ISE" window will open.
  4. Click on the terminal panel of the "Windows PowerShell ISE" window.
    The terminal panel is the part that has the command prompt like PS C:\Users\per>
  5. Type the following command:
    & "C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.57.0_x86__mdqgnx93n4wtt\arduino-builder"
    
  6. Press the Enter key.

When things are working correctly, we expect this to cause the command line help for the tool to be printed in the PowerShell terminal:

PS C:\> & "C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.57.0_x86__mdqgnx93n4wtt\arduino-builder"
Parameter 'hardware' is mandatory
Usage of C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.57.0_x86__mdqgnx93n4wtt\arduino-builder:
  -build-cache string
        builds of 'core.a' are saved into this folder to be cached and reused
  -build-options-file string
        Instead of specifying --hardware, --tools etc every time, you can load all such options from a file
  -build-path string
        build path
  -built-in-libraries value
        Specify a built-in 'libraries' folder. These are low priority libraries. Can be added multiple times for specifying multiple built-in 'libraries' folders
  -code-complete-at string
        output code completions for sketch at a specific location. Location format is "file:line:col"
  -compile
        compiles the given sketch
  -core-api-version string
        version of core APIs (used to populate ARDUINO #define) (default "10600")
  -daemon
        daemonizes and serves its functions via rpc
  -debug-level int
        Turns on debugging messages. The higher, the chattier (default 5)
  -dump-prefs
        dumps build properties used when compiling
  -experimental
        enables experimental features
  -fqbn string
        fully qualified board name
  -hardware value
        Specify a 'hardware' folder. Can be added multiple times for specifying multiple 'hardware' folders
  -ide-version string
        [deprecated] use 'core-api-version' instead (default "10600")
  -jobs int
        specify how many concurrent gcc processes should run at the same time. Defaults to the number of available cores on the running machine
  -libraries value
        Specify a 'libraries' folder. Can be added multiple times for specifying multiple 'libraries' folders
  -logger string
        Sets type of logger. Available values are 'human', 'humantags', 'machine' (default "human")
  -prefs value
        Specify a custom preference. Can be added multiple times for specifying multiple custom preferences
  -preprocess
        preprocess the given sketch
  -quiet
        if 'true' doesn't print any warnings or progress or whatever
  -tools value
        Specify a 'tools' folder. Can be added multiple times for specifying multiple 'tools' folders
  -trace
        traces the whole process lifecycle
  -verbose
        if 'true' prints lots of stuff
  -version
        prints version and exits
  -vid-pid string
        specify to use vid/pid specific build properties, as defined in boards.txt
  -warnings string
        Sets warnings level. Available values are 'none', 'default', 'more' and 'all'
PS C:\> 

Do you see that expected output when you perform the instructions I provided, or something else? If something else, please post the full output from the PowerShell terminal or any dialogs that might have appeared.

Well that doesn`t seem right:

Program 'arduino-builder.exe' failed to run: Access is deniedAt line:1 char:1
+ & "C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.57.0_x86__m ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~.
At line:1 char:1
+ & "C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.57.0_x86__m ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ResourceUnavailable: (:) [], ApplicationFailedException
    + FullyQualifiedErrorId : NativeCommandFailed
 

"...failed to run: Access is denied", maybe firewall?

It is possible this result is normal when using the Microsoft Store package of Arduino IDE as you are. I tested the equivalent arduino-builder command on my own computer, but I only have the regular package of Arduino IDE 1.8.19 installed so the environment on my computer is significantly different from the environment on your computer.

I don't have much experience with the Microsoft Store package of Arduino IDE but I do know that Windows places very strict security restrictions on these apps when compared to applications installed normally. The error message you encountered might be a normal consequence of those security restrictions.

You might try it again with the Arduino IDE package you get by clicking the "Windows ZIP file" download link (instead of the "Windows app" link) here:

https://www.arduino.cc/en/software#legacy-ide-18x