fix: Rebuild docker image using newer versions and add a Makefile.
This commit is contained in:
@@ -7,7 +7,7 @@ This directory shows how to flash a SystemVerilog program (a full-adder) on a Zy
|
||||
Firstly, the SystemVerilog file needs to be converted to verilog to use it with Yosys :
|
||||
|
||||
```bash
|
||||
podman run --mount=type=bind,source=.,target=/root/code fmn_alpine sv2v adder.sv -w adder.v
|
||||
podman run --mount=type=bind,source=.,target=/root/code localhost/fmn-toolchain sv2v adder.sv -w adder.v
|
||||
```
|
||||
|
||||
The mount parameter is used to provide the current directory to podman.
|
||||
@@ -15,20 +15,20 @@ The mount parameter is used to provide the current directory to podman.
|
||||
Then, Yosys can perform the RTL synthesis of the program :
|
||||
|
||||
```bash
|
||||
podman run --mount=type=bind,source=.,target=/root/code fmn_alpine yosys adder.v -p "synth_xilinx; write_json synthesis.json"
|
||||
podman run --mount=type=bind,source=.,target=/root/code localhost/fmn-toolchain yosys adder.v -p "synth_xilinx; write_json synthesis.json"
|
||||
```
|
||||
|
||||
Nextpnr can now place and route each component using the XDC constraints file :
|
||||
|
||||
```bash
|
||||
podman run --mount=type=bind,source=.,target=/root/code fmn_alpine nextpnr-himbaechel --json synthesis.json -o xdc=adder.xdc -o fasm=out.fasm --device xc7z010clg400-1
|
||||
podman run --mount=type=bind,source=.,target=/root/code localhost/fmn-toolchain nextpnr-himbaechel --json synthesis.json -o xdc=adder.xdc -o fasm=out.fasm --device xc7z010clg400-1
|
||||
```
|
||||
|
||||
Now the FASM file can be converted to a frames file and then to a bitstream :
|
||||
|
||||
```bash
|
||||
podman run --mount=type=bind,source=.,target=/root/code fmn_alpine fasm2frames --part xc7z010clg400-1 --db-root /usr/share/xray/database/zynq7 out.fasm out.frames
|
||||
podman run --mount=type=bind,source=.,target=/root/code fmn_alpine xc7frames2bit -frm_file out.frames -part_file /usr/share/xray/database/zynq7/xc7z010clg400-1/part.yaml --output_file out.bin
|
||||
podman run --mount=type=bind,source=.,target=/root/code localhost/fmn-toolchain fasm2frames --part xc7z010clg400-1 --db-root /usr/share/xray/database/zynq7 out.fasm out.frames
|
||||
podman run --mount=type=bind,source=.,target=/root/code localhost/fmn-toolchain xc7frames2bit -frm_file out.frames -part_file /usr/share/xray/database/zynq7/xc7z010clg400-1/part.yaml --output_file out.bin
|
||||
```
|
||||
|
||||
## Flashing the FPGA
|
||||
@@ -44,5 +44,5 @@ Bus 003 Device 005: ID 0403:6010 Future Technology Devices International, Ltd FT
|
||||
Here the usb device path is `/dev/bus/usb/003/005`
|
||||
|
||||
```bash
|
||||
podman run --device=/dev/bus/usb/003/005 --mount=type=bind,source=.,target=/root/code fmn_alpine openFPGALoader -b zybo_z7_10 out.bin
|
||||
podman run --device=/dev/bus/usb/003/005 --mount=type=bind,source=.,target=/root/code localhost/fmn-toolchain openFPGALoader -b zybo_z7_10 out.bin
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user