Add example for 5k UWG30 package

This commit is contained in:
David Shah 2018-01-14 10:45:35 +00:00
parent 4b16c3735c
commit 99857b1505
2 changed files with 39 additions and 0 deletions

View File

@ -0,0 +1,36 @@
PROJ = rgb
PIN_DEF = rgb_uwg30.pcf
DEVICE = up5k
ARACHNE = arachne-pnr
ARACHNE_ARGS =
ICEPACK = icepack
ICETIME = icetime
ICEPROG = iceprog
all: $(PROJ).bin
%.blif: %.v
yosys -p 'synth_ice40 -top top -blif $@' $<
%.asc: $(PIN_DEF) %.blif
$(ARACHNE) $(ARACHNE_ARGS) -d $(subst up,,$(subst hx,,$(subst lp,,$(DEVICE)))) -o $@ -p $^ -P uwg30
%.bin: %.asc
$(ICEPACK) $< $@
%.rpt: %.asc
$(ICETIME) -d $(DEVICE) -mtr $@ $<
prog: $(PROJ).bin
$(ICEPROG) -S $<
sudo-prog: $(PROJ).bin
@echo 'Executing prog as root!!!'
sudo $(ICEPROG) -S $<
clean:
rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean

View File

@ -0,0 +1,3 @@
set_io RGB0 A5
set_io RGB1 B5
set_io RGB2 C5