mirror of
https://github.com/wuxx/icesugar.git
synced 2025-12-29 04:32:35 +08:00
basic basic examples switched to nextpnr
This commit is contained in:
@@ -1,13 +1,27 @@
|
||||
filename = top
|
||||
pcf_file = ../../../common/io.pcf
|
||||
|
||||
ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
prog_flash:
|
||||
icesprog $(filename).bin
|
||||
@if [ -d '$(ICELINK_DIR)' ]; \
|
||||
then \
|
||||
cp $(filename).bin $(ICELINK_DIR); \
|
||||
else \
|
||||
echo "iCELink not found"; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
clean:
|
||||
rm -rf $(filename).blif $(filename).asc $(filename).bin
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
filename = hard_led
|
||||
pcf_file = ../../../common/io.pcf
|
||||
|
||||
ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$9}')
|
||||
ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
prog_flash:
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
prog_flash:
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
prog_flash:
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
#prog: #for sram
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
prog_flash:
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
prog_flash:
|
||||
|
||||
@@ -5,8 +5,13 @@ ICELINK_DIR=$(shell df | grep iCELink | awk '{print $$6}')
|
||||
${warning iCELink path: $(ICELINK_DIR)}
|
||||
|
||||
build:
|
||||
yosys -p "synth_ice40 -blif $(filename).blif" $(filename).v
|
||||
arachne-pnr -d 5k -P sg48 -p $(pcf_file) $(filename).blif -o $(filename).asc
|
||||
yosys -p "synth_ice40 -json $(filename).json" $(filename).v
|
||||
nextpnr-ice40 \
|
||||
--up5k \
|
||||
--package sg48 \
|
||||
--json $(filename).json \
|
||||
--pcf $(pcf_file) \
|
||||
--asc $(filename).asc
|
||||
icepack $(filename).asc $(filename).bin
|
||||
|
||||
#prog: #for sram
|
||||
|
||||
Reference in New Issue
Block a user