vard

Forum Replies Created

Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • in reply to: Update OpenOCD #21599
    vard
    Participant

    I’ve re-installed everything from  scratch, I no longer get that error, and the debugger seems to stop just fine at the first breakpoint! I can even step through the code!

    Very nice, many thanks!

    in reply to: Update OpenOCD #21598
    vard
    Participant

    Hi,

    I’ve downloaded and installed VGDB 5.4 Preview 4 and the latest ESP32 toolchain (R10) but now I have a different issue: I can’t see the debug configuration. Under the “Debug settings” tab, I’ve selected “Debug using ESP32 Devkit” but I got a “Failed To Display Configuration” error:

    System.MissingMethodException: Method not found: ‘BSPEngine.IAdvancedProjectDebugContext BSPEngine.IBSPConfiguratorHost.get_AdvancedModeContext()’.
    at OpenOCDPackage.OpenOCDSettingsEditor..ctor(IBSPConfiguratorHost host, String baseDir, OpenOCDSettings settings, KnownInterfaceInstance context, Boolean autoDetectDevice)
    at ESP8266DebugPackage.ESPxxOpenOCDSettingsEditor..ctor(IBSPConfiguratorHost host, String baseDir, ESPxxOpenOCDSettings settings, KnownInterfaceInstance context, Boolean isESP32)
    at ESP8266DebugPackage.GUI.ESPxxOpenOCDSettingsControl.SetConfiguration(Object configuration, KnownInterfaceInstance context)
    at VisualGDB.Common_GUI.WPF.DebugMethodSettingsControl.Controller.set_SelectedItem(MethodOrDeviceItemBase value)

    in reply to: Update OpenOCD #21549
    vard
    Participant

    That’s very nice of you, thank you for going out of your way to help with this issue!
    Looking forward to trying out the new preview release.

    in reply to: Update OpenOCD #21540
    vard
    Participant

    Fair enough, thanks again for all the help!

    in reply to: Update OpenOCD #21535
    vard
    Participant

    Hmmm…. I’m still seeing some problems, but of a more or less different kind this time around: On a clean memory ESP32 (flash erased), I can do a Debug Test Settings from VisualGDB properties page and everything works fine. Then I program the chip and run the program, no problem. But if I make any changes in the code and try to program again, the debugger fails to connect and program the ESP32. I get an error: Failed to get flash maps(-1)!

    The stub log looks like this:

    c:\sysgcc\esp32\esp32-bsp\OpenOCD\bin\openocd.exe -c “gdb_port 55856” -c “telnet_port 55857” -f interface/ftdi/esp32_devkitj_v1.cfg -c “adapter_khz 3000” -f target/esp32.cfg -c “echo VisualGDB_OpenOCD_Ready”
    Open On-Chip Debugger 0.9.0 (2018-07-30)
    Licensed under GNU GPL v2
    For bug reports, read
    http://openocd.org/doc/doxygen/bugs.html
    none separate
    adapter speed: 3000 kHz
    Info : auto-selecting first available session transport “jtag”. To override use ‘transport select <transport>’.
    force hard breakpoints
    VisualGDB_OpenOCD_Ready
    Info : clock speed 3000 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 : Target halted. PRO_CPU: PC=0x40009070 (active) APP_CPU: PC=0x400076DD
    Info : accepting ‘gdb’ connection on tcp/55856
    Info : Target halted. PRO_CPU: PC=0x4009170E (active) APP_CPU: PC=0x400076DD
    Error: Failed to get flash maps (-1)!
    Error: Failed to get flash mappings (-4)!
    Error: auto_probe failed
    Error: Connect failed. Consider setting up a gdb-attach event for the target to prepare target for GDB connect, or use ‘gdb_memory_map disable’.
    Error: attempted ‘gdb’ connection rejected

    Going back to the VisualGDB Project Properties page, I can no longer get a successful test, the test console window displays the same message as the above stub log.

    The only way I can get this back to work is to use the ESP32 Download tool to erase the flash. After erasing the flash, the test works correctly and I can go ahead an program the chip:

    c:\sysgcc\esp32\esp32-bsp\OpenOCD\bin\openocd.exe -c “gdb_port 55959” -c “telnet_port 55960” -f interface/ftdi/esp32_devkitj_v1.cfg -c “adapter_khz 3000” -f target/esp32.cfg -c “echo VisualGDB_OpenOCD_Ready”
    Open On-Chip Debugger 0.9.0 (2018-07-30)
    Licensed under GNU GPL v2
    For bug reports, read
    http://openocd.org/doc/doxygen/bugs.html
    none separate
    adapter speed: 3000 kHz
    Info : auto-selecting first available session transport “jtag”. To override use ‘transport select <transport>’.
    force hard breakpoints
    VisualGDB_OpenOCD_Ready
    Info : clock speed 3000 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 was reset (pwrstat=0x5F, after clear 0x0F).
    Info : esp32: Core was reset (pwrstat=0x5F, after clear 0x0F).
    Info : accepting ‘gdb’ connection on tcp/55959
    Info : Target halted. PRO_CPU: PC=0x40090616 (active) APP_CPU: PC=0x00000000
    Info : Target halted. PRO_CPU: PC=0x4009170E (active) APP_CPU: PC=0x00000000
    Info : Target halted. PRO_CPU: PC=0x4009170E (active) APP_CPU: PC=0x00000000
    Info : Auto-detected flash size 4096 KB
    Info : Using flash size 4096 KB
    Info : dropped ‘gdb’ connection
    Info : Restore debug stubs @ 0 on core0 of target ‘esp32’

    All seems to be working fine after that except… it no longer wants to stop to any break points (again)!

    During debug I can go into the GDB Session window and try the Diagnose Breakpoint Problems button but the answer is “No breakpoint problems detected”

    So it worked beautifully the first time I tried the latest OpenOCD versions, but now it’s doing the same thing as before, plus the programming issue (I have to erase the flash to program it).

    I tried it on 3 different debuggers (I tried ESP32 Devkit, Olimex and Segger Jlink) and two ESP32 boards (Devkit and ESP core V2).

    Any suggestions?

    Thanks again for all the help and support!

     

     

    in reply to: Update OpenOCD #21533
    vard
    Participant

    Awesome ! Works like a charm! And thank you for taking your time to make the exe file, much appreciated!

     

    in reply to: Missing option in SDK Config #21323
    vard
    Participant

    You are quite right, it was a project specific problem. I was trying to import an older IDF 2.1 project and I had an additional #include sdkconfig.h statement in one of the older header files.

    Works well, now thank you very much!

    in reply to: Failed to clone ESP-IDF #20842
    vard
    Participant

    Thank you very much for the fast response, it looks like I had an issue with the toolchain and the path on my PC. I re-installed it and everything seems to be fine now.
    All the best!

    in reply to: Code Map Issues #11581
    vard
    Participant

    I see… thank you!

    in reply to: Code Map Issues #11575
    vard
    Participant

    Left clicked on function, it appeared in the rightmost combo box, right clicked on the same function and here’s what I got:  Snap Shot 2

    in reply to: Code Map Issues #11573
    vard
    Participant

    It is hosted on my Dropbox. You can right click on the link and select Open Image in a new tab.

    in reply to: Code Map Issues #11562
    vard
    Participant

    Thank you kindly for your fast reply.

    The Preprocess Selected Lines command appears upon mouse right-click and is functional, but the Code Map is not.

    Please see snap shot  Snap_shot

    • This reply was modified 6 years, 10 months ago by vard.
    in reply to: Problem: ESP32 Wroom with OpenOCD #11352
    vard
    Participant

    Not sure if you’ve read this, some good information here: LIMITATIONS OF THE ESP32 DEBUGGING

    in reply to: ESP32 WROVER + JLINK OpenOCD problems #11348
    vard
    Participant

    Please disregard question number 2 regarding the breakpoints, I read “LIMITATIONS OF THE ESP32 DEBUGGING”, 2 breakpoints (no wonder it was crashing at 3!).

    Thanks!

    • This reply was modified 6 years, 11 months ago by vard.
    in reply to: ESP32 WROVER + JLINK OpenOCD problems #11347
    vard
    Participant

    Thank you kindly for your response, you were quite right, I had a connection problem indeed (broken wire inside the shrink tube of the test wire).

    Found it with the logic analyzer, all is good now!

     

    I can now run the ESP32 Demo as per your latest tutorial, picked up the LED blinky as suggested. The Jlink / OpenOCD seems to be working fine now, but I still have a couple of very quick questions:

    1 – I get some messages in the GDB session window, and I’m too sure I understand what they mean:

    Warning: could not set a breakpoint on main. ‘Step into new instance’ will not work.
    Indeed, after loading the program, the debugger does not stop at main as I believe it should (I’ve got Stepping into new instance (F10) will stop in: main checked).

    Cannot resolve the address of _estack. Skipping stack pointer validity check.

    Obviously, if I un-check the box “Validate stack pointer when starting debugging”  the warning goes away, but I would still like to understand what it means.

    Any suggestions?

     

    2 – What is the maximum number of hardware breakpoints I can have with Jlink/OpenOCD on ESP32? I tried 3 breakpoints and the debugger crashed. I know I’m wasting a breakpoint stopping at main at start-up, I will un-check the stop at main box because the debugger never stops at main anyway, but I would still like to know the maximum number of breakpoints.

     

    Thanks again for all the help and support!

     

Viewing 15 posts - 1 through 15 (of 15 total)