Debug adapter crash
Posted: Mon Jan 02, 2023 8:09 am
Hi,
I'm trying to get a Windows VSC environment working using the built-in JTAG on an esp32c3. So far I've managed to get an example downloading and executing ('restful_server'), but can't get debugging to work. The build and flash steps using Open OCD are working OK, so basic connectivity to the chip is working OK.
Here's some of the debug logs:
debug.log
------------------------------------
2023-01-02 18:37:25,487 - Debug Adapter (main) - DEBUG - START_TIME_2023_01_02_18-37-25
2023-01-02 18:37:25,487 - Debug Adapter (main) - DEBUG - Init errors:None
2023-01-02 18:37:25,487 - Debug Adapter (main) - INFO - Working directory: C:\Users\david\AppData\Local\Programs\Microsoft VS Code
2023-01-02 18:37:25,488 - Debug Adapter (main) - INFO - Arguments:
{ 'app_flash_off': 65536,
'board_type': None,
'cmdfile': 'c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\esp-idf-vscode-generated.gdb',
'core_file': (),
'debug': 4,
'developer_mode': 'none',
'device_name': 'esp32c3',
'elfpath': ( 'c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\build\\restful_server.elf',),
'log_file': 'c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\debug.log',
'log_mult_files': None,
'log_no_debug_console': None,
'oocd': 'openocd',
'oocd_args': None,
'oocd_ip': 'localhost',
'oocd_mode': 'connect_to_instance',
'oocd_scripts': None,
'port': 43474,
'postmortem': False,
'tmo_scale_factor': 5,
'toolchain_prefix': 'riscv32-esp-elf-'}
2023-01-02 18:37:25,488 - Debug Adapter (main) - CRITICAL - Debug adapter -> Extension: DEBUG_ADAPTER_STARTED
2023-01-02 18:37:25,488 - Debug Adapter (main) - INFO - Starting. Cmd: c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter_main.py -d 4 -e c:\Users\david\OneDrive\Documents\ESP32\restful_server\build\restful_server.elf -l c:\Users\david\OneDrive\Documents\ESP32\restful_server\debug.log -p 43474 -dn esp32c3 -a 0x10000 -t riscv32-esp-elf- -x c:\Users\david\OneDrive\Documents\ESP32\restful_server\esp-idf-vscode-generated.gdb -tsf 5
2023-01-02 18:37:25,493 - Debug Adapter (main) - INFO - Listening on port 43474
2023-01-02 18:37:25,494 - Debug Adapter (main) - CRITICAL - Debug adapter -> Extension: DEBUG_ADAPTER_READY2CONNECT
2023-01-02 18:37:25,498 - Debug Adapter (main) - DEBUG - Got connection
2023-01-02 18:37:25,499 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Debug adapter -> Extension: DEBUG_ADAPTER_STARTED\n", "source": {}}, "seq": 0}
2023-01-02 18:37:25,500 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Starting. Cmd: c:\\Users\\david\\.vscode\\extensions\\espressif.esp-idf-extension-1.5.1\\esp_debug_adapter\\debug_adapter_main.py -d 4 -e c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\build\\restful_server.elf -l c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\debug.log -p 43474 -dn esp32c3 -a 0x10000 -t riscv32-esp-elf- -x c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\esp-idf-vscode-generated.gdb -tsf 5\n\n", "source": {}}, "seq": 1}
2023-01-02 18:37:25,500 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Listening on port 43474\n", "source": {}}, "seq": 2}
2023-01-02 18:37:25,500 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Debug adapter -> Extension: DEBUG_ADAPTER_READY2CONNECT\n", "source": {}}, "seq": 3}
2023-01-02 18:37:25,501 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Got connection\n", "source": {}}, "seq": 4}
2023-01-02 18:37:25,515 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'Content-Length: 480\\r\\n'<<
2023-01-02 18:37:25,515 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'\\r\\n'<<
2023-01-02 18:37:25,516 - Debug Adapter(Command Processor) - DEBUG - Got json: {
"arguments": {
"adapterID": "espidf",
"clientID": "vscode",
"clientName": "Visual Studio Code",
"columnsStartAt1": true,
"linesStartAt1": true,
"locale": "en-us",
"pathFormat": "path",
"supportsArgsCanBeInterpretedByShell": true,
"supportsInvalidatedEvent": true,
"supportsMemoryEvent": true,
"supportsMemoryReferences": true,
"supportsProgressReporting": true,
"supportsRunInTerminalRequest": true,
"supportsVariablePaging": true,
"supportsVariableType": true
},
"command": "initialize",
"seq": 1,
"type": "request"
}
2023-01-02 18:37:25,516 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Got json: {\n \"arguments\": {\n \"adapterID\": \"espidf\",\n \"clientID\": \"vscode\",\n \"clientName\": \"Visual Studio Code\",\n \"columnsStartAt1\": true,\n \"linesStartAt1\": true,\n \"locale\": \"en-us\",\n \"pathFormat\": \"path\",\n \"supportsArgsCanBeInterpretedByShell\": true,\n \"supportsInvalidatedEvent\": true,\n \"supportsMemoryEvent\": true,\n \"supportsMemoryReferences\": true,\n \"supportsProgressReporting\": true,\n \"supportsRunInTerminalRequest\": true,\n \"supportsVariablePaging\": true,\n \"supportsVariableType\": true\n },\n \"command\": \"initialize\",\n \"seq\": 1,\n \"type\": \"request\"\n}\n", "source": {}}, "seq": 5}
2023-01-02 18:37:25,523 - Gdb - DEBUG - MI->: -gdb-set mi-async on
2023-01-02 18:37:26,701 - Gdb - DEBUG - MI<-:
[{'message': 'thread-group-added',
'payload': {'id': 'i1'},
'stream': 'stdout',
'token': None,
'type': 'notify'},
{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,701 - Gdb - INFO - NOTIFY: thread-group-added {'id': 'i1'}
2023-01-02 18:37:26,701 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,701 - Gdb - DEBUG - MI->: -gdb-set logging file C:\Users\david\AppData\Local\Temp\gdb_proc.log
2023-01-02 18:37:26,712 - Gdb - DEBUG - MI<-:
[{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,712 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,712 - Gdb - DEBUG - MI->: -gdb-set logging on
2023-01-02 18:37:26,722 - Gdb - DEBUG - MI<-:
[{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,722 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,722 - Gdb - DEBUG - MI->: -gdb-set arch riscv:rv32
2023-01-02 18:37:26,733 - Gdb - DEBUG - MI<-:
[{'message': None,
'payload': 'The target architecture is set to \\"riscv:rv32\\".\\n',
'stream': 'stdout',
'type': 'console'},
{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,733 - Gdb - INFO - CONS: 'The target architecture is set to \\"riscv:rv32\\".\\n'
2023-01-02 18:37:26,733 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,733 - Debug Adapter (main) - DEBUG - Created gdb object of type: GdbEsp32c3
2023-01-02 18:37:26,733 - Gdb - DEBUG - MI->: -file-exec-and-symbols c:/Users/david/OneDrive/Documents/ESP32/restful_server/build/restful_server.elf
2023-01-02 18:37:26,733 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Created gdb object of type: GdbEsp32c3\n", "source": {}}, "seq": 6}
2023-01-02 18:37:32,304 - Gdb - DEBUG - MI<-:
[{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:32,304 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:32,304 - Gdb - DEBUG - Connecting to 127.0.0.1:3333
2023-01-02 18:37:32,304 - Gdb - DEBUG - MI->: -target-select remote 127.0.0.1:3333
2023-01-02 18:38:22,304 - Gdb - DEBUG - MI<-:
[{'message': None,
'payload': 'Ignoring packet error, continuing...\\n',
'stream': 'stdout',
'type': 'console'},
{'message': None,
'payload': 'warning: unrecognized item \\"timeout\\" in \\"qSupported\\" '
'response\\n',
'stream': 'stdout',
'type': 'log'},
{'message': 'error',
'payload': {'msg': "Remote replied unexpectedly to 'vMustReplyEmpty': "
'PacketSize=4000;qXfer:memory-map:read+;qXfer:features:read+;qXfer:threads:read+;QStartNoAckMode+;vContSupported+'},
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:38:22,304 - Gdb - INFO - CONS: 'Ignoring packet error, continuing...\\n'
2023-01-02 18:38:22,304 - Gdb - DEBUG - LOG: 'warning: unrecognized item \\"timeout\\" in \\"qSupported\\" response\\n'
2023-01-02 18:38:22,305 - Gdb - DEBUG - RESULT: error {'msg': "Remote replied unexpectedly to 'vMustReplyEmpty': "
'PacketSize=4000;qXfer:memory-map:read+;qXfer:features:read+;qXfer:threads:read+;QStartNoAckMode+;vContSupported+'}
2023-01-02 18:38:22,305 - Debug Adapter (main) - ERROR - Failed to connect to "remote 127.0.0.1:3333"!
Traceback (most recent call last):
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\command_processor.py", line 52, in __call__
on_request(protocol_message)
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\command_processor.py", line 75, in on_initialize_request
raise e
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\command_processor.py", line 70, in on_initialize_request
self.da.adapter_init()
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 328, in adapter_init
raise e
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 324, in adapter_init
self.start_gdb()
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 654, in start_gdb
raise e
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 651, in start_gdb
self._gdb.connect()
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_backend\debug_backend\gdb.py", line 578, in connect
self.target_select(remote_mode, self._remote_target, tmo=tmo)
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_backend\debug_backend\gdb.py", line 258, in target_select
raise DebuggerError('Failed to connect to "%s %s"!' % (tgt_type, tgt_params))
debug_adapter.debug_backend.debug_backend.defs.DebuggerError: Failed to connect to "remote 127.0.0.1:3333"!
2023-01-02 18:38:22,305 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "response", "request_seq": 1, "success": false, "command": "initialize", "seq": 7, "message": "Failed to init Debug Adapter!", "body": {}}
2023-01-02 18:38:22,307 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Failed to connect to \"remote 127.0.0.1:3333\"!\n", "source": {}}, "seq": 8}
2023-01-02 18:38:22,307 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Failed to connect to \"remote 127.0.0.1:3333\"!\n", "source": {}}, "seq": 9}
2023-01-02 18:38:22,368 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'Content-Length: 79\\r\\n'<<
2023-01-02 18:38:22,368 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'\\r\\n'<<
2023-01-02 18:38:22,368 - Debug Adapter(Command Processor) - DEBUG - Got json: {
"arguments": {
"restart": false
},
"command": "disconnect",
"seq": 2,
"type": "request"
}
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Adapter is Stopping...
2023-01-02 18:38:22,369 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Got json: {\n \"arguments\": {\n \"restart\": false\n },\n \"command\": \"disconnect\",\n \"seq\": 2,\n \"type\": \"request\"\n}\n", "source": {}}, "seq": 10}
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Stopping target poller
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Closing the GDB process
2023-01-02 18:38:22,369 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Debug Adapter stopped\n", "source": {}}, "seq": 11}
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Closing the Socket
2023-01-02 18:38:22,369 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Adapter is Stopping...\n", "source": {}}, "seq": 12}
2023-01-02 18:38:22,370 - Debug Adapter (main) - DEBUG - Stopping of the Writer thread
2023-01-02 18:38:22,370 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Stopping target poller\n", "source": {}}, "seq": 13}
2023-01-02 18:38:22,370 - Debug Adapter (main) - DEBUG - Stopping of the Reader thread
2023-01-02 18:38:22,371 - Debug Adapter (main) - DEBUG - Adapter is Stopped
2023-01-02 18:38:22,371 - Debug Adapter (main) - CRITICAL - Debug adapter -> Extension: DEBUG_ADAPTER_STOPPED
2023-01-02 18:38:22,371 - Debug Adapter(Command Processor) - DEBUG - Processed command: disconnect
-----------------------------------------------------------------------------------------------------------------------------------------------------------
Doctor report:
---------------------------------------------- ESP-IDF Extension for Visual Studio Code report ---------------------------------------------
OS win32 x64 10.0.22621
System environment variable IDF_PYTHON_ENV_PATH
undefined
System environment variable PATH
C:\Program Files\Common Files\Oracle\Java\javapath;C:\Python310\Scripts\;C:\Python310\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files (x86)\Plantronics\Spokes3G\;C:\Program Files\Git XL;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\ProgramData\chocolatey\bin;C:\Program Files\nodejs\;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\PuTTY\;C:\Program Files\WireGuard\;C:\Program Files\Git\cmd;C:\Program Files\dotnet\;C:<HOMEPATH>\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Git\cmd;C:<HOMEPATH>\AppData\Roaming\npm;C:<HOMEPATH>\AppData\Local\Microsoft\WindowsApps;C:<HOMEPATH>\AppData\Local\Markdown Monster;C:<HOMEPATH>\AppData\Local\Programs\Microsoft VS Code\bin
System environment variable PYTHON
undefined
Visual Studio Code version 1.74.2
Visual Studio Code language en
Visual Studio Code shell C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe
ESP-IDF Extension version 1.5.1
Workspace folder c:<HOMEPATH>\OneDrive\Documents\ESP32\restful_server
---------------------------------------------------- Extension configuration settings ------------------------------------------------------
ESP-ADF Path (idf.espAdfPath) ${env:ADF_PATH}
ESP-IDF Path (idf.espIdfPath) C:<HOMEPATH>\esp\esp-idf
ESP-MDF Path (idf.espMdfPath) ${env:MDF_PATH}
ESP-Matter Path (idf.espMatterPath) ${env:ESP_MATTER_PATH}
Custom extra paths (idf.customExtraPaths) C:<HOMEPATH>\.espressif\tools\xtensa-esp-elf-gdb\11.2_20220823\xtensa-esp-elf-gdb\bin;C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf-gdb\11.2_20220823\riscv32-esp-elf-gdb\bin;C:<HOMEPATH>\.espressif\tools\xtensa-esp32-elf\esp-2022r1-11.2.0\xtensa-esp32-elf\bin;C:<HOMEPATH>\.espressif\tools\xtensa-esp32s2-elf\esp-2022r1-11.2.0\xtensa-esp32s2-elf\bin;C:<HOMEPATH>\.espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin;C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf\esp-2022r1-11.2.0\riscv32-esp-elf\bin;C:<HOMEPATH>\.espressif\tools\esp32ulp-elf\2.35_20220830\esp32ulp-elf\bin;C:<HOMEPATH>\.espressif\tools\cmake\3.24.0\bin;C:<HOMEPATH>\.espressif\tools\openocd-esp32\v0.11.0-esp32-20221026\openocd-esp32\bin;C:<HOMEPATH>\.espressif\tools\ninja\1.10.2;C:<HOMEPATH>\.espressif\tools\idf-exe\1.0.3;C:<HOMEPATH>\.espressif\tools\ccache\4.6.2\ccache-4.6.2-windows-x86_64;C:<HOMEPATH>\.espressif\tools\dfu-util\0.9\dfu-util-0.9-win64
Custom extra vars (idf.customExtraVars) {"OPENOCD_SCRIPTS":"C:\\Users\\david\\.espressif\\tools\\openocd-esp32\\v0.11.0-esp32-20221026/openocd-esp32/share/openocd/scripts","IDF_CCACHE_ENABLE":"1"}
Virtual env Python Path (idf.pythonBinPath) C:<HOMEPATH>\.espressif\python_env\idf5.0_py3.8_env\Scripts\python.exe
Serial port (idf.port) COM9
OpenOCD Configs (idf.openOcdConfigs) board/esp32c3-builtin.cfg
ESP-IDF Tools Path (idf.toolsPath) C:<HOMEPATH>\.espressif
Git Path (idf.gitPath) C:<HOMEPATH>\.espressif\tools\idf-git\2.30.1\cmd\git.exe
-------------------------------------------------------- Configurations access -------------------------------------------------------------
Access to ESP-ADF Path (idf.espAdfPath) false
Access to ESP-IDF Path (idf.espIdfPath) true
Access to ESP-MDF Path (idf.espMdfPath) false
Access to ESP-Matter Path (idf.espMatterPath) false
Access to ESP-IDF Custom extra paths
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp-elf-gdb\11.2_20220823\xtensa-esp-elf-gdb\bin: true
Access to C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf-gdb\11.2_20220823\riscv32-esp-elf-gdb\bin: true
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp32-elf\esp-2022r1-11.2.0\xtensa-esp32-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp32s2-elf\esp-2022r1-11.2.0\xtensa-esp32s2-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf\esp-2022r1-11.2.0\riscv32-esp-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\esp32ulp-elf\2.35_20220830\esp32ulp-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\cmake\3.24.0\bin: true
Access to C:<HOMEPATH>\.espressif\tools\openocd-esp32\v0.11.0-esp32-20221026\openocd-esp32\bin: true
Access to C:<HOMEPATH>\.espressif\tools\ninja\1.10.2: true
Access to C:<HOMEPATH>\.espressif\tools\idf-exe\1.0.3: true
Access to C:<HOMEPATH>\.espressif\tools\ccache\4.6.2\ccache-4.6.2-windows-x86_64: true
Access to C:<HOMEPATH>\.espressif\tools\dfu-util\0.9\dfu-util-0.9-win64: true
Access to Virtual env Python Path (idf.pythonBinPath) true
Access to CMake in environment PATH undefined
Access to Ninja in environment PATH undefined
Access to ESP-IDF Tools Path (idf.toolsPath) true
-------------------------------------------------------- Configurations has spaces -------------------------------------------------------------
Spaces in system environment Path true
Spaces in ESP-ADF Path (idf.espAdfPath) false
Spaces in ESP-IDF Path (idf.espIdfPath) false
Spaces in ESP-MDF Path (idf.espMdfPath) false
Spaces in ESP-Matter Path (idf.espMatterPath) false
Spaces in ESP-IDF Custom extra paths
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp-elf-gdb\11.2_20220823\xtensa-esp-elf-gdb\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf-gdb\11.2_20220823\riscv32-esp-elf-gdb\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp32-elf\esp-2022r1-11.2.0\xtensa-esp32-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp32s2-elf\esp-2022r1-11.2.0\xtensa-esp32s2-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf\esp-2022r1-11.2.0\riscv32-esp-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\esp32ulp-elf\2.35_20220830\esp32ulp-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\cmake\3.24.0\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\openocd-esp32\v0.11.0-esp32-20221026\openocd-esp32\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\ninja\1.10.2: false
Spaces in C:<HOMEPATH>\.espressif\tools\idf-exe\1.0.3: false
Spaces in C:<HOMEPATH>\.espressif\tools\ccache\4.6.2\ccache-4.6.2-windows-x86_64: false
Spaces in C:<HOMEPATH>\.espressif\tools\dfu-util\0.9\dfu-util-0.9-win64: false
Spaces in Virtual env Python Path (idf.pythonBinPath) false
Spaces in ESP-IDF Tools Path (idf.toolsPath) false
----------------------------------------------------------- Executables Versions -----------------------------------------------------------
Git version 2.30.1.windows.1
ESP-IDF version 5.0
Python version 3.8.7
Python's pip version 22.3.1
-------------------------------------------------- Python packages in idf.pythonBinPath ----------------------------------------------------
bitstring version: 3.1.9
CacheControl version: 0.12.11
certifi version: 2022.12.7
cffi version: 1.15.1
charset-normalizer version: 2.1.1
click version: 8.0.4
colorama version: 0.4.6
construct version: 2.10.68
contextlib2 version: 21.6.0
cryptography version: 36.0.2
ecdsa version: 0.18.0
esp-coredump version: 1.4.2
esptool version: 4.4
freertos-gdb version: 1.0.1
future version: 0.18.2
gcovr version: 5.2
idf-component-manager version: 1.2.1
idna version: 3.4
Jinja2 version: 3.0.3
kconfiglib version: 14.1.0
lockfile version: 0.12.2
lxml version: 4.9.2
MarkupSafe version: 2.1.1
msgpack version: 1.0.4
packaging version: 22.0
pip version: 22.3.1
psutil version: 5.9.4
pycparser version: 2.21
pyelftools version: 0.27
pygdbmi version: 0.9.0.2
Pygments version: 2.13.0
pyparsing version: 3.0.9
pyserial version: 3.5
pywin32 version: 305
PyYAML version: 6.0
reedsolo version: 1.5.4
requests version: 2.28.1
requests-file version: 1.5.1
requests-toolbelt version: 0.10.1
schema version: 0.7.5
setuptools version: 65.6.3
six version: 1.16.0
tqdm version: 4.64.1
urllib3 version: 1.26.13
websocket-client version: 1.4.2
wheel version: 0.36.2
windows-curses version: 2.3.1
xmlrunner version: 1.7.7
---------------------------------------------------- Check ESP-IDF python requirements.txt -------------------------------------------------
Check ESP-IDF Python packages Python requirements are satisfied.
---------------------------------------------------- Check extension requirements.txt ------------------------------------------------------
Check Extension Python packages Python requirements are satisfied.
---------------------------------------------------- Check ESP-IDF debug adapter requirements.txt ------------------------------------------
Check Debug AdapterPython packages Python requirements are satisfied.
---------------------------------------------------- Visual Studio Code launch.json --------------------------------------------------------
{
"version": "0.2.0",
"configurations": [
{
"type": "espidf",
"name": "Launch",
"request": "launch",
"debugPort": 43474,
"logLevel": 4,
"mode": "auto",
"verifyAppBinBeforeDebug": false,
"tmoScaleFactor": 5,
"initGdbCommands": [
"target remote :3333",
"symbol-file C:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\build\\restful_server.elf",
"set remote hardware-watchpoint-limit 2",
"mon reset halt",
"flushregs",
"thb app_main",
"c"
],
"env": {
"CUSTOM_ENV_VAR": "SOME_VALUE"
}
}
]
}
---------------------------------------------------- Visual Studio Code c_cpp_properties.json ----------------------------------------------
{
"configurations": [
{
"name": "ESP-IDF",
"compilerPath": "C:\\Users\\david\\.espressif\\tools\\riscv32-esp-elf\\esp-2022r1-11.2.0\\riscv32-esp-elf\\bin\\riscv32-esp-elf-gcc.exe",
"cStandard": "c11",
"cppStandard": "c++17",
"includePath": [
"${config:idf.espIdfPath}/components/**",
"${config:idf.espIdfPathWin}/components/**",
"${config:idf.espAdfPath}/components/**",
"${config:idf.espAdfPathWin}/components/**",
"${workspaceFolder}/**"
],
"browse": {
"path": [
"${config:idf.espIdfPath}/components",
"${config:idf.espIdfPathWin}/components",
"${config:idf.espAdfPath}/components/**",
"${config:idf.espAdfPathWin}/components/**",
"${workspaceFolder}"
],
"limitSymbolsToIncludedHeaders": false
}
//"compileCommands": "${workspaceFolder}/build/compile_commands.json",
//"configurationProvider": "ms-vscode.cmake-tools"
}
],
"version": 4
}
--------------------------------------------------------------------------------------------------------------------------------------------
Not sure what's going wrong here, but it seems to be somewhere between the Debug adapter and GDB I think.
Thanks for any assistance.
Regards,
David.
I'm trying to get a Windows VSC environment working using the built-in JTAG on an esp32c3. So far I've managed to get an example downloading and executing ('restful_server'), but can't get debugging to work. The build and flash steps using Open OCD are working OK, so basic connectivity to the chip is working OK.
Here's some of the debug logs:
debug.log
------------------------------------
2023-01-02 18:37:25,487 - Debug Adapter (main) - DEBUG - START_TIME_2023_01_02_18-37-25
2023-01-02 18:37:25,487 - Debug Adapter (main) - DEBUG - Init errors:None
2023-01-02 18:37:25,487 - Debug Adapter (main) - INFO - Working directory: C:\Users\david\AppData\Local\Programs\Microsoft VS Code
2023-01-02 18:37:25,488 - Debug Adapter (main) - INFO - Arguments:
{ 'app_flash_off': 65536,
'board_type': None,
'cmdfile': 'c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\esp-idf-vscode-generated.gdb',
'core_file': (),
'debug': 4,
'developer_mode': 'none',
'device_name': 'esp32c3',
'elfpath': ( 'c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\build\\restful_server.elf',),
'log_file': 'c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\debug.log',
'log_mult_files': None,
'log_no_debug_console': None,
'oocd': 'openocd',
'oocd_args': None,
'oocd_ip': 'localhost',
'oocd_mode': 'connect_to_instance',
'oocd_scripts': None,
'port': 43474,
'postmortem': False,
'tmo_scale_factor': 5,
'toolchain_prefix': 'riscv32-esp-elf-'}
2023-01-02 18:37:25,488 - Debug Adapter (main) - CRITICAL - Debug adapter -> Extension: DEBUG_ADAPTER_STARTED
2023-01-02 18:37:25,488 - Debug Adapter (main) - INFO - Starting. Cmd: c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter_main.py -d 4 -e c:\Users\david\OneDrive\Documents\ESP32\restful_server\build\restful_server.elf -l c:\Users\david\OneDrive\Documents\ESP32\restful_server\debug.log -p 43474 -dn esp32c3 -a 0x10000 -t riscv32-esp-elf- -x c:\Users\david\OneDrive\Documents\ESP32\restful_server\esp-idf-vscode-generated.gdb -tsf 5
2023-01-02 18:37:25,493 - Debug Adapter (main) - INFO - Listening on port 43474
2023-01-02 18:37:25,494 - Debug Adapter (main) - CRITICAL - Debug adapter -> Extension: DEBUG_ADAPTER_READY2CONNECT
2023-01-02 18:37:25,498 - Debug Adapter (main) - DEBUG - Got connection
2023-01-02 18:37:25,499 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Debug adapter -> Extension: DEBUG_ADAPTER_STARTED\n", "source": {}}, "seq": 0}
2023-01-02 18:37:25,500 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Starting. Cmd: c:\\Users\\david\\.vscode\\extensions\\espressif.esp-idf-extension-1.5.1\\esp_debug_adapter\\debug_adapter_main.py -d 4 -e c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\build\\restful_server.elf -l c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\debug.log -p 43474 -dn esp32c3 -a 0x10000 -t riscv32-esp-elf- -x c:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\esp-idf-vscode-generated.gdb -tsf 5\n\n", "source": {}}, "seq": 1}
2023-01-02 18:37:25,500 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Listening on port 43474\n", "source": {}}, "seq": 2}
2023-01-02 18:37:25,500 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Debug adapter -> Extension: DEBUG_ADAPTER_READY2CONNECT\n", "source": {}}, "seq": 3}
2023-01-02 18:37:25,501 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Got connection\n", "source": {}}, "seq": 4}
2023-01-02 18:37:25,515 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'Content-Length: 480\\r\\n'<<
2023-01-02 18:37:25,515 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'\\r\\n'<<
2023-01-02 18:37:25,516 - Debug Adapter(Command Processor) - DEBUG - Got json: {
"arguments": {
"adapterID": "espidf",
"clientID": "vscode",
"clientName": "Visual Studio Code",
"columnsStartAt1": true,
"linesStartAt1": true,
"locale": "en-us",
"pathFormat": "path",
"supportsArgsCanBeInterpretedByShell": true,
"supportsInvalidatedEvent": true,
"supportsMemoryEvent": true,
"supportsMemoryReferences": true,
"supportsProgressReporting": true,
"supportsRunInTerminalRequest": true,
"supportsVariablePaging": true,
"supportsVariableType": true
},
"command": "initialize",
"seq": 1,
"type": "request"
}
2023-01-02 18:37:25,516 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Got json: {\n \"arguments\": {\n \"adapterID\": \"espidf\",\n \"clientID\": \"vscode\",\n \"clientName\": \"Visual Studio Code\",\n \"columnsStartAt1\": true,\n \"linesStartAt1\": true,\n \"locale\": \"en-us\",\n \"pathFormat\": \"path\",\n \"supportsArgsCanBeInterpretedByShell\": true,\n \"supportsInvalidatedEvent\": true,\n \"supportsMemoryEvent\": true,\n \"supportsMemoryReferences\": true,\n \"supportsProgressReporting\": true,\n \"supportsRunInTerminalRequest\": true,\n \"supportsVariablePaging\": true,\n \"supportsVariableType\": true\n },\n \"command\": \"initialize\",\n \"seq\": 1,\n \"type\": \"request\"\n}\n", "source": {}}, "seq": 5}
2023-01-02 18:37:25,523 - Gdb - DEBUG - MI->: -gdb-set mi-async on
2023-01-02 18:37:26,701 - Gdb - DEBUG - MI<-:
[{'message': 'thread-group-added',
'payload': {'id': 'i1'},
'stream': 'stdout',
'token': None,
'type': 'notify'},
{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,701 - Gdb - INFO - NOTIFY: thread-group-added {'id': 'i1'}
2023-01-02 18:37:26,701 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,701 - Gdb - DEBUG - MI->: -gdb-set logging file C:\Users\david\AppData\Local\Temp\gdb_proc.log
2023-01-02 18:37:26,712 - Gdb - DEBUG - MI<-:
[{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,712 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,712 - Gdb - DEBUG - MI->: -gdb-set logging on
2023-01-02 18:37:26,722 - Gdb - DEBUG - MI<-:
[{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,722 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,722 - Gdb - DEBUG - MI->: -gdb-set arch riscv:rv32
2023-01-02 18:37:26,733 - Gdb - DEBUG - MI<-:
[{'message': None,
'payload': 'The target architecture is set to \\"riscv:rv32\\".\\n',
'stream': 'stdout',
'type': 'console'},
{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:26,733 - Gdb - INFO - CONS: 'The target architecture is set to \\"riscv:rv32\\".\\n'
2023-01-02 18:37:26,733 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:26,733 - Debug Adapter (main) - DEBUG - Created gdb object of type: GdbEsp32c3
2023-01-02 18:37:26,733 - Gdb - DEBUG - MI->: -file-exec-and-symbols c:/Users/david/OneDrive/Documents/ESP32/restful_server/build/restful_server.elf
2023-01-02 18:37:26,733 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Created gdb object of type: GdbEsp32c3\n", "source": {}}, "seq": 6}
2023-01-02 18:37:32,304 - Gdb - DEBUG - MI<-:
[{'message': 'done',
'payload': None,
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:37:32,304 - Gdb - DEBUG - RESULT: done None
2023-01-02 18:37:32,304 - Gdb - DEBUG - Connecting to 127.0.0.1:3333
2023-01-02 18:37:32,304 - Gdb - DEBUG - MI->: -target-select remote 127.0.0.1:3333
2023-01-02 18:38:22,304 - Gdb - DEBUG - MI<-:
[{'message': None,
'payload': 'Ignoring packet error, continuing...\\n',
'stream': 'stdout',
'type': 'console'},
{'message': None,
'payload': 'warning: unrecognized item \\"timeout\\" in \\"qSupported\\" '
'response\\n',
'stream': 'stdout',
'type': 'log'},
{'message': 'error',
'payload': {'msg': "Remote replied unexpectedly to 'vMustReplyEmpty': "
'PacketSize=4000;qXfer:memory-map:read+;qXfer:features:read+;qXfer:threads:read+;QStartNoAckMode+;vContSupported+'},
'stream': 'stdout',
'token': None,
'type': 'result'}]
2023-01-02 18:38:22,304 - Gdb - INFO - CONS: 'Ignoring packet error, continuing...\\n'
2023-01-02 18:38:22,304 - Gdb - DEBUG - LOG: 'warning: unrecognized item \\"timeout\\" in \\"qSupported\\" response\\n'
2023-01-02 18:38:22,305 - Gdb - DEBUG - RESULT: error {'msg': "Remote replied unexpectedly to 'vMustReplyEmpty': "
'PacketSize=4000;qXfer:memory-map:read+;qXfer:features:read+;qXfer:threads:read+;QStartNoAckMode+;vContSupported+'}
2023-01-02 18:38:22,305 - Debug Adapter (main) - ERROR - Failed to connect to "remote 127.0.0.1:3333"!
Traceback (most recent call last):
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\command_processor.py", line 52, in __call__
on_request(protocol_message)
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\command_processor.py", line 75, in on_initialize_request
raise e
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\command_processor.py", line 70, in on_initialize_request
self.da.adapter_init()
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 328, in adapter_init
raise e
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 324, in adapter_init
self.start_gdb()
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 654, in start_gdb
raise e
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_adapter.py", line 651, in start_gdb
self._gdb.connect()
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_backend\debug_backend\gdb.py", line 578, in connect
self.target_select(remote_mode, self._remote_target, tmo=tmo)
File "c:\Users\david\.vscode\extensions\espressif.esp-idf-extension-1.5.1\esp_debug_adapter\debug_adapter\debug_backend\debug_backend\gdb.py", line 258, in target_select
raise DebuggerError('Failed to connect to "%s %s"!' % (tgt_type, tgt_params))
debug_adapter.debug_backend.debug_backend.defs.DebuggerError: Failed to connect to "remote 127.0.0.1:3333"!
2023-01-02 18:38:22,305 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "response", "request_seq": 1, "success": false, "command": "initialize", "seq": 7, "message": "Failed to init Debug Adapter!", "body": {}}
2023-01-02 18:38:22,307 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Failed to connect to \"remote 127.0.0.1:3333\"!\n", "source": {}}, "seq": 8}
2023-01-02 18:38:22,307 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Failed to connect to \"remote 127.0.0.1:3333\"!\n", "source": {}}, "seq": 9}
2023-01-02 18:38:22,368 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'Content-Length: 79\\r\\n'<<
2023-01-02 18:38:22,368 - Debug Adapter (ReaderThread) - DEBUG - read line: >>b'\\r\\n'<<
2023-01-02 18:38:22,368 - Debug Adapter(Command Processor) - DEBUG - Got json: {
"arguments": {
"restart": false
},
"command": "disconnect",
"seq": 2,
"type": "request"
}
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Adapter is Stopping...
2023-01-02 18:38:22,369 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Got json: {\n \"arguments\": {\n \"restart\": false\n },\n \"command\": \"disconnect\",\n \"seq\": 2,\n \"type\": \"request\"\n}\n", "source": {}}, "seq": 10}
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Stopping target poller
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Closing the GDB process
2023-01-02 18:38:22,369 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Debug Adapter stopped\n", "source": {}}, "seq": 11}
2023-01-02 18:38:22,369 - Debug Adapter (main) - DEBUG - Closing the Socket
2023-01-02 18:38:22,369 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Adapter is Stopping...\n", "source": {}}, "seq": 12}
2023-01-02 18:38:22,370 - Debug Adapter (main) - DEBUG - Stopping of the Writer thread
2023-01-02 18:38:22,370 - Debug Adapter (WriterThread) - DEBUG - Writing: {"type": "event", "event": "output", "body": {"output": "Stopping target poller\n", "source": {}}, "seq": 13}
2023-01-02 18:38:22,370 - Debug Adapter (main) - DEBUG - Stopping of the Reader thread
2023-01-02 18:38:22,371 - Debug Adapter (main) - DEBUG - Adapter is Stopped
2023-01-02 18:38:22,371 - Debug Adapter (main) - CRITICAL - Debug adapter -> Extension: DEBUG_ADAPTER_STOPPED
2023-01-02 18:38:22,371 - Debug Adapter(Command Processor) - DEBUG - Processed command: disconnect
-----------------------------------------------------------------------------------------------------------------------------------------------------------
Doctor report:
---------------------------------------------- ESP-IDF Extension for Visual Studio Code report ---------------------------------------------
OS win32 x64 10.0.22621
System environment variable IDF_PYTHON_ENV_PATH
undefined
System environment variable PATH
C:\Program Files\Common Files\Oracle\Java\javapath;C:\Python310\Scripts\;C:\Python310\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files (x86)\Plantronics\Spokes3G\;C:\Program Files\Git XL;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\ProgramData\chocolatey\bin;C:\Program Files\nodejs\;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\PuTTY\;C:\Program Files\WireGuard\;C:\Program Files\Git\cmd;C:\Program Files\dotnet\;C:<HOMEPATH>\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Git\cmd;C:<HOMEPATH>\AppData\Roaming\npm;C:<HOMEPATH>\AppData\Local\Microsoft\WindowsApps;C:<HOMEPATH>\AppData\Local\Markdown Monster;C:<HOMEPATH>\AppData\Local\Programs\Microsoft VS Code\bin
System environment variable PYTHON
undefined
Visual Studio Code version 1.74.2
Visual Studio Code language en
Visual Studio Code shell C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe
ESP-IDF Extension version 1.5.1
Workspace folder c:<HOMEPATH>\OneDrive\Documents\ESP32\restful_server
---------------------------------------------------- Extension configuration settings ------------------------------------------------------
ESP-ADF Path (idf.espAdfPath) ${env:ADF_PATH}
ESP-IDF Path (idf.espIdfPath) C:<HOMEPATH>\esp\esp-idf
ESP-MDF Path (idf.espMdfPath) ${env:MDF_PATH}
ESP-Matter Path (idf.espMatterPath) ${env:ESP_MATTER_PATH}
Custom extra paths (idf.customExtraPaths) C:<HOMEPATH>\.espressif\tools\xtensa-esp-elf-gdb\11.2_20220823\xtensa-esp-elf-gdb\bin;C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf-gdb\11.2_20220823\riscv32-esp-elf-gdb\bin;C:<HOMEPATH>\.espressif\tools\xtensa-esp32-elf\esp-2022r1-11.2.0\xtensa-esp32-elf\bin;C:<HOMEPATH>\.espressif\tools\xtensa-esp32s2-elf\esp-2022r1-11.2.0\xtensa-esp32s2-elf\bin;C:<HOMEPATH>\.espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin;C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf\esp-2022r1-11.2.0\riscv32-esp-elf\bin;C:<HOMEPATH>\.espressif\tools\esp32ulp-elf\2.35_20220830\esp32ulp-elf\bin;C:<HOMEPATH>\.espressif\tools\cmake\3.24.0\bin;C:<HOMEPATH>\.espressif\tools\openocd-esp32\v0.11.0-esp32-20221026\openocd-esp32\bin;C:<HOMEPATH>\.espressif\tools\ninja\1.10.2;C:<HOMEPATH>\.espressif\tools\idf-exe\1.0.3;C:<HOMEPATH>\.espressif\tools\ccache\4.6.2\ccache-4.6.2-windows-x86_64;C:<HOMEPATH>\.espressif\tools\dfu-util\0.9\dfu-util-0.9-win64
Custom extra vars (idf.customExtraVars) {"OPENOCD_SCRIPTS":"C:\\Users\\david\\.espressif\\tools\\openocd-esp32\\v0.11.0-esp32-20221026/openocd-esp32/share/openocd/scripts","IDF_CCACHE_ENABLE":"1"}
Virtual env Python Path (idf.pythonBinPath) C:<HOMEPATH>\.espressif\python_env\idf5.0_py3.8_env\Scripts\python.exe
Serial port (idf.port) COM9
OpenOCD Configs (idf.openOcdConfigs) board/esp32c3-builtin.cfg
ESP-IDF Tools Path (idf.toolsPath) C:<HOMEPATH>\.espressif
Git Path (idf.gitPath) C:<HOMEPATH>\.espressif\tools\idf-git\2.30.1\cmd\git.exe
-------------------------------------------------------- Configurations access -------------------------------------------------------------
Access to ESP-ADF Path (idf.espAdfPath) false
Access to ESP-IDF Path (idf.espIdfPath) true
Access to ESP-MDF Path (idf.espMdfPath) false
Access to ESP-Matter Path (idf.espMatterPath) false
Access to ESP-IDF Custom extra paths
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp-elf-gdb\11.2_20220823\xtensa-esp-elf-gdb\bin: true
Access to C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf-gdb\11.2_20220823\riscv32-esp-elf-gdb\bin: true
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp32-elf\esp-2022r1-11.2.0\xtensa-esp32-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp32s2-elf\esp-2022r1-11.2.0\xtensa-esp32s2-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf\esp-2022r1-11.2.0\riscv32-esp-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\esp32ulp-elf\2.35_20220830\esp32ulp-elf\bin: true
Access to C:<HOMEPATH>\.espressif\tools\cmake\3.24.0\bin: true
Access to C:<HOMEPATH>\.espressif\tools\openocd-esp32\v0.11.0-esp32-20221026\openocd-esp32\bin: true
Access to C:<HOMEPATH>\.espressif\tools\ninja\1.10.2: true
Access to C:<HOMEPATH>\.espressif\tools\idf-exe\1.0.3: true
Access to C:<HOMEPATH>\.espressif\tools\ccache\4.6.2\ccache-4.6.2-windows-x86_64: true
Access to C:<HOMEPATH>\.espressif\tools\dfu-util\0.9\dfu-util-0.9-win64: true
Access to Virtual env Python Path (idf.pythonBinPath) true
Access to CMake in environment PATH undefined
Access to Ninja in environment PATH undefined
Access to ESP-IDF Tools Path (idf.toolsPath) true
-------------------------------------------------------- Configurations has spaces -------------------------------------------------------------
Spaces in system environment Path true
Spaces in ESP-ADF Path (idf.espAdfPath) false
Spaces in ESP-IDF Path (idf.espIdfPath) false
Spaces in ESP-MDF Path (idf.espMdfPath) false
Spaces in ESP-Matter Path (idf.espMatterPath) false
Spaces in ESP-IDF Custom extra paths
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp-elf-gdb\11.2_20220823\xtensa-esp-elf-gdb\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf-gdb\11.2_20220823\riscv32-esp-elf-gdb\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp32-elf\esp-2022r1-11.2.0\xtensa-esp32-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp32s2-elf\esp-2022r1-11.2.0\xtensa-esp32s2-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\xtensa-esp32s3-elf\esp-2022r1-11.2.0\xtensa-esp32s3-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\riscv32-esp-elf\esp-2022r1-11.2.0\riscv32-esp-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\esp32ulp-elf\2.35_20220830\esp32ulp-elf\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\cmake\3.24.0\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\openocd-esp32\v0.11.0-esp32-20221026\openocd-esp32\bin: false
Spaces in C:<HOMEPATH>\.espressif\tools\ninja\1.10.2: false
Spaces in C:<HOMEPATH>\.espressif\tools\idf-exe\1.0.3: false
Spaces in C:<HOMEPATH>\.espressif\tools\ccache\4.6.2\ccache-4.6.2-windows-x86_64: false
Spaces in C:<HOMEPATH>\.espressif\tools\dfu-util\0.9\dfu-util-0.9-win64: false
Spaces in Virtual env Python Path (idf.pythonBinPath) false
Spaces in ESP-IDF Tools Path (idf.toolsPath) false
----------------------------------------------------------- Executables Versions -----------------------------------------------------------
Git version 2.30.1.windows.1
ESP-IDF version 5.0
Python version 3.8.7
Python's pip version 22.3.1
-------------------------------------------------- Python packages in idf.pythonBinPath ----------------------------------------------------
bitstring version: 3.1.9
CacheControl version: 0.12.11
certifi version: 2022.12.7
cffi version: 1.15.1
charset-normalizer version: 2.1.1
click version: 8.0.4
colorama version: 0.4.6
construct version: 2.10.68
contextlib2 version: 21.6.0
cryptography version: 36.0.2
ecdsa version: 0.18.0
esp-coredump version: 1.4.2
esptool version: 4.4
freertos-gdb version: 1.0.1
future version: 0.18.2
gcovr version: 5.2
idf-component-manager version: 1.2.1
idna version: 3.4
Jinja2 version: 3.0.3
kconfiglib version: 14.1.0
lockfile version: 0.12.2
lxml version: 4.9.2
MarkupSafe version: 2.1.1
msgpack version: 1.0.4
packaging version: 22.0
pip version: 22.3.1
psutil version: 5.9.4
pycparser version: 2.21
pyelftools version: 0.27
pygdbmi version: 0.9.0.2
Pygments version: 2.13.0
pyparsing version: 3.0.9
pyserial version: 3.5
pywin32 version: 305
PyYAML version: 6.0
reedsolo version: 1.5.4
requests version: 2.28.1
requests-file version: 1.5.1
requests-toolbelt version: 0.10.1
schema version: 0.7.5
setuptools version: 65.6.3
six version: 1.16.0
tqdm version: 4.64.1
urllib3 version: 1.26.13
websocket-client version: 1.4.2
wheel version: 0.36.2
windows-curses version: 2.3.1
xmlrunner version: 1.7.7
---------------------------------------------------- Check ESP-IDF python requirements.txt -------------------------------------------------
Check ESP-IDF Python packages Python requirements are satisfied.
---------------------------------------------------- Check extension requirements.txt ------------------------------------------------------
Check Extension Python packages Python requirements are satisfied.
---------------------------------------------------- Check ESP-IDF debug adapter requirements.txt ------------------------------------------
Check Debug AdapterPython packages Python requirements are satisfied.
---------------------------------------------------- Visual Studio Code launch.json --------------------------------------------------------
{
"version": "0.2.0",
"configurations": [
{
"type": "espidf",
"name": "Launch",
"request": "launch",
"debugPort": 43474,
"logLevel": 4,
"mode": "auto",
"verifyAppBinBeforeDebug": false,
"tmoScaleFactor": 5,
"initGdbCommands": [
"target remote :3333",
"symbol-file C:\\Users\\david\\OneDrive\\Documents\\ESP32\\restful_server\\build\\restful_server.elf",
"set remote hardware-watchpoint-limit 2",
"mon reset halt",
"flushregs",
"thb app_main",
"c"
],
"env": {
"CUSTOM_ENV_VAR": "SOME_VALUE"
}
}
]
}
---------------------------------------------------- Visual Studio Code c_cpp_properties.json ----------------------------------------------
{
"configurations": [
{
"name": "ESP-IDF",
"compilerPath": "C:\\Users\\david\\.espressif\\tools\\riscv32-esp-elf\\esp-2022r1-11.2.0\\riscv32-esp-elf\\bin\\riscv32-esp-elf-gcc.exe",
"cStandard": "c11",
"cppStandard": "c++17",
"includePath": [
"${config:idf.espIdfPath}/components/**",
"${config:idf.espIdfPathWin}/components/**",
"${config:idf.espAdfPath}/components/**",
"${config:idf.espAdfPathWin}/components/**",
"${workspaceFolder}/**"
],
"browse": {
"path": [
"${config:idf.espIdfPath}/components",
"${config:idf.espIdfPathWin}/components",
"${config:idf.espAdfPath}/components/**",
"${config:idf.espAdfPathWin}/components/**",
"${workspaceFolder}"
],
"limitSymbolsToIncludedHeaders": false
}
//"compileCommands": "${workspaceFolder}/build/compile_commands.json",
//"configurationProvider": "ms-vscode.cmake-tools"
}
],
"version": 4
}
--------------------------------------------------------------------------------------------------------------------------------------------
Not sure what's going wrong here, but it seems to be somewhere between the Debug adapter and GDB I think.
Thanks for any assistance.
Regards,
David.