I am currently trying to learn the in’s and out’s of EJTAG debugging and am trying to use my Dominio PI for such activities. Currently my configuration consists of the Shikra board, openOCD, and the Domino PI with the SPI/JTAG board (I added pins to the exposed JTAG headers and used a DVM to test all connections). The problem that I am having is that I can never get an active connection, openOCD always says this:
Open On-Chip Debugger 0.10.0+dev-00001-g0ecee83 (2017-02-03-21:13)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
adapter speed: 2000 kHz
ar9331.cpu
Info : clock speed 2000 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: ar9331.cpu: IR capture error; saw 0x1f not 0x01
Warn : Bypassing JTAG setup events due to errors
and when I press SW1 it responds with:
target halted in MIPS32 mode due to undefined, pc: 0x00000000
On the telnet side I see this:
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Open On-Chip Debugger
> halt
Failed to enter Debug Mode!
Halt timed out, wake up GDB.
timed out while waiting for target halted
target halted in MIPS32 mode due to debug-request, pc: 0x00000000
For the openOCD cfg file I am using the one shown on the shikra website:
#shikra.cfg
interface ftdi
ftdi_vid_pid 0x0403 0x6014
ftdi_layout_init 0x0c08 0x0f1b
adapter_khz 2000
#
# ADDED BY ME
#
transport select jtag
source [find target/atheros_ar9331.cfg]
#end shikra.cfg
Since this is my first time messing with JTAG on a MIPS processor I am unsure of what I am doing wrong. Has anyone been able to get an active JTAG connection and if so could you perhaps point out what I am doing worng?
tried a lot of times before. It connects but I cannot recover the uboot using jtag. So gave up and didn’t try later
Thanks for the update and I am sorry to hear that you were not able to accomplish the recovery.
So far by pulling GPIO11 up (using a 10k ohm resistor) and pulling GPIO01 down (again with the 10K ohm) I was able to get the UART terminal
to read:
Hornet USB booting...
VID=0xcf3,PID=0x9330
iManufacturer=0x10,iProduct=0x20,iSerialNumber=0x30
bMaxPower=0xfa
-> COLD_START
bUSBPhyBias=0x3
RUN
Default State
HS
HS
HS
HS
HS
but the JTAG connection terminal still shows errors:
`Open On-Chip Debugger 0.10.0+dev-00001-g0ecee83 (2017-02-03-21:13)
Licensed under GNU GPL v2
For bug reports, read OpenOCD: Bug Reporting
adapter speed: 2000 kHz
ar9331.cpu
Info : clock speed 2000 kHz
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: ar9331.cpu: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
’
So far trying to JTAG the ar9331 has proven to be very difficult to figure out. Makes we wonder how the designers were able to JTAG the MCU and what tools they were using (hint…hint…developers…can you throw me a bone here?)
If anyone else has any ideas hear I would greatly appreciate them!
Thanks for the example on how you did it in the past. When I try with my SEGGER JLINK EDU (using the same cmd line you listed) here is what I get (my other posts were from using my Shikra board)
Open On-Chip Debugger 0.10.0+dev-00001-g0ecee83 (2017-02-03-21:13)
Licensed under GNU GPL v2
For bug reports, read http://openocd.org/doc/doxygen/bugs.html
Info : auto-selecting first available session transport “jtag”. To override use ‘transport select <transport>’.
ar9331.cpu
Info : No device selected, using first device.
Info : J-Link V9 compiled Dec 21 2015 09:38:47
Info : Hardware version: 9.30
Info : VTarget = 2.695 V
Error: JTAG I/O operation failed: 0x1.
Error: jaylink_jtag_io() failed: JAYLINK_ERR_DEV.
Error: An adapter speed is not selected in the init script. Insert a call to adapter_khz or jtag_rclk to proceed.
;----------
Could you tell me what the contents of your ar9331.cfg is as I can not figure out what I am doing wrong (have tested all connections with a DVM so I know the solder job on the JTAG headers are good) Also, my pin usage for both the JLINK and the Domino pi is:
Domino Pi JTAG Header Pin # JLINK Header Pin Number
Darn. Nothing seems to work for this! I tried the attached cfg file and this is all I get:
Trying 127.0.0.1…
Connected to localhost.
Escape character is ‘^]’.
Open On-Chip Debugger
> reset
TAP ar9331.cpu does not have IDCODE
ar9331.cpu: IR capture error; saw 0x11 not 0x01
Bypassing JTAG setup events due to errors
> reset init
TAP ar9331.cpu does not have IDCODE
ar9331.cpu: IR capture error; saw 0x11 not 0x01
Bypassing JTAG setup events due to errors
timed out while waiting for target halted
TARGET: ar9331.cpu - Not halted
in procedure ‘reset’
in procedure ‘ocd_bouncer’
Halt timed out, wake up GDB.
and on the openOCD side:
sudo openocd -f interface/jlink.cfg -f ar9331.cfg
Open On-Chip Debugger 0.10.0+dev-00001-g0ecee83 (2017-02-03-21:13)
Licensed under GNU GPL v2
For bug reports, read OpenOCD: Bug Reporting
adapter_nsrst_delay: 100
Info : auto-selecting first available session transport “jtag”. To override use ‘transport select <transport>’.
jtag_ntrst_delay: 100
adapter speed: 600 kHz
none separate
131072
Info : No device selected, using first device.
Info : J-Link V9 compiled Dec 21 2015 09:38:47
Info : Hardware version: 9.30
Info : VTarget = 0.000 V
Info : clock speed 600 kHz
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: ar9331.cpu: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
Info : accepting ‘telnet’ connection on tcp/4444
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: ar9331.cpu: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
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: ar9331.cpu: IR capture error; saw 0x00 not 0x01
Warn : Bypassing JTAG setup events due to errors
Error: timed out while waiting for target halted
TARGET: ar9331.cpu - Not halted
in procedure ‘reset’
in procedure ‘ocd_bouncer’
;----------
I even removed the SPI/JTAG board and connect straight to the header on the actual Domino PI board.
JTAG is finally up-and-running. Looks like there is an issue with the system I was using at home as when I brought it into work everything went off without any issues.
Hi…i am a new user here. As per my observation i am not getting how you connect. Here is what I have tried long time before.I can connect to JTAG without problems. I am not sure which device you use though.I can load uboot to the RAM and resume it.