VisualGDB, JTAG debugging with Segger JLink

Sysprogs forums Forums VisualGDB VisualGDB, JTAG debugging with Segger JLink

This topic contains 5 replies, has 3 voices, and was last updated by  gojimmypi 2 years, 7 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #10357

    Reto Keller
    Participant

    Dear sysprogs,

    I am trying to debug my ADAFRUIT FEATHER HUZZAH WITH ESP8266 WIFI module with VisualGDB and a Segger JLink debugger.

    I have the following issue: I can set breakpoints, but the debugger does not stop.

    I double checked the wiring with this tutorial: https://visualgdb.com/tutorials/esp8266/

    Any suggestions? THANK YOU!

     

    Here the output:

    Open On-Chip Debugger 0.9.0 (2015-11-04-20:38)
    Licensed under GNU GPL v2
    For bug reports, read
    http://openocd.org/doc/doxygen/bugs.html
    trst_and_srst separate srst_gates_jtag trst_push_pull srst_open_drain connect_deassert_srst
    adapter speed: 1000 kHz
    stop_wdt
    Info : J-Link V9 compiled Oct 18 2012 19:49:50
    Info : J-Link caps 0xb9ff7bbf
    Info : J-Link hw version 90000
    Info : J-Link hw type J-Link
    Info : J-Link max mem block 74856
    Info : J-Link configuration
    Info : USB-Address: 0x0
    Info : Kickstart power on JTAG-pin 19: 0xffffffff
    Info : Vref = 3.362 TCK = 1 TDI = 0 TDO = 0 TMS = 0 SRST = 1 TRST = 1
    Info : J-Link JTAG Interface ready
    Info : clock speed 1000 kHz
    Info : TAP esp8266.cpu does not have IDCODE
    Info : halted: PC: 0x40003b50
    Info : debug cause: 0x20
    Info : accepting ‘gdb’ connection on tcp/3333
    Error: JTAG scan chain interrogation failed: all zeroes
    Error: Check JTAG interface, timings, target power, etc.
    Error: Trying to use configured scan chain anyway…
    Error: esp8266.cpu: IR capture error; saw 0x00 not 0x01
    Warn : Bypassing JTAG setup events due to errors
    Warn : xtensa_deassert_reset: ‘reset halt’ is not supported for Xtensa. Have halted some time after resetting (not the same thing!)
    target state: halted
    Info : halted: PC: 0x40003b4d
    Info : debug cause: 0x20
    Info : halted: PC: 0x40003b50
    Info : debug cause: 0x1
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Info : halted: PC: 0x4010013c
    Info : debug cause: 0x8
    Interrupt suppression during single-stepping is now enabled
    Watchdog feeding during stops is now enabled
    invalid command name “detach”
    Info : dropped ‘gdb’ connection

    • This topic was modified 2 years, 7 months ago by  Reto Keller.
    • This topic was modified 2 years, 7 months ago by  Reto Keller.
    #10365

    gojimmypi
    Participant

    Hi – I had a similar issue, perhaps this thread may be helpful:

    https://sysprogs.com/w/forums/topic/where-to-find-esp8266-xtensa-lx-106-elf-for-gdb-stub/

    fwiw – I ended up buying Olimex hardware (both the JTAG programmer & ESP8266 EVB) from Mouser Electronics. I had more success, but things still did not work out quite as one might expect.

    See also my thread on the Olimex forum that may be of interest:

    https://www.olimex.com/forum/index.php?topic=5676.0

    I plan to revisit the Segger this weekend & will post my results. One thing that may have been reckless on my part: I used a nice parallel cable with the Olimex, and an octopus of loose wires with the Segger:

    https://twitter.com/gojimmypi/status/830173265993674752

    Lame, as my background is in electronics and I should know that the alternating parallels of ground wire can significantly reduce the noise and interference on the signal lines.

     

    #10373

    support
    Keymaster

    Hi,

    The “Error: JTAG scan chain interrogation failed: all zeroes” error almost 100% indicates a wiring problems (that also includes power and reset issues). Hence our best advice is to get exactly the same hardware as shown in the tutorial, get it to work and once you get a stable reference point, start experimenting with different boards.

    #10411

    Reto Keller
    Participant

    Thank you guys for your answers!

    I don’t expect that my problems come from “octopus” wiring/cableling rather than an ESP8266 issue together with Segger J-Link and Windows 10 driver and VisualGDB… It all looks quite shaky and unstable to me. And I don’t like the kind of problems. I would like to focus on my application.

    I triple checked my wiring and I still can’t find an error (I made one silly mistake at the beginning, but since then couldn’t find a mistake in wiring).

    I don’t want to loose too much time here and I do not want to buy a new debugger hardware. So I may try debugging over serial interface / UART. I hope this is more stable?

    Again: many thanks to you for the support.

    #10479

    support
    Keymaster

    Hi,

    Yes, the gdb stub-based debugging should not be affected by the JTAG wiring issues, so we would recommend trying it if JTAG does not work.

    #10484

    gojimmypi
    Participant

    The “Error: JTAG scan chain interrogation failed: all zeroes” error almost 100% indicates a wiring problems (that also includes power and reset issues).

    I’d like to add that I’ve recently found that simply power-cycling the ESP8266 and JTAG programmer has resolved my “all zeros” problem as well.

    But I agree that adequate power is important, as well as understanding the reset line (e.g note the NodeMCU can control the reset line via serial port RTS/DTR lines)

     

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

You must be logged in to reply to this topic.