aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAki Van Ness <aki@lethalbit.net>2022-09-15 06:32:45 -0400
committerAki Van Ness <aki@lethalbit.net>2022-09-15 06:32:45 -0400
commitca43729f124466b816f922842353feeb3f6f8e84 (patch)
treedcb5191f0f33237ae561bfad064bd20fc397e728
parent2bc541743ada3542c6da36a50e66303b9cbd2059 (diff)
downloadicestorm-ca43729f124466b816f922842353feeb3f6f8e84.tar.gz
icestorm-ca43729f124466b816f922842353feeb3f6f8e84.tar.bz2
icestorm-ca43729f124466b816f922842353feeb3f6f8e84.zip
Replaced instances of `arachne-pnr` with the `nextpnr-ice40` equivalent
-rw-r--r--examples/hx8kboard/.gitignore9
-rw-r--r--examples/hx8kboard/Makefile11
-rw-r--r--examples/iceblink/.gitignore10
-rw-r--r--examples/iceblink/Makefile11
-rw-r--r--examples/icebreaker/.gitignore10
-rw-r--r--examples/icebreaker/Makefile15
-rw-r--r--examples/icemulti/.gitignore10
-rw-r--r--examples/icemulti/Makefile6
-rw-r--r--examples/icestick/.gitignore31
-rw-r--r--examples/icestick/Makefile15
-rw-r--r--examples/icezum/.gitignore9
-rw-r--r--examples/icezum/Makefile11
-rw-r--r--examples/up5k_rgb/.gitignore18
-rw-r--r--examples/up5k_rgb/Makefile13
-rw-r--r--examples/up5k_rgb/Makefile.uwg3012
-rw-r--r--icebram/.gitignore1
-rw-r--r--icebram/rundemo.sh4
17 files changed, 95 insertions, 101 deletions
diff --git a/examples/hx8kboard/.gitignore b/examples/hx8kboard/.gitignore
index c1fa30b..56f263f 100644
--- a/examples/hx8kboard/.gitignore
+++ b/examples/hx8kboard/.gitignore
@@ -1,4 +1,5 @@
-example.bin
-example.blif
-example.asc
-example.rpt
+*
+!.gitignore
+!example.v
+!hx8kboard.pcf
+!Makefile
diff --git a/examples/hx8kboard/Makefile b/examples/hx8kboard/Makefile
index bcecdf2..eea99c4 100644
--- a/examples/hx8kboard/Makefile
+++ b/examples/hx8kboard/Makefile
@@ -1,14 +1,15 @@
PROJ = example
PIN_DEF = hx8kboard.pcf
DEVICE = hx8k
+PACKAGE = ct256
all: $(PROJ).rpt $(PROJ).bin
-%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+%.json: %.v
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
icepack $< $@
@@ -24,7 +25,7 @@ sudo-prog: $(PROJ).bin
sudo iceprog $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean
diff --git a/examples/iceblink/.gitignore b/examples/iceblink/.gitignore
index c1fa30b..1af40d6 100644
--- a/examples/iceblink/.gitignore
+++ b/examples/iceblink/.gitignore
@@ -1,4 +1,6 @@
-example.bin
-example.blif
-example.asc
-example.rpt
+*
+!.gitignore
+!example.v
+!iceblink.pcf
+!Makefile
+!README
diff --git a/examples/iceblink/Makefile b/examples/iceblink/Makefile
index 3403a4b..a57e377 100644
--- a/examples/iceblink/Makefile
+++ b/examples/iceblink/Makefile
@@ -1,14 +1,15 @@
PROJ = example
PIN_DEF = iceblink.pcf
DEVICE = hx1k
+PACKAGE = vq100
all: $(PROJ).rpt $(PROJ).bin
-%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+%.json: %.v
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^ -P vq100
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
icepack $< $@
@@ -24,6 +25,6 @@ sudo-prog: $(PROJ).bin
iCEburn.py -e -v -w $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.PHONY: all prog clean
diff --git a/examples/icebreaker/.gitignore b/examples/icebreaker/.gitignore
index 797fcc0..a435ac9 100644
--- a/examples/icebreaker/.gitignore
+++ b/examples/icebreaker/.gitignore
@@ -1,4 +1,6 @@
-example.asc
-example.bin
-example.blif
-example.rpt
+*
+!.gitignore
+!example.v
+!icebreaker.pcf
+!Makefile
+!README
diff --git a/examples/icebreaker/Makefile b/examples/icebreaker/Makefile
index e91de63..db610ea 100644
--- a/examples/icebreaker/Makefile
+++ b/examples/icebreaker/Makefile
@@ -2,14 +2,15 @@ PROJ = example
PIN_DEF = icebreaker.pcf
DEVICE = up5k
+PACKAGE = sg48
all: $(PROJ).rpt $(PROJ).bin
-%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+%.json: %.v
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- arachne-pnr -d $(subst up,,$(subst hx,,$(subst lp,,$(DEVICE)))) -o $@ -p $^
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
icepack $< $@
@@ -23,8 +24,8 @@ all: $(PROJ).rpt $(PROJ).bin
%_tb.vcd: %_tb
vvp -N $< +vcd=$@
-%_syn.v: %.blif
- yosys -p 'read_blif -wideports $^; write_verilog $@'
+%_syn.v: %.json
+ yosys -p 'read_json $^; write_verilog $@'
%_syntb: %_tb.v %_syn.v
iverilog -o $@ $^ `yosys-config --datdir/ice40/cells_sim.v`
@@ -40,7 +41,7 @@ sudo-prog: $(PROJ).bin
sudo iceprog $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean
diff --git a/examples/icemulti/.gitignore b/examples/icemulti/.gitignore
index 5ae574e..82b6627 100644
--- a/examples/icemulti/.gitignore
+++ b/examples/icemulti/.gitignore
@@ -1,4 +1,6 @@
-/app?.asc
-/app?.bin
-/app?.blif
-/config.bin
+*
+!.gitignore
+!app?.v
+!icestick.pcf
+!Makefile
+!README
diff --git a/examples/icemulti/Makefile b/examples/icemulti/Makefile
index d8a8320..a7ce692 100644
--- a/examples/icemulti/Makefile
+++ b/examples/icemulti/Makefile
@@ -9,12 +9,12 @@ 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
+ yosys -p "synth_ice40 -top top -json $(basename $<).json" $<
+ nextpnr-ice40 --hx1k --package tq144 --asc $(basename $<).asc --pcf icestick.pcf --json $(basename $<).json
icetime -d hx1k -c 25 $(basename $<).asc
icepack $(basename $<).asc $(basename $<).bin
clean:
- rm -f app?.asc app?.bin app?.blif config.bin
+ rm -f app?.asc app?.bin app?.json config.bin
.PHONY: prog sudo-prog clean
diff --git a/examples/icestick/.gitignore b/examples/icestick/.gitignore
index c854ccc..ac0a6a4 100644
--- a/examples/icestick/.gitignore
+++ b/examples/icestick/.gitignore
@@ -1,22 +1,9 @@
-example.bin
-example.blif
-example.asc
-example.rpt
-rs232demo.bin
-rs232demo.blif
-rs232demo.asc
-rs232demo.rpt
-rs232demo_tb
-rs232demo_tb.vcd
-rs232demo_syn.v
-rs232demo_syntb
-rs232demo_syntb.vcd
-checker.bin
-checker.blif
-checker.asc
-checker.rpt
-checker_tb
-checker_tb.vcd
-checker_syn.v
-checker_syntb
-checker_syntb.vcd
+*
+!.gitignore
+!checker_tb.v
+!checker.v
+!example.v
+!icestick.pcf
+!Makefile
+!rs232demo_tb.v
+!rs232demo.v
diff --git a/examples/icestick/Makefile b/examples/icestick/Makefile
index 58f26b9..d6a649b 100644
--- a/examples/icestick/Makefile
+++ b/examples/icestick/Makefile
@@ -4,14 +4,15 @@ PROJ = example
PIN_DEF = icestick.pcf
DEVICE = hx1k
+PACKAGE = tq144
all: $(PROJ).rpt $(PROJ).bin
-%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+%.json: %.v
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
icepack $< $@
@@ -25,8 +26,8 @@ all: $(PROJ).rpt $(PROJ).bin
%_tb.vcd: %_tb
vvp -N $< +vcd=$@
-%_syn.v: %.blif
- yosys -p 'read_blif -wideports $^; write_verilog $@'
+%_syn.v: %.json
+ yosys -p 'read_json $^; write_verilog $@'
%_syntb: %_tb.v %_syn.v
iverilog -o $@ $^ `yosys-config --datdir/ice40/cells_sim.v`
@@ -46,7 +47,7 @@ sudo-prog: $(PROJ).bin
sudo iceprog $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean
diff --git a/examples/icezum/.gitignore b/examples/icezum/.gitignore
index c1fa30b..7994dc7 100644
--- a/examples/icezum/.gitignore
+++ b/examples/icezum/.gitignore
@@ -1,4 +1,5 @@
-example.bin
-example.blif
-example.asc
-example.rpt
+*
+!.gitignore
+!example.v
+!icezum.pcf
+!Makefile
diff --git a/examples/icezum/Makefile b/examples/icezum/Makefile
index cad44d2..9944b95 100644
--- a/examples/icezum/Makefile
+++ b/examples/icezum/Makefile
@@ -1,14 +1,15 @@
PROJ = example
PIN_DEF = icezum.pcf
DEVICE = hx1k
+PACKAGE = tq144
all: $(PROJ).rpt $(PROJ).bin
-%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+%.json: %.v
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- arachne-pnr -d $(subst hx,,$(subst lp,,$(DEVICE))) -o $@ -p $^
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
icepack $< $@
@@ -24,7 +25,7 @@ sudo-prog: $(PROJ).bin
sudo iceprog $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean
diff --git a/examples/up5k_rgb/.gitignore b/examples/up5k_rgb/.gitignore
index dd32bfb..348ed09 100644
--- a/examples/up5k_rgb/.gitignore
+++ b/examples/up5k_rgb/.gitignore
@@ -1,12 +1,6 @@
-*.bin
-*.blif
-*.asc
-*.rpt
-*.glb
-*.psb
-*.sdf
-*.vsb
-*.bin
-*.tmp/
-*.exp
-*.vlog
+*
+!.gitignore
+!Makefile*
+!README
+!rgb*.pcf
+!rgb.v
diff --git a/examples/up5k_rgb/Makefile b/examples/up5k_rgb/Makefile
index 51c1f72..2e7e8f2 100644
--- a/examples/up5k_rgb/Makefile
+++ b/examples/up5k_rgb/Makefile
@@ -1,20 +1,19 @@
PROJ = rgb
PIN_DEF = rgb.pcf
DEVICE = up5k
+PACKAGE = sg48
-ARACHNE = arachne-pnr
-ARACHNE_ARGS =
ICEPACK = icepack
ICETIME = icetime
ICEPROG = iceprog
all: $(PROJ).bin
-%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+%.json: %.v
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- $(ARACHNE) $(ARACHNE_ARGS) -d $(subst up,,$(subst hx,,$(subst lp,,$(DEVICE)))) -o $@ -p $^
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
$(ICEPACK) $< $@
@@ -30,7 +29,7 @@ sudo-prog: $(PROJ).bin
sudo $(ICEPROG) -S $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean
diff --git a/examples/up5k_rgb/Makefile.uwg30 b/examples/up5k_rgb/Makefile.uwg30
index b3755ff..41e776c 100644
--- a/examples/up5k_rgb/Makefile.uwg30
+++ b/examples/up5k_rgb/Makefile.uwg30
@@ -1,9 +1,9 @@
PROJ = rgb
PIN_DEF = rgb_uwg30.pcf
DEVICE = up5k
+PACKAGE = uwg30
+
-ARACHNE = arachne-pnr
-ARACHNE_ARGS =
ICEPACK = icepack
ICETIME = icetime
ICEPROG = iceprog
@@ -11,10 +11,10 @@ ICEPROG = iceprog
all: $(PROJ).bin
%.blif: %.v
- yosys -p 'synth_ice40 -top top -blif $@' $<
+ yosys -p 'synth_ice40 -top top -json $@' $<
-%.asc: $(PIN_DEF) %.blif
- $(ARACHNE) $(ARACHNE_ARGS) -d $(subst up,,$(subst hx,,$(subst lp,,$(DEVICE)))) -o $@ -p $^ -P uwg30
+%.asc: $(PIN_DEF) %.json
+ nextpnr-ice40 --$(DEVICE) --package $(PACKAGE) --asc $@ --pcf $< --json $*.json
%.bin: %.asc
$(ICEPACK) $< $@
@@ -30,7 +30,7 @@ sudo-prog: $(PROJ).bin
sudo $(ICEPROG) -S $<
clean:
- rm -f $(PROJ).blif $(PROJ).asc $(PROJ).rpt $(PROJ).bin
+ rm -f $(PROJ).json $(PROJ).asc $(PROJ).rpt $(PROJ).bin
.SECONDARY:
.PHONY: all prog clean
diff --git a/icebram/.gitignore b/icebram/.gitignore
index d329cf5..308b51a 100644
--- a/icebram/.gitignore
+++ b/icebram/.gitignore
@@ -1,5 +1,6 @@
demo.asc
demo.blif
+demo.json
demo.pcf
demo.v
demo.vvp
diff --git a/icebram/rundemo.sh b/icebram/rundemo.sh
index 4e90ea2..6917eaa 100644
--- a/icebram/rundemo.sh
+++ b/icebram/rundemo.sh
@@ -2,8 +2,8 @@
set -ex
python3 makedemo.py
-yosys -p 'synth_ice40 -blif demo.blif' demo.v
-arachne-pnr -d 8k -w demo.pcf -o demo.asc demo.blif
+yosys -p 'synth_ice40 -json demo.json' demo.v
+nextpnr-ice40 --hx8k --package bg121 --pcf-allow-unconstrained --asc demo.asc --json demo.json
./icebram -v demo_dat0.hex demo_dat1.hex < demo.asc > demo_new.asc