aboutsummaryrefslogtreecommitdiffstats
path: root/examples/icestick/Makefile
blob: a9b1d8bc17953c95a2bebdaa6c04f02ddcb5685e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
PROJ = example
PIN_DEF = icestick.pcf
DEVICE = 1k

all: $(PROJ).bin

%.blif: %.v
	yosys -p 'synth_ice40 -top top -blif $@' $<

%.txt: $(PIN_DEF) %.blif
	arachne-pnr -d $(DEVICE) -o $@ -p $^

%.bin: %.txt
	icepack $< $@

prog: $(PROJ).bin
	iceprog $<

clean:
	rm -f *.blif *.txt *.bin

.PHONY: all prog clean