diff options
-rw-r--r-- | icebox/icebox.py | 94 | ||||
-rw-r--r-- | icefuzz/icecube.sh | 4 | ||||
-rw-r--r-- | icefuzz/pinloc/pinloc-1k-cb121.sh | 49 |
3 files changed, 147 insertions, 0 deletions
diff --git a/icebox/icebox.py b/icebox/icebox.py index 7380ff1..7702a00 100644 --- a/icebox/icebox.py +++ b/icebox/icebox.py @@ -1785,6 +1785,100 @@ pinloc_db = { ( "J7", 11, 0, 1), ( "J8", 12, 0, 0), ], + "1k-cb121": [ + ( "A2", 1, 17, 1), + ( "A3", 2, 17, 0), + ( "A4", 4, 17, 0), + ( "A5", 3, 17, 1), + ( "A6", 4, 17, 1), + ( "A8", 10, 17, 0), + ("A10", 12, 17, 1), + ("A11", 13, 15, 0), + ( "B1", 0, 14, 0), + ( "B3", 1, 17, 0), + ( "B4", 2, 17, 1), + ( "B5", 3, 17, 0), + ( "B8", 10, 17, 1), + ( "B9", 12, 17, 0), + ("B11", 13, 15, 1), + ( "C1", 0, 14, 1), + ( "C2", 0, 11, 1), + ( "C3", 0, 13, 1), + ( "C4", 0, 13, 0), + ( "C5", 5, 17, 0), + ( "C6", 7, 17, 0), + ( "C7", 8, 17, 1), + ( "C8", 11, 17, 0), + ( "C9", 11, 17, 1), + ("C11", 13, 14, 1), + ( "D1", 0, 10, 1), + ( "D2", 0, 11, 0), + ( "D3", 0, 9, 0), + ( "D4", 0, 12, 0), + ( "D5", 5, 17, 1), + ( "D6", 6, 17, 1), + ( "D7", 8, 17, 0), + ( "D8", 13, 12, 0), + ( "D9", 13, 13, 0), + ("D10", 13, 13, 1), + ("D11", 13, 14, 0), + ( "E2", 0, 10, 0), + ( "E3", 0, 9, 1), + ( "E4", 0, 12, 1), + ( "E5", 6, 17, 0), + ( "E6", 7, 17, 1), + ( "E7", 9, 17, 0), + ( "E8", 13, 11, 0), + ( "E9", 13, 11, 1), + ("E11", 13, 12, 1), + ( "F2", 0, 6, 1), + ( "F3", 0, 5, 1), + ( "F4", 0, 8, 1), + ( "F7", 9, 17, 1), + ( "F8", 13, 8, 1), + ( "F9", 13, 9, 0), + ("F10", 13, 9, 1), + ( "G1", 0, 6, 0), + ( "G3", 0, 5, 0), + ( "G4", 0, 8, 0), + ( "G7", 13, 6, 1), + ( "G8", 13, 7, 0), + ( "G9", 13, 7, 1), + ("G10", 13, 8, 0), + ( "H1", 0, 3, 1), + ( "H2", 0, 4, 1), + ( "H3", 0, 4, 0), + ( "H4", 4, 0, 0), + ( "H5", 4, 0, 1), + ( "H6", 10, 0, 0), + ( "H7", 13, 4, 1), + ( "H8", 13, 6, 0), + ( "H9", 13, 4, 0), + ("H10", 13, 3, 1), + ("H11", 9, 0, 1), + ( "J1", 0, 3, 0), + ( "J2", 0, 2, 0), + ( "J3", 0, 2, 1), + ( "J4", 2, 0, 1), + ( "J5", 3, 0, 0), + ( "J6", 10, 0, 1), + ( "J8", 11, 0, 0), + ( "J9", 12, 0, 1), + ("J11", 8, 0, 1), + ( "K3", 1, 0, 0), + ( "K4", 1, 0, 1), + ( "K8", 11, 0, 1), + ( "K9", 12, 0, 0), + ("K11", 9, 0, 0), + ( "L2", 2, 0, 0), + ( "L3", 3, 0, 1), + ( "L4", 5, 0, 0), + ( "L5", 5, 0, 1), + ( "L8", 7, 0, 0), + ( "L9", 6, 0, 1), + ("L10", 7, 0, 1), + ("L11", 8, 0, 0), + ], "1k-cb132": [ ( "A1", 1, 17, 1), ( "A2", 2, 17, 1), diff --git a/icefuzz/icecube.sh b/icefuzz/icecube.sh index aca08e0..b6f1d8b 100644 --- a/icefuzz/icecube.sh +++ b/icefuzz/icecube.sh @@ -99,6 +99,10 @@ case "${ICEDEV:-hx1k-tq144}" in iCEPACKAGE="CB81" iCE40DEV="iCE40LP1K" ;; + lp1k-cb121) + iCEPACKAGE="CB121" + iCE40DEV="iCE40LP1K" + ;; ul1k-cm36a) iCEPACKAGE="CM36A" iCE40DEV="iCE40UL1K" diff --git a/icefuzz/pinloc/pinloc-1k-cb121.sh b/icefuzz/pinloc/pinloc-1k-cb121.sh new file mode 100644 index 0000000..fcab0bd --- /dev/null +++ b/icefuzz/pinloc/pinloc-1k-cb121.sh @@ -0,0 +1,49 @@ +#!/bin/bash + +mkdir -p pinloc-1k-cb121 +cd pinloc-1k-cb121 + +pins=" + A2 A3 A4 A5 A6 A8 A10 A11 + B1 B3 B4 B5 B8 B9 B11 + C1 C2 C3 C4 C5 C6 C7 C8 C9 C11 + D1 D2 D3 D4 D5 D6 D7 D8 D9 D10 D11 + E2 E3 E4 E5 E6 E7 E8 E9 E11 + F2 F3 F4 F7 F8 F9 F10 + G1 G3 G4 G7 G8 G9 G10 + H1 H2 H3 H4 H5 H6 H7 H8 H9 H10 H11 + J1 J2 J3 J4 J5 J6 J8 J9 J11 + K3 K4 K8 K9 K11 + L2 L3 L4 L5 L8 L9 L10 L11 +" + +if [ $(echo $pins | wc -w) -ne 92 ]; then + echo "Incorrect number of pins:" $(echo $pins | wc -w) + exit 1 +fi + +{ + echo -n "all:" + for pin in $pins; do + id="pinloc-1k-cb121_${pin}" + echo -n " ${id}.exp" + done + echo + + for pin in $pins; do + id="pinloc-1k-cb121_${pin}" + echo "module top(output y); assign y = 0; endmodule" > ${id}.v + echo "set_io y ${pin}" >> ${id}.pcf + echo; echo "${id}.exp:" + echo " ICEDEV=lp1k-cb121 bash ../../icecube.sh ${id} > ${id}.log 2>&1" + echo " ../../../icebox/icebox_explain.py ${id}.asc > ${id}.exp.new" + echo " ! grep '^Warning: pin' ${id}.log" + echo " rm -rf ${id}.tmp" + echo " mv ${id}.exp.new ${id}.exp" + done +} > pinloc-1k-cb121.mk + +set -ex +make -f pinloc-1k-cb121.mk -j4 +python3 ../pinlocdb.py pinloc-1k-cb121_*.exp > ../pinloc-1k-cb121.txt + |