Hi Paul,

Am 18.01.2014 17:32, schrieb Paul Fertser:
Hi,

Does http://openocd.zylin.com/1884 help with this?


It's getting better, but putting
  init; ftdi_set_signal PWR_RST 1
at the end of my config file doesn't help.
I need to restart openocd to get a connection on 2nd try.

I'm using GIT Head and the stock tcl/target/ti_tms570.cfg, so I tried to hook the FTDI-reset into JTAG's post-reset event (see attached patch) and it works reliably, but I don't know if this is the right hook for that?


Thanks && best regards,
Alex
diff --git a/tcl/interface/ftdi/xds100v2.cfg b/tcl/interface/ftdi/xds100v2.cfg
index 8557baa..ebae441 100644
--- a/tcl/interface/ftdi/xds100v2.cfg
+++ b/tcl/interface/ftdi/xds100v2.cfg
@@ -8,7 +8,7 @@ interface ftdi
 ftdi_device_desc "Texas Instruments Inc.XDS100 Ver 2.0"
 ftdi_vid_pid 0x0403 0xa6d0
 
-ftdi_layout_init 0x0838 0x597b
+ftdi_layout_init 0x0038 0x597b
 ftdi_layout_signal nTRST -data 0x0010
 ftdi_layout_signal nSRST -oe 0x0100
 ftdi_layout_signal nEMU_EN -data 0x0020
@@ -16,3 +16,5 @@ ftdi_layout_signal nEMU0 -data 0x0040
 ftdi_layout_signal nEMU1 -data 0x1000
 ftdi_layout_signal PWR_RST -data 0x0800
 ftdi_layout_signal LOOPBACK -data 0x4000
+
+echo "\nInfo : to use this adapter you MUST add ``init; ftdi_set_signal PWR_RST 1'' to the end of your config file!\n"
diff --git a/tcl/target/ti_tms570.cfg b/tcl/target/ti_tms570.cfg
index 589e9d6..e9f29e7 100644
--- a/tcl/target/ti_tms570.cfg
+++ b/tcl/target/ti_tms570.cfg
@@ -33,7 +33,8 @@ if { [info exists JRC_TAPID] } {
 jtag newtap $_CHIPNAME jrc -irlen 6 -ircapture 0x1 -irmask 0x3f \
 	-expected-id $_JRC_TAPID -ignore-version
 jtag configure $_CHIPNAME.jrc -event setup "jtag tapenable $_CHIPNAME.dap"
-jtag configure $_CHIPNAME.jrc -event post-reset "runtest 100"
+# "ftdi_set_signal" is required when using FTDI driver, see ftdi/xds100v2.cfg
+jtag configure $_CHIPNAME.jrc -event post-reset "ftdi_set_signal PWR_RST 1; runtest 100"
 
 # Cortex R4 target
 set _TARGETNAME $_CHIPNAME.cpu
------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For
Critical Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today. 
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to