Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Hot Topic (More than 8 Replies) JTAG debugging no longer works after updating VS 2023 to 17.7.5. (Read 2549 times)
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Oct 16th, 2023 at 10:47am
Print Post  
Die Fehlermeldungen lauten:
1.      VS2022: „Unable to start debugging. Unable to establish a connection to GDB. Debug output may contain more information.“
2.      Der letzte Debugger-Befehl endet mit Fehler:  exited with code 1 (0x1).
3.      Setze ich den Befehl mit CMD kommt das Ergebnis:
\vmicro\\tools\\openocd-espressif-esp32-10.0.1\bin/openocd.exe"
Open On-Chip Debugger  v0.10.0-esp32-20190313 (2019-03-13-09:57)
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
embedded:startup.tcl:63: Error: Can't find openocd.cfg
in procedure 'script'
at file "embedded:startup.tcl", line 63
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Error: Debug Adapter has to be specified, see "interface" command
embedded:startup.tcl:63: Error:
in procedure 'script'
at file "embedded:startup.tcl", line 63
4.      In Blink5.ino_DebugOpenOCD steht:
none
adapter speed: 2000 kHz
Info : Configured 2 cores
esp32 interrupt mask on
Error: No J-Link device found.

Warn : Flash driver of esp32.flash does not support free_driver_priv()
Warn : Flash driver of irom does not support free_driver_priv()
Warn : Flash driver of drom does not support free_driver_priv()
Eine Neuinstallation von vMicro hat nichts gebracht. Was wäre da noch zu tun?
« Last Edit: Oct 16th, 2023 at 11:24am by Simon@Visual Micro »  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2441
Joined: Feb 13th, 2019
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #1 - Oct 16th, 2023 at 11:25am
Print Post  
Thanks for the report.

Can you confirm you have updated the JLink Driver to WinUSB using the Zadig Tool?
https://www.visualmicro.com/page/Zadig-Driver-Installation-Guide.aspx
  
Back to top
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #2 - Oct 16th, 2023 at 12:50pm
Print Post  
Die Schnittstelle wurde mit der Version Zadig V2.8 installiert. Mit folgendem Befehl wird meiner Ansicht nach der JTAG-Adapter erkannt? 
C:\ProgramData\vmicro\tools\openocd-espressif-esp32-10.0.1\bin>openocd -s tcl -f interface/ftdi/esp32_devkitj_v1.cfg -f board/esp-wroom-32.cfg
Open On-Chip Debugger  v0.10.0-esp32-20190313 (2019-03-13-09:57)
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
none separate
adapter speed: 2000 kHz
Info : Configured 2 cores
esp32 interrupt mask on
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : clock speed 2000 kHz
Info : JTAG tap: esp32.cpu0 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
Info : JTAG tap: esp32.cpu1 tap/device found: 0x120034e5 (mfg: 0x272 (Tensilica), part: 0x2003, ver: 0x1)
Info : esp32: Debug controller 0 was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core 0 was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Debug controller 1 was reset (pwrstat=0x5F, after clear 0x0F).
Info : esp32: Core 1 was reset (pwrstat=0x5F, after clear 0x0F).
Info : Listening on port 3333 for gdb connections
  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2441
Joined: Feb 13th, 2019
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #3 - Oct 16th, 2023 at 1:18pm
Print Post  
Please log in English on the forum so we can understand the issue correctly.

Your initial post mentioned the JLink adapter, however the command you have run is looking for the FT2232H JTAG chip on the Espressif DevkitJ board, which is a completely separate debugging probe.

Can you confirm which adapter you wish to use for debugging, and then enable the options shown at the top of the page, and attach the complete log file from a Build so we can see your setup in full?

If there is any additional output in the Output > Debug window when using Debug > Attach to Process, please also attach this for us to review.
  
Back to top
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #4 - Oct 16th, 2023 at 2:33pm
Print Post  
I thought I had a Segger J-Link. But it is an ESP32 PROG and is connected as shown on your website. Now ESP32 PROG is also set in the debugger. The exit code is 1 (0x1).
  

Please Register or Login to the Forum to see File Attachments
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2441
Joined: Feb 13th, 2019
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #5 - Oct 16th, 2023 at 2:45pm
Print Post  
Thanks for the update.

Can you confirm your code does not use any of the JTAG pins (GPIO 12-15) in any way?

Also please attach the full log from a build so we can confirm versions and the specific board in use.
  
Back to top
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #6 - Oct 16th, 2023 at 3:06pm
Print Post  
I therefore set the output in Blink to GPIO 5.
  

Please Register or Login to the Forum to see File Attachments
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2441
Joined: Feb 13th, 2019
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #7 - Oct 16th, 2023 at 3:08pm
Print Post  
Thanks for the update.

If you upload the code to the board (via Serial/USB) and then try the Debug > Attach to Process, does this now work as expected?
  
Back to top
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #8 - Oct 16th, 2023 at 3:31pm
Print Post  
The error message appears:
Microsoft Visual Studio
Unable to start debugging. Unexpected GDB output from command "-target-select remote localhost:3333". Remote communication error. Target disconnected.: (undocumented errno 10061).
  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2441
Joined: Feb 13th, 2019
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #9 - Oct 16th, 2023 at 3:48pm
Print Post  
Thanks, can you check there are no processes running called "openocd.exe" or "xtensa-esp32-elf-gdb.exe" and if there are kill these in task manager.

Then try attaching the debugger again.
  
Back to top
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #10 - Oct 16th, 2023 at 4:06pm
Print Post  
"openocd.exe" or "xtensa-esp32-elf-gdb.exe were not active. I ran the debug option “Attach to process” again and the debugger stopped at the breakpoint!!! Why only now? I I'll continue testing and report back.
  
Back to top
 
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #11 - Oct 16th, 2023 at 5:23pm
Print Post  
When I start debugging and at the end of the loading process call the debugging option “Attach to process”, I get into debugging mode. But that's not normal operation!! Is there another way?
  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2441
Joined: Feb 13th, 2019
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #12 - Oct 16th, 2023 at 5:29pm
Print Post  
If you press the Debug > Start button it will perform the build and upload operations, and then automatically start the debugging process.
  
Back to top
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #13 - Oct 16th, 2023 at 5:56pm
Print Post  
When I click the Debug button, I get the error message:
 
Microsoft Visual Studio
Unable to start debugging. GDB exited unexpectedly with exit code 1 (0x1).
  
Back to top
 
IP Logged
 
Harry22
Newbies
*
Offline


Posts: 9
Joined: Oct 11th, 2023
Re: JTAG debugging no longer works after updating VS 2023 to 17.7.5.
Reply #14 - Oct 17th, 2023 at 8:04am
Print Post  
I can debug with the following process:
After starting with the “Start” button, the program is loaded onto the ESP32 after compiling. When the write cycle is around 70%, I call “Attach to Process” using the Debug button. Now debugging will start. The debugger stopped at the breakpoint. The message comes from VS: “Do you want to stop debugging? Yes No". If no, I can work with the debugger. This works with all other programs too.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint