3 Replies Latest reply on Oct 20, 2020 3:24 PM by RoFl_4496141

    Can't start debugger (Error: can't add breakpoint: target running)

    RoFl_4496141

      I'm trying to do the bring-up for our board and I'm afraid I'm stumped.

       

      I can see the board in the Control Center and I can attempt to load a program to RAM, but then it fails to enumerate again. So I tried to debug the code.

       

      I'm having pretty much the same symptons as this old post:

      [FX3 Debug] Error: can't add breakpoint: target running

      ... but I can't move forward.

       

      Here's my console dump:

       

      Open On-Chip Debugger 0.8.0 (2014-12-03-15:43)

      Licensed under GNU GPL v2

      For bug reports, read

          http://openocd.sourceforge.net/doc/doxygen/bugs.html

      Warn : Adapter driver 'cy7c65215' did not declare which transports it allows; assuming legacy JTAG-only

      Info : only one transport option; autoselect 'jtag'

      adapter_nsrst_delay: 200

      jtag_ntrst_delay: 200

      adapter speed: 1000 kHz

      trst_and_srst srst_pulls_trst srst_gates_jtag trst_push_pull srst_open_drain connect_deassert_srst

      RCLK - adaptive

      adapter speed: 1000 kHz

      Info : clock speed 1000 kHz

      Error: JTAG scan chain interrogation failed: all ones

      Error: Check JTAG interface, timings, target power, etc.

      Error: Trying to use configured scan chain anyway...

      Error: fx3.cpu: IR capture error; saw 0x0f not 0x01

      Warn : Bypassing JTAG setup events due to errors

      Info : Embedded ICE version 0

      Error: unknown EmbeddedICE version (comms ctrl: 0x00000000)

      Info : fx3.cpu: hardware has 2 breakpoint/watchpoint units

      Info : accepting 'gdb' connection from 3333

      undefined debug reason 7 - target needs reset

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Error: Target not halted

      Warn : target not halted

      Error: JTAG scan chain interrogation failed: all ones

      Error: Check JTAG interface, timings, target power, etc.

      Error: Trying to use configured scan chain anyway...

      Error: fx3.cpu: IR capture error; saw 0x0f not 0x01

      Warn : Bypassing JTAG setup events due to errors

      Warn : srst pulls trst - can not reset into halted mode. Issuing halt after reset.

      Error: timed out while waiting for target halted

      TARGET: fx3.cpu - Not halted

       

      in procedure 'reset'

      Info : Halt timed out, wake up GDB.

      Error: timed out while waiting for target halted

      in procedure 'halt'

      Warn : target not halted

      Warn : target not halted

      Warn : target not halted

      Warn : target not halted

      Warn : target not halted

      Warn : target not halted

      Warn : target not halted

      Warn : target not halted

      Warn : target fx3.cpu is not halted

      Error: can't add breakpoint: target running

      Info : dropped 'gdb' connection

       

      But I can't debug, execution doesn't stop at main, arm-none-eabi-gdb is terminated (exit value 0) as does openocd.exe (exit value 1). We have an on board CY7C65215-32LTXIT and it's both wired and programmed exactly as the one in the Explorer Board. Still, I can't debug (but I have no problems whatsoever in the Explorer Board).

       

      Since I also have the "target not halted" I checked the schematic and even measured connectivity for TRST and everything seems to be sound. I don't have an oscilloscope at hand*, so I wanted to see if there's something else I could test.

       

      Any ideas?

       

      Even if it's just a JTAG problem, I'm still at a loss as to why it wouldn't enumerate. I made a small app that does nothing beyond basic clock config and RTOS start, and it still doesn't enumerate.

       

      * As I write this, I'm suspecting the error on "Error: JTAG scan chain interrogation failed: all ones".