|
From: <jan...@ce...> - 2012-02-16 09:12:41
|
Hi,
further to my previous emails, I am sending some more info
Here is a log after I changed the speed
to 500kHz, as Spen suggested
C:\openocd-0.6.0-dev-111231122355\bin>openocd.exe -f interface/jtagkey.cfg -f ta
rget/bcm7401.cfg
Open On-Chip Debugger 0.6.0-dev-00308-g7e22576 (2011-12-31-13:49)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.sourceforge.net/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'jtag'
500 kHz
adapter_nsrst_delay: 100
jtag_ntrst_delay: 10
trst_and_srst separate srst_gates_jtag trst_push_pull srst_open_drain
Event actions for target (0) bcm7401.cpu
Event | Body
------------------------- | ----------------------------------------
***END***
Info : clock speed 500 kHz
Info : JTAG tap: bcm7401.cpu tap/device found: 0x2740117f (mfg: 0x0bf, part: 0x7
401, ver: 0x2)
Info : accepting 'telnet' connection from 4444
User : 39 11563 command.c:557 command_print(): debug_level: 3
Debug: 40 16188 command.c:151 script_debug(): command - ocd_command
ocd_command
type ocd_halt
Debug: 41 16203 command.c:151 script_debug(): command - halt ocd_halt
Debug: 43 16203 target.c:2354 handle_halt_command(): -
Debug: 44 16203 mips_m4k.c:185 mips_m4k_halt(): target->state: running
Debug: 45 16219 mips_ejtag.c:250 mips_ejtag_enter_debug(): ejtag_ctrl: 0x0020d10
0
Error: 46 16219 mips_ejtag.c:253 mips_ejtag_enter_debug(): Failed to enter Debug
Mode!
Debug: 47 16219 target.c:2333 target_wait_state(): waiting for target halted...
Info : 50 17235 target.c:468 target_poll(): Halt timed out, wake up GDB.
Debug: 51 17235 target.c:1198 target_call_event_callbacks(): target event 2 (gdb
-halt)
Error: 59 21235 target.c:2344 target_wait_state(): timed out while waiting for t
arget halted
Debug: 60 21235 command.c:638 run_command(): Command failed with error code -4
User : 61 21235 command.c:679 command_run_line(): in procedure 'halt'
Debug: 62 130547 command.c:151 script_debug(): command - ocd_command
ocd_command
type ocd_halt 100
Debug: 63 130547 command.c:151 script_debug(): command - halt ocd_halt 100
Debug: 65 130563 target.c:2354 handle_halt_command(): -
Debug: 66 130563 mips_m4k.c:185 mips_m4k_halt(): target->state: running
Debug: 67 130563 mips_ejtag.c:250 mips_ejtag_enter_debug(): ejtag_ctrl: 0x0020d1
00
Error: 68 130578 mips_ejtag.c:253 mips_ejtag_enter_debug(): Failed to enter Debu
g Mode!
Debug: 69 130578 target.c:2333 target_wait_state(): waiting for target halted...
Info : 72 131594 target.c:468 target_poll(): Halt timed out, wake up GDB.
Debug: 73 131594 target.c:1198 target_call_event_callbacks(): target event 2 (gd
b-halt)
Debug: 224 209282 mips_m4k.c:142 mips_m4k_poll(): Reset Detected
Error: 225 209297 mips32_pracc.c:242 mips32_pracc_exec_write(): Error writing un
expected address 0xffffffff
Debug: 226 209297 mips_m4k.c:858 mips_m4k_read_memory(): address: 0xff300000, si
ze: 0x00000004, count: 0x00000001
Debug: 227 209328 target.c:1741 target_read_u32(): address: 0xff300000, value: 0
xe023248b
Debug: 228 209328 mips_m4k.c:858 mips_m4k_read_memory(): address: 0xff301000, si
ze: 0x00000004, count: 0x00000001
Debug: 229 209344 target.c:1741 target_read_u32(): address: 0xff301000, value: 0
x00000000
Debug: 230 209344 target.c:1818 target_write_u32(): address: 0xff301000, value:
0x00000000
Debug: 231 209344 mips_m4k.c:925 mips_m4k_write_memory(): address: 0xff301000, s
ize: 0x00000004, count: 0x00000001
Debug: 233 209375 mips_m4k.c:858 mips_m4k_read_memory(): address: 0xff302000, si
ze: 0x00000004, count: 0x00000001
Debug: 234 209391 target.c:1741 target_read_u32(): address: 0xff302000, value: 0
x00000000
Debug: 235 209391 target.c:1818 target_write_u32(): address: 0xff302000, value:
0x00000000
Debug: 236 209391 mips_m4k.c:925 mips_m4k_write_memory(): address: 0xff302000, s
ize: 0x00000004, count: 0x00000001
Warn : 237 209407 mips32.c:565 mips32_configure_break_unit(): DCR endianness set
tings does not match target settings
Debug: 238 209422 mips32.c:569 mips32_configure_break_unit(): DCR 0xe023248b
num
inst 0 numdata 0
Error: 240 210297 mips32_pracc.c:242 mips32_pracc_exec_write(): Error writing un
expected address 0xffffffff
Debug: 241 210297 mips_m4k.c:112 mips_m4k_debug_entry(): entered debug state at
PC 0x0, target->state: halted
Debug: 242 210297 target.c:1198 target_call_event_callbacks(): target event 2 (g
db-halt)
Debug: 243 210313 target.c:1198 target_call_event_callbacks(): target event 3 (h
alted)
User : 244 210313 target.c:1475 target_arch_state(): target state: halted
User : 245 210313 mips32.c:258 mips32_arch_state(): target halted in MIPS32 mode
due to debug-request, pc: 0x00000000
Debug: 246 210328 mips_m4k.c:142 mips_m4k_poll(): Reset Detected
##################################
and here is my Telnet session
Open On-Chip Debugger
> debug_level 3
debug_level: 3
> halt
Failed to enter Debug Mode!
Halt timed out, wake up GDB.
timed out while waiting for target halted
in procedure 'halt'
> halt 100
Failed to enter Debug Mode!
Halt timed out, wake up GDB.
Error writing unexpected address 0xffffffff
DCR endianness settings does not match target settings
Error writing unexpected address 0xffffffff
target state: halted
target halted in MIPS32 mode due to debug-request, pc: 0x0000000
>
##################
ONly few comments
I used halt first( without any time) but it did not halt the target. So I used halt 100
but it caused the target to hang. So I restarted the target and that caused
text
target halted in MIPS32 mode
due to debug-request, pc: 0x00000000
see the log. I do not thik it is correct.
jtagkey.cfg looks like this
interface ft2232
ft2232_device_desc "Amontec JTAGkey"
ft2232_layout jtagkey
ft2232_vid_pid 0x0403 0xcff8
adapter_khz 500
and my CPU config is like this
set _CHIPNAME $CHIPNAME
} else {
set _CHIPNAME bcm7401
}
if { [info exists ENDIAN] } {
set _ENDIAN $ENDIAN
} else {
set _ENDIAN little
}
if { [info exists CPUTAPID] } {
set _CPUTAPID $CPUTAPID
} else {
set _CPUTAPID 0x2740117f
}
adapter_nsrst_delay 100
jtag_ntrst_delay 10
reset_config trst_and_srst separate
# jtag scan chain
# format L IRC IRCM IDCODE (Length, IR Capture, IR Capture Mask, IDCODE)
jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x2740117f
set _TARGETNAME $_CHIPNAME.cpu
target create $_TARGETNAME mips_m4k -chain-position $_CHIPNAME.cpu -endian
$_ENDIAN -variant $_TARGETNAME
$_TARGETNAME eventlist
telnet_port 4444
Or is it true OpenOCD can not be used with Broadcom CPU?
Thanks
|