[ABANDONED] Guessing TRST - meaning of printouts during halt

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [ABANDONED] Guessing TRST - meaning of printouts during halt

    I'm trying to connect to a board with 2 unknown chips (Segger tells me they have an ARM7 and ARM9 core) and an unusual 10 pin header where I only know the position of TMS, TDI, TCK, TDO, GND and VREF. I've connected these pins to the JLINK EDU, and am guessing the location of TRST.

    I want to halt the processor and read memory. With most guesses of TRST I'm able to connect, but cannot halt as follows:

    J-Link>halt
    Using DBGRQ to halt CPU
    Resetting TRST in order to halt CPU

    ****** Error: Unable to halt CPU core
    J-Link>go

    ****** Error: CPU is not halted


    However, with 2 guesses I get "Cannot connect to target," but halting seems to do something. The output of that is below. In no case can I ever read memory.

    Does anyone have a sense of which is correct - could the TRST guesses where I "cannot connect" but can halt be right? What do the different printouts for the not connected guesses mean?

    _____
    Guess 1:

    Device>ARM7
    Please specify target interface:
    J) JTAG (Default)
    TIF>j
    Device position in JTAG chain (IRPre,DRPre) <Default>: -1,-1 => Auto-detect
    JTAGConf>
    Specify target interface speed [kHz]. <Default>: 4000 kHz
    Speed>1000
    Device "ARM7" selected.


    Connecting to target via JTAG
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF00000000000011
    Cannot connect to target.
    J-Link>h
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    PC: (R15) = 00000000, CPSR = 00000000 (Unknown mode, ARM)
    Current:
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    R0 =00000000, R1 =00000000, R2 =00000000, R3 =00000000
    R4 =00000000, R5 =00000000, R6 =00000000, R7 =00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    USR: R8 =00000000, R9 =00000000, R10=00000000, R11=00000000, R12=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    R13=00000000, R14=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    FIQ: R8 =00000000, R9 =00000000, R10=00000000, R11=00000000, R12=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF00000000000011
    R13=00000000, R14=00000000, SPSR=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    IRQ: R13=00000000, R14=00000000, SPSR=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    SVC: R13=00000000, R14=00000000, SPSR=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    ABT: R13=00000000, R14=00000000, SPSR=00000000
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011
    UND: R13=00000000, R14=00000000, SPSR=00000000
    J-Link>go
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFE0000000000011
    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFFC0000000000011


    _____
    Guess 2:

    J-Link>con
    Please specify device / core. <Default>: ARM7
    Type '?' for selection dialog
    Device>ARM7
    Please specify target interface:
    J) JTAG (Default)
    TIF>J
    Device position in JTAG chain (IRPre,DRPre) <Default>: -1,-1 => Auto-detect
    JTAGConf>
    Specify target interface speed [kHz]. <Default>: 4000 kHz
    Speed>1000
    Device "ARM7" selected.


    Connecting to target via JTAG
    Cannot connect to target.
    J-Link>h
    PC: (R15) = 00000000, CPSR = 00000000 (Unknown mode, ARM)
    Current:
    R0 =00000000, R1 =00000000, R2 =00000000, R3 =00000000
    R4 =00000000, R5 =00000000, R6 =00000000, R7 =00000000
    USR: R8 =00000000, R9 =00000000, R10=00000000, R11=00000000, R12=00000000
    R13=00000000, R14=00000000
    FIQ: R8 =00000000, R9 =00000000, R10=00000000, R11=00000000, R12=00000000
    R13=00000000, R14=00000000, SPSR=00000000
    IRQ: R13=00000000, R14=00000000, SPSR=00000000
    SVC: R13=00000000, R14=00000000, SPSR=00000000
    ABT: R13=00000000, R14=00000000, SPSR=00000000
    UND: R13=00000000, R14=00000000, SPSR=00000000
    J-Link>go
  • Hi,


    2 unknown chips (Segger tells me they have an ARM7 and ARM9 core

    To what output message of which application do you refer?

    TotalIRLen = ?, IRPrint = 0x..FFFFFFFFFF80000000000011

    This output indicates that J-Link did write a test pattern to TDI, but did never received it via TDO.
    This could be caused by one of the following:
    -> TDI and / or TDO not wired correctly
    -> Debug interface is disabled on the target
    -> VTRef not connected correctly (What voltage does J-Link Commander show?)
    -> Target does not support JTAG

    When using Guess 2, do you get a valid output for TotalIRLen / IRPrint ?

    Best regards,
    Niklas
    Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
    Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
    Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
    Notification for Embedded Studio: Link
  • Hi,

    The message which tells me the types of chips is this, when I am able to connect:
    #0 Id: 0x4F1F002F, IRLen: 04, ARM7TDMI-S Core
    #1 Id: 0x1594602F, IRLen: 04, ARM946E-S Core

    I think you're right - I had VREF on the wrong pin, because previously it said VTref is 2.549 and it should be 3.3V. With guess 2 (and the wrong VREF, I think now) I was unable to connect and so didn't see IRLEN or IRPRINT.

    With VREF on the 3.3V pin, none of the other available guesses for TRST are able to halt it.

    I just get the following (below). Any ideas how I can halt this thing?

    Thanks.

    SEGGER J-Link Commander V6.16j (Compiled Jul 24 2017 18:43:04)
    DLL version V6.16j, compiled Jul 24 2017 18:42:55

    Connecting to J-Link via USB...O.K.
    Firmware: J-Link ARM V8 compiled Nov 28 2014 13:44:46
    Hardware version: V8.00
    S/N: 268005650
    License(s): FlashBP, GDB
    OEM: SEGGER-EDU
    VTref = 3.345V


    Type "connect" to establish a target connection, '?' for help
    J-Link>con
    Please specify device / core. <Default>: ARM7
    Type '?' for selection dialog
    Device>ARM7
    Please specify target interface:
    J) JTAG (Default)
    TIF>j
    Device position in JTAG chain (IRPre,DRPre) <Default>: -1,-1 => Auto-detect
    JTAGConf>
    Specify target interface speed [kHz]. <Default>: 4000 kHz
    Speed>1000
    Device "ARM7" selected.


    Connecting to target via JTAG
    TotalIRLen = 8, IRPrint = 0x0011
    JTAG chain detection found 2 devices:
    #0 Id: 0x4F1F002F, IRLen: 04, ARM7TDMI-S Core
    #1 Id: 0x1594602F, IRLen: 04, ARM946E-S Core

    **************************
    WARNING: The selected device is not JTAG compliant (IEEE Std 1149.1, 7.1.1.d, IR-cells). (Expected: 0x1, Found: 0x3)

    **************************

    ARM7 identified.
    ETM V1.2: 1 pairs addr.comp, 0 data comp, 4 MM decs, 1 counters
    J-Link>h
    Using DBGRQ to halt CPU
    Resetting TRST in order to halt CPU

    ****** Error: Unable to halt CPU core
    J-Link>g

    ****** Error: CPU is not halted
  • Hi,


    1000 kHz fixed interface speed is probably too much for the ARM7TDMI-S Core.
    You either can use a low speed (4 - 50 kHz) or try adaptive clocking.

    Best regards,
    Niklas
    Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
    Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
    Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
    Notification for Embedded Studio: Link
  • Thanks for this. I tried halting with "halt" and "rx 0" with all the 3 candidate TRST pins, with speeds of 4, 5, 15, 25, 35, 45, 50. None of them succeeded - the output is below. Adaptive clocking results in: "****** Error: JTAG Timeout during adaptive clocking: RTCK did not respond.
    Cannot connect to target."

    Is having only TMS, TDI, TCK, TDO, VREF and possibly TRST connected enough to halt the CPU? I have nothing on the Segger's DBGRQ or RESET pins.

    Here's the output:

    SEGGER J-Link Commander V6.16j (Compiled Jul 24 2017 18:43:04)
    DLL version V6.16j, compiled Jul 24 2017 18:42:55

    Connecting to J-Link via USB...O.K.
    Firmware: J-Link ARM V8 compiled Nov 28 2014 13:44:46
    Hardware version: V8.00
    S/N: 268005650
    License(s): FlashBP, GDB
    OEM: SEGGER-EDU
    VTref = 3.345V


    Type "connect" to establish a target connection, '?' for help
    J-Link>con
    Please specify device / core. <Default>: ARM7
    Type '?' for selection dialog
    Device>ARM7
    Please specify target interface:
    J) JTAG (Default)
    TIF>j
    Device position in JTAG chain (IRPre,DRPre) <Default>: -1,-1 => Auto-detect
    JTAGConf>
    Specify target interface speed [kHz]. <Default>: 4000 kHz
    Speed>4
    Device "ARM7" selected.


    Connecting to target via JTAG
    TotalIRLen = 8, IRPrint = 0x0011
    JTAG chain detection found 2 devices:
    #0 Id: 0x4F1F002F, IRLen: 04, ARM7TDMI-S Core
    #1 Id: 0x1594602F, IRLen: 04, ARM946E-S Core

    **************************
    WARNING: The selected device is not JTAG compliant (IEEE Std 1149.1, 7.1.1.d, IR-cells). (Expected: 0x1, Found: 0x3)

    **************************

    ARM7 identified.
    ETM V1.2: 1 pairs addr.comp, 0 data comp, 4 MM decs, 1 counters
    J-Link>h
    Using DBGRQ to halt CPU
    Resetting TRST in order to halt CPU

    ****** Error: Unable to halt CPU core
    J-Link>g

    ****** Error: CPU is not halted
    J-Link>rx 0
    Reset delay: 0 ms
    Reset type NORMAL: Using RESET pin, halting CPU after Reset

    **************************
    WARNING: The selected device is not JTAG compliant (IEEE Std 1149.1, 7.1.1.d, IR-cells). (Expected: 0x1, Found: 0x3)

    **************************

    Core does not stop after Reset, setting WP to stop it.
    Failed to halt CPU core after Reset (BP@0), using default reset strategy.

    **************************
    WARNING: The selected device is not JTAG compliant (IEEE Std 1149.1, 7.1.1.d, IR-cells). (Expected: 0x1, Found: 0x3)

    **************************

    Resetting target using RESET pin
    Halting CPU core
    Using DBGRQ to halt CPU
    Resetting TRST in order to halt CPU
    Resetting target using RESET pin
    Halting CPU core
    Using DBGRQ to halt CPU
    Resetting TRST in order to halt CPU

    ****** Error: Unable to halt CPU core
  • Hi,

    Error: JTAG Timeout during adaptive clocking: RTCK did not respond.
    Cannot connect to target."

    The RTCK pin (pin 11) needs to be connected in order to use adaptive clocking.
    I have nothing on the Segger's DBGRQ or RESET pins.

    J-Link does not use the DBGRQ pin, it accesses DBGRQ via the ICE registers.
    You should connect the nRESET pin if possible.


    You do not have more information about the target? Name, vendor, schematics?

    Best regards,
    Niklas
    Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
    Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
    Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
    Notification for Embedded Studio: Link