nextpnr/generic/examples/simtest.sh
David Shah 2f56b98959 generic: Add support for post-PnR simulation
Signed-off-by: David Shah <dave@ds0.me>
2019-11-27 15:17:53 +00:00

8 lines
428 B
Bash
Executable File

#!/usr/bin/env bash
set -ex
yosys -p "tcl ../synth/synth_generic.tcl 4 blinky.json" blinky.v
${NEXTPNR:-../../nextpnr-generic} --no-iobs --pre-pack simple.py --pre-place simple_timing.py --json blinky.json --post-route bitstream.py --write pnrblinky.json
yosys -p "read_json pnrblinky.json; write_verilog -noattr -norename pnrblinky.v"
iverilog -o blinky_simtest ../synth/prims.v blinky_tb.v pnrblinky.v
vvp -N ./blinky_simtest