From 743641960a61674afb7d32751752b26cc33c6ae8 Mon Sep 17 00:00:00 2001 From: Karol Gugala Date: Tue, 1 Jan 2019 21:17:55 +0100 Subject: [PATCH 1/3] minitests: roi: runme.sh: do not hardcode artix7 Signed-off-by: Karol Gugala --- minitests/roi_harness/runme.sh | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/minitests/roi_harness/runme.sh b/minitests/roi_harness/runme.sh index c69a230f..221b1f79 100755 --- a/minitests/roi_harness/runme.sh +++ b/minitests/roi_harness/runme.sh @@ -9,6 +9,16 @@ source ${XRAY_DIR}/utils/environment.sh export XRAY_PINCFG=${XRAY_PINCFG:-ARTY-A7-SWBUT} export BUILD_DIR=${BUILD_DIR:-build} +DEVICE=`expr substr $XRAY_PART 4 1` +if [ $DEVICE == "z" ] ; then + export XRAY_DEVICE=zynq7 +elif [ $DEVICE == "a" ] ; then + export XRAY_DEVICE=artix7 +else + echo "Unknown XRAY_DEVICE " $XRAY_DEVICE + exit 1 +fi + # not part of the normal DB # to generate: cat >/dev/null </dev/null +stat ${XRAY_DIR}/database/${XRAY_DEVICE}/${XRAY_PART}.yaml >/dev/null # 6x by 18y CLBs (108) if [ "$SMALL" = Y ] ; then echo "Design: small" export PITCH=1 - export DIN_N=8 - export DOUT_N=8 - export XRAY_ROI=SLICE_X12Y100:SLICE_X17Y117 + export DIN_N=${XRAY_DIN_N_SMALL:-8} + export DOUT_N=${XRAY_DOUT_N_SMALL:-8} + export XRAY_ROI=${XRAY_ROI_SMALL:-SLICE_X12Y100:SLICE_X17Y117} # All of CMT X0Y2 else echo "Design: large" export PITCH=2 - export DIN_N=17 - export DOUT_N=17 - export XRAY_ROI=SLICE_X0Y100:SLICE_X35Y149 + export DIN_N=${XRAY_DIN_N_LARGE:-8} + export DOUT_N=${XRAY_DOUT_N_LARGE:-8} + export XRAY_ROI=${XRAY_ROI_LARGE:-SLICE_X0Y100:SLICE_X35Y149} fi mkdir -p $BUILD_DIR From fe0f1f2248445c658286f07dbce2b0f8240eb6c5 Mon Sep 17 00:00:00 2001 From: Karol Gugala Date: Tue, 1 Jan 2019 21:20:52 +0100 Subject: [PATCH 2/3] minitests: roi_harness: runme.tcl add ZYBO-Z7 support Signed-off-by: Karol Gugala --- minitests/roi_harness/runme.tcl | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/minitests/roi_harness/runme.tcl b/minitests/roi_harness/runme.tcl index 29c35633..a969de5b 100644 --- a/minitests/roi_harness/runme.tcl +++ b/minitests/roi_harness/runme.tcl @@ -186,6 +186,33 @@ if {$part eq "xc7a50tfgg484-1"} { } else { error "Unsupported config $pincfg" } +} elseif {$part eq "xc7z010clg400-1"} { + if {$pincfg eq "ZYBOZ7-SWBUT"} { + # https://github.com/Digilent/digilent-xdc/blob/master/Zybo-Z7-Master.xdc + + # Slide switches and buttons + set ins "G15 P15 W13 T16" + set outs "M14 M15 G14 D18" + + # 125 MHz CLK onboard + set pin "K17" + set net2pin(clk) $pin + + # DIN + for {set i 0} {$i < $DIN_N} {incr i} { + set pin [lindex $ins $i] + set net2pin(din[$i]) $pin + } + + # DOUT + for {set i 0} {$i < $DOUT_N} {incr i} { + set pin [lindex $outs $i] + set net2pin(dout[$i]) $pin + } + + } else { + error "Unsupported config $pincfg" + } } else { error "Pins: unsupported part $part" } From 3f0e0bd8285a1bbac7c8257dd9039ad1e333591e Mon Sep 17 00:00:00 2001 From: Karol Gugala Date: Tue, 1 Jan 2019 21:22:11 +0100 Subject: [PATCH 3/3] minitests: roi_harness: add zybo Z7 settings Signed-off-by: Karol Gugala --- minitests/roi_harness/zybo.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 minitests/roi_harness/zybo.sh diff --git a/minitests/roi_harness/zybo.sh b/minitests/roi_harness/zybo.sh new file mode 100644 index 00000000..0e367950 --- /dev/null +++ b/minitests/roi_harness/zybo.sh @@ -0,0 +1,19 @@ +# XC7010-1CLG400C +export XRAY_PART=xc7z010clg400-1 +export XRAY_PINCFG=ZYBOZ7-SWBUT +export XRAY_DIN_N_LARGE=4 +export XRAY_DOUT_N_LARGE=4 + +# For generating DB +export XRAY_PIN_00="G15" +export XRAY_PIN_01="P15" +export XRAY_PIN_02="W13" +export XRAY_PIN_03="T16" +export XRAY_PIN_04="K18" +export XRAY_PIN_05="P16" +export XRAY_PIN_06="K19" + +# ROI is in top right +export XRAY_ROI_LARGE="SLICE_X22Y50:SLICE_X43Y99" + +source $XRAY_DIR/utils/environment.sh