nandring
661 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/sh -x
if [ "$ROOT" = "" ]; then
echo "Please specified the ROOT "
exit
fi
usage()
{
echo "Usage: dc [-g]"
echo " Generate nandring test vector"
echo " -g use gate_level simulate instead"
}
GATE=0
while getopts "g?" a
do
case $a in
g) GATE=1;;
*) usage;;
esac
done
cd ${ROOT}/PR/hw2/chip/vsim
rm -f verilog.dump
rm -f dump.v
cp -f dump.v.padio dump.v
make clean
export SIMDEFS="+nospecify +define+TEST_VECTORS +define+NANDRING"
if [ "$GATE" = "1" ]; then
export SIMGATE=1
else
export SIMGATE=""
fi
make
./sim.v +sysclk=200000 +usbclk=200000 +vclk=200000 +delay_mode_zero +non_clk_mon