aboutsummaryrefslogtreecommitdiff
path: root/tcl/cpld
diff options
context:
space:
mode:
authorRobert Jordens <jordens@gmail.com>2015-07-02 23:38:53 -0600
committerSpencer Oliver <spen@spen-soft.co.uk>2015-08-06 13:14:21 +0100
commit733e8ba062de8abc5f4d655d73c2fbd8b51877b2 (patch)
treecb7c5e5f7b0560ae9fb2abedaebe4c49b34e0456 /tcl/cpld
parent804eefc25954465a35e63abc272862169dbf4b9b (diff)
downloadriscv-openocd-733e8ba062de8abc5f4d655d73c2fbd8b51877b2.zip
riscv-openocd-733e8ba062de8abc5f4d655d73c2fbd8b51877b2.tar.gz
riscv-openocd-733e8ba062de8abc5f4d655d73c2fbd8b51877b2.tar.bz2
kc705: digilent-jtag/kintex7/jtagspi board
Xilinx Kintex7 Development board with integrated Digilent JTAG-SMT1 (a.k.a. HS1) interface and a 128 MBit SPI flash. Change-Id: I9daba0a2fb2c17e04bcb37bd41872ebde25e0d2f Signed-off-by: Robert Jordens <jordens@gmail.com> Reviewed-on: http://openocd.zylin.com/2861 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Diffstat (limited to 'tcl/cpld')
-rw-r--r--tcl/cpld/xilinx-xc7.cfg57
1 files changed, 57 insertions, 0 deletions
diff --git a/tcl/cpld/xilinx-xc7.cfg b/tcl/cpld/xilinx-xc7.cfg
new file mode 100644
index 0000000..5c5b023
--- /dev/null
+++ b/tcl/cpld/xilinx-xc7.cfg
@@ -0,0 +1,57 @@
+# xilinx series 7 (artix, kintex, virtex)
+# http://www.xilinx.com/support/documentation/user_guides/ug470_7Series_Config.pdf
+
+if { [info exists CHIPNAME] } {
+ set _CHIPNAME $CHIPNAME
+} else {
+ set _CHIPNAME xc7
+}
+
+# the 4 top bits (28:31) are the die stepping/revisions. ignore it.
+jtag newtap $_CHIPNAME tap -irlen 6 -ignore-version \
+ -expected-id 0x0362D093 \
+ -expected-id 0x0362D093 \
+ -expected-id 0x0362C093 \
+ -expected-id 0x03632093 \
+ -expected-id 0x03631093 \
+ -expected-id 0x03636093 \
+ -expected-id 0x03647093 \
+ -expected-id 0x0364C093 \
+ -expected-id 0x03651093 \
+ -expected-id 0x03747093 \
+ -expected-id 0x03656093 \
+ -expected-id 0x03752093 \
+ -expected-id 0x03751093 \
+ -expected-id 0x03671093 \
+ -expected-id 0x036B3093 \
+ -expected-id 0x036B7093 \
+ -expected-id 0x036BB093 \
+ -expected-id 0x036BF093 \
+ -expected-id 0x03667093 \
+ -expected-id 0x03682093 \
+ -expected-id 0x03687093 \
+ -expected-id 0x03692093 \
+ -expected-id 0x03691093 \
+ -expected-id 0x03696093 \
+ -expected-id 0x036D5093 \
+ -expected-id 0x036D9093 \
+ -expected-id 0x036DB093
+
+pld device virtex2 $_CHIPNAME.tap 1
+
+set XC7_JSHUTDOWN 0x0d
+set XC7_JPROGRAM 0x0b
+set XC7_JSTART 0x0c
+set XC7_BYPASS 0x3f
+
+proc xc7_program {tap} {
+ global XC7_JSHUTDOWN XC7_JPROGRAM XC7_JSTART XC7_BYPASS
+ irscan $tap $XC7_JSHUTDOWN
+ irscan $tap $XC7_JPROGRAM
+ runtest 60000
+ #JSTART prevents this from working...
+ #irscan $tap $XC7_JSTART
+ runtest 2000
+ irscan $tap $XC7_BYPASS
+ runtest 2000
+}