aboutsummaryrefslogtreecommitdiffstats
path: root/examples/icemulti/Makefile
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2017-09-14 19:09:52 +0200
committerClifford Wolf <clifford@clifford.at>2017-09-14 19:09:52 +0200
commit5c4d4db08d39673b98ce953f1ab1d1368eeb2f44 (patch)
tree4f449b7cf9b88b48156ee503f14d486845b8bbdb /examples/icemulti/Makefile
parentd0f5b2ee8efd4c6babab101f68087f8339138317 (diff)
downloadicestorm-5c4d4db08d39673b98ce953f1ab1d1368eeb2f44.tar.gz
icestorm-5c4d4db08d39673b98ce953f1ab1d1368eeb2f44.tar.bz2
icestorm-5c4d4db08d39673b98ce953f1ab1d1368eeb2f44.zip
Add icemulti example
Diffstat (limited to 'examples/icemulti/Makefile')
-rw-r--r--examples/icemulti/Makefile20
1 files changed, 20 insertions, 0 deletions
diff --git a/examples/icemulti/Makefile b/examples/icemulti/Makefile
new file mode 100644
index 0000000..d8a8320
--- /dev/null
+++ b/examples/icemulti/Makefile
@@ -0,0 +1,20 @@
+prog: config.bin
+ sudo iceprog config.bin
+
+sudo-prog: config.bin
+ @echo 'Executing prog as root!!!'
+ sudo iceprog config.bin
+
+config.bin: app0.bin app1.bin app2.bin app3.bin
+ icemulti -v -A16 -p0 -o config.bin app0.bin app1.bin app2.bin app3.bin
+
+app%.bin: app%.v icestick.pcf
+ yosys -p "synth_ice40 -top top -blif $(basename $<).blif" $<
+ arachne-pnr -o $(basename $<).asc -d 1k -P tq144 -p icestick.pcf $(basename $<).blif
+ icetime -d hx1k -c 25 $(basename $<).asc
+ icepack $(basename $<).asc $(basename $<).bin
+
+clean:
+ rm -f app?.asc app?.bin app?.blif config.bin
+
+.PHONY: prog sudo-prog clean