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
Normal Topic Confusing ERROR with ESP32PRG JTAG Adapter and HW Debugging (Read 204 times)
Apostel14
Newbies
*
Offline


Posts: 3
Joined: Nov 21st, 2024
Confusing ERROR with ESP32PRG JTAG Adapter and HW Debugging
Nov 21st, 2024 at 2:57pm
Print Post  
There is a confusing problem with the HW debugging of a ESP32 DevBoard. I’m using VS community version 17.12.1 and the latest VisualMicro installed from the extension manager of the VS. Both are clean installations. I use the VM no Arduino IDE option. Build and uploading Arduino projects are running well. 

But if I try to use the HW debugging (the main reason why I bought the VM) it is hard to get it run.
I use the ESP32 Prog adapter from Espressif as HW debugger and the Target Unit is a common ESP32 Devboard. 

If I use the following settings
Debug:      Hardware
Debugger:      ESP32 PROG
Compileropt:        No

It does not work. I got an Error message 

“Unable to start debugging. Unable to establish a connection to GDB. Debug output may contain more information."

The debug output you can find it below. The MicroBuild output I attached.

BUT

If I use the ESPESP32 DEVBOARD instead the ESP32 PROG as HW Debugger in the settings, it works more than less.  Which is surprising, because the DEV BOARD is not the HW debugger. The debugger is the ESP32 Prog Adapter, which is connected to the DevBoard as a JTAG.


Starting:  -d2 -l DebugOpenOCD.log}" -s s/" -f s/interface/ftdi/minimodule-lowcost.cfg" -c "set ESP32_RTOS none" -f s/board/esp-wroom-32.cfg" -c "init; reset halt"
Starting: lf-gdb.exe" --interpreter=mi -ex "set remote hardware-watchpoint-limit 2" -ex "mon reset halt" -ex "flushregs" -ex "thb app_main" -ex "c"
exited with code 1 (0x1).
  

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


Posts: 2496
Joined: Feb 13th, 2019
Re: Confusing ERROR with ESP32PRG JTAG Adapter and HW Debugging
Reply #1 - Nov 21st, 2024 at 3:03pm
Print Post  
Thanks for the report.

The configurations for both are virtually identical (as both technically use the same FT2232H chip).   

Can you confirm which specific target ESP32 MCU is in use?

Could you try attaching with the ESP-PROG, and then attach the OpenOCD Log from the build folder, and the output from the Output > Debug Window as well?
Doc: Locate OpenOCD Log File
« Last Edit: Nov 21st, 2024 at 3:04pm by Simon@Visual Micro »  
Back to top
IP Logged
 
Apostel14
Newbies
*
Offline


Posts: 3
Joined: Nov 21st, 2024
Re: Confusing ERROR with ESP32PRG JTAG Adapter and HW Debugging
Reply #2 - Nov 21st, 2024 at 4:05pm
Print Post  
The Target is a JOY-iT ESP32 Devborad with a ESP WROM-32 modue, but I have check it out with different Boards and modules, with all the same behavior.

The DebugOpenOCD attached.   
  

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


Posts: 2496
Joined: Feb 13th, 2019
Re: Confusing ERROR with ESP32PRG JTAG Adapter and HW Debugging
Reply #3 - Nov 21st, 2024 at 4:47pm
Print Post  
Thanks for the log.

There are some minor differences between the configurations for the probe, and we will update the ESP-PROG to use the same config as the DEVKIT in the next release once tested if it is proving more reliable, and aligns with the Espressif Documentation.

Do you have any other issues when using the ESP32 DEVKIT configuration? 

  
Back to top
IP Logged
 
Apostel14
Newbies
*
Offline


Posts: 3
Joined: Nov 21st, 2024
Re: Confusing ERROR with ESP32PRG JTAG Adapter and HW Debugging
Reply #4 - Nov 21st, 2024 at 8:53pm
Print Post  
Hello and thanks for the fast answer.

I have not tested VM in detail yet.  But what noticeable is, is that I must manually set the DevBoard in the Upload-Mode by pressing the switches on the board. That is not necessary if I use the same hardware combination on the same PC under PlatformIO and VSC. Mayby  that’s works in this environment why I can choose there the correct hardware ESP32-PROG.

Best regards
« Last Edit: Nov 22nd, 2024 at 11:52am by Apostel14 »  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint