From 419ee0058e4ad89e1308291e6138fdfba144a252 Mon Sep 17 00:00:00 2001 From: stnolting Date: Sat, 7 Aug 2021 22:17:29 +0200 Subject: [PATCH 1/8] [setups] moved `examples/*` to `osflow/board_tops/*` * removed original examples/README.md (there was no new information in it) --- setups/examples/Makefile | 92 ------------------- setups/examples/README.md | 83 ----------------- .../neorv32_Fomu_BoardTop_Minimal.vhd | 0 .../neorv32_Fomu_BoardTop_MinimalBoot.vhd | 0 .../neorv32_Fomu_BoardTop_MixedLanguage.vhd | 0 .../neorv32_Fomu_BoardTop_UP5KDemo.vhd | 0 .../neorv32_Fomu_MixedLanguage_ClkGen.v | 0 ...eorv32_OrangeCrab_BoardTop_MinimalBoot.vhd | 0 .../neorv32_UPduino_BoardTop_MinimalBoot.vhd | 0 .../neorv32_UPduino_BoardTop_UP5KDemo.vhd | 0 .../neorv32_iCESugar_BoardTop_Minimal.vhd | 0 .../neorv32_iCESugar_BoardTop_MinimalBoot.vhd | 0 12 files changed, 175 deletions(-) delete mode 100644 setups/examples/Makefile delete mode 100644 setups/examples/README.md rename setups/{examples => osflow/board_tops}/neorv32_Fomu_BoardTop_Minimal.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_Fomu_BoardTop_MinimalBoot.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_Fomu_BoardTop_MixedLanguage.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_Fomu_BoardTop_UP5KDemo.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_Fomu_MixedLanguage_ClkGen.v (100%) rename setups/{examples => osflow/board_tops}/neorv32_OrangeCrab_BoardTop_MinimalBoot.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_UPduino_BoardTop_MinimalBoot.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_UPduino_BoardTop_UP5KDemo.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_iCESugar_BoardTop_Minimal.vhd (100%) rename setups/{examples => osflow/board_tops}/neorv32_iCESugar_BoardTop_MinimalBoot.vhd (100%) diff --git a/setups/examples/Makefile b/setups/examples/Makefile deleted file mode 100644 index cb783af6e..000000000 --- a/setups/examples/Makefile +++ /dev/null @@ -1,92 +0,0 @@ -OSFLOW := ../osflow -EXAMPLES := ../examples -TEMPLATES := ../../rtl/templates -MV := mv - -.DEFAULT_GOAL := help - -TASK := clean $(BITSTREAM) - -FOMU_REV ?= pvt -OrangeCrab_REV ?= r02-25F -UPduino_REV ?= v3 - -#ifndef BOARD -#$(error BOARD needs to be set to 'Fomu', 'iCESugar', 'UPDuino' or 'OrangeCrab' !) -#endif - -run: - $(eval TASK ?= clean $(BITSTREAM)) - $(MAKE) -C $(OSFLOW) -f common.mk \ - BOARD_SRC=$(EXAMPLES)/neorv32_$(BOARD)_BoardTop_$(DESIGN).vhd \ - TOP=neorv32_$(BOARD)_BoardTop_$(DESIGN) \ - ID=$(DESIGN) \ - $(TASK) - IMPL="$${BITSTREAM%%.*}"; for item in ".bit" ".svf"; do \ - if [ -f "$(OSFLOW)/$$IMPL$$item" ]; then \ - $(MV) "$(OSFLOW)/$$IMPL$$item" ./; \ - fi \ - done - -# Boards - -Fomu: -ifeq ($(DESIGN),Minimal) - $(eval IMEM_SRC := ../../rtl/core/neorv32_imem.vhd) -else - $(eval IMEM_SRC := devices/ice40/neorv32_imem.ice40up_spram.vhd) -endif - $(MAKE) \ - BITSTREAM=neorv32_$(BOARD)_$(FOMU_REV)_$(DESIGN).bit \ - NEORV32_MEM_SRC="${IMEM_SRC} devices/ice40/neorv32_dmem.ice40up_spram.vhd" \ - run - -iCESugar: - $(MAKE) \ - BITSTREAM=neorv32_$(BOARD)_$(DESIGN).bit \ - run - -UPduino: - $(MAKE) \ - BITSTREAM=neorv32_$(BOARD)_$(UPduino_REV)_$(DESIGN).bit \ - run - -OrangeCrab: - $(MAKE) \ - BITSTREAM=neorv32_$(BOARD)_$(OrangeCrab_REV)_$(DESIGN).bit \ - NEORV32_MEM_SRC="../../rtl/core/neorv32_imem.vhd ../../rtl/core/neorv32_dmem.vhd" \ - run - -# Designs - -Minimal: - $(MAKE) \ - DESIGN=$@ \ - DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_Minimal*.vhd \ - $(BOARD) - -MinimalBoot: - $(MAKE) \ - DESIGN=$@ \ - DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_MinimalBoot.vhd \ - $(BOARD) - -UP5KDemo: - $(MAKE) \ - DESIGN=$@ \ - DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_UP5KDemo.vhd \ - $(BOARD) - -MixedLanguage: - $(MAKE) \ - DESIGN=$@ \ - DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_Minimal*.vhd \ - NEORV32_VERILOG_SRC='devices/ice40/sb_ice40_components.v ../examples/neorv32_Fomu_MixedLanguage_ClkGen.v' \ - $(BOARD) - -# Help - -help: - @echo "Open-Source Synthesis, P&R, Routing and Bitstream Generation" - @echo "Usage: make BOARD= " - @echo "Example: make BOARD=Fomu Minimal" diff --git a/setups/examples/README.md b/setups/examples/README.md deleted file mode 100644 index 889dbe2e1..000000000 --- a/setups/examples/README.md +++ /dev/null @@ -1,83 +0,0 @@ -# Examples - -### :construction: Under Construction :construction: - -## UPduino v3.0 - -* FPGA Board: :books: [tinyVision.ai Inc. UPduino v3 FPGA Board (GitHub)](https://github.com/tinyvision-ai-inc/UPduino-v3.0/), :credit_card: buy on [Tindie](https://www.tindie.com/products/tinyvision_ai/upduino-v30-low-cost-lattice-ice40-fpga-board/) -* FPGA: Lattice iCE40 UltraPlus 5k `iCE40UP5K-SG48I` - - -### [`neorv32_UPduino_v3_BoardTop_MinimalProcessor.vhd`](https://github.com/stnolting/neorv32/blob/master/examples/neorv32_UPduino_v3_BoardTop_MinimalProcessor.vhd) - -Minimal *blinky* example. - -### [`neorv32_UPduino_v3_BoardTop_SmallProcessor.vhd`](https://github.com/stnolting/neorv32/blob/master/examples/neorv32_UPduino_v3_BoardTop_SmallProcessor.vhd) - -This example setup turns the UPduino v3.0 into an RTOS capable NEORV32 *microcontroller*, along with a set of standard peripherals like UART, TWI and SPI. - -#### Processor Configuration - -* CPU: `rv32imac_Zicsr` (reduced CPU `[m]instret` & `[m]cycle` counter width!) -* Memory: 64 kB instruction memory (internal IMEM), 64 kB data memory (internal DMEM), 4 kB bootloader ROM -* Peripherals: `GPIO`, `MTIME`, `UART0`, `SPI`, `TWI`, `PWM`, `WDT` -* Clock: 18 MHz from on-chip HF oscillator (via PLL) -* Reset: via PLL "locked" signal; "external reset" via FPGA reconfiguration (`creset_n`) -* Tested with version [`1.5.5.5`](https://github.com/stnolting/neorv32/blob/master/CHANGELOG.md) -* On-board FPGA bitstream flash storage can also be used to store/load NEORV32 application software (via the bootloader) - -#### Interface Signals - -:information_source: See [`upduino_v3.pcf`](https://github.com/stnolting/neorv32/blob/master/boards/osflow/UPduino_v3/upduino_v3.pcf) -for the FPGA pin mapping. - -| Top Entity Signal | FPGA Pin | Package Pin | Board Header Pin | -|:------------------------------|:----------:|:------------:|:-----------------| -| `flash_csn_o` (spi_cs[0]) | IOB_35B | 16 | J3-1 | -| `flash_sck_o` | IOB_34A | 15 | J3-2 | -| `flash_sdo_o` | IOB_32A | 14 | J3-3 | -| `flash_sdi_i` | IOB_33B | 17 | J3-4 | -| `gpio_i(0)` | IOB_3B_G6 | 44 | J3-9 | -| `gpio_i(1)` | IOB_8A | 4 | J3-10 | -| `gpio_i(2)` | IOB_9B | 3 | J3-11 | -| `gpio_i(3)` | IOB_4A | 48 | J3-12 | -| `gpio_o(0)` (status LED) | IOB_5B | 45 | J3-13 | -| `gpio_o(1)` | IOB_2A | 47 | J3-14 | -| `gpio_o(2)` | IOB_0A | 46 | J3-15 | -| `gpio_o(3)` | IOB_6A | 2 | J3-16 | -| - | - | - | - | -| **reconfigure FPGA** ("_reset_") | CRESET | 8 | J2-3 | -| `pwm_o(0)` (red) | RGB2 | 41 | J2-5 | -| `pwm_o(1)` (green) | RGB0 | 39 | J2-6 | -| `pwm_o(2)` (blue) | RGB1 | 40 | J2-7 | -| `twi_sda_io` | IOT_42B | 31 | J2-9 | -| `twi_scl_io` | IOT_45A_G1 | 37 | J2-10 | -| `spi_sdo_o` | IOT_44B | 34 | J2-11 | -| `spi_sck_o` | IOT_49A | 43 | J2-12 | -| `spi_csn_o` (spi_cs[1]) | IOT_48B | 36 | J2-13 | -| `spi_sdi_i` | IOT_51A | 42 | J2-14 | -| `uart_txd_o` (UART0) | IOT_50B | 38 | J2-15 | -| `uart_rxd_i` (UART0) | IOT_41A | 28 | J2-16 | - -:information_source: The TWI signals (`twi_sda_io` and `twi_scl_io`) and the reset input (`rstn_i`) require an external pull-up resistor. GPIO output 0 (`gpio_o(0)`) is used as output for a high-active status LED driven by the bootloader. - -#### FPGA Utilization - -``` -Device utilisation: - ICESTORM_LC: 5206/ 5280 98% - ICESTORM_RAM: 12/ 30 40% - SB_IO: 20/ 96 20% - SB_GB: 8/ 8 100% - ICESTORM_PLL: 1/ 1 100% - SB_WARMBOOT: 0/ 1 0% - ICESTORM_DSP: 0/ 8 0% - ICESTORM_HFOSC: 1/ 1 100% - ICESTORM_LFOSC: 0/ 1 0% - SB_I2C: 0/ 2 0% - SB_SPI: 0/ 2 0% - IO_I3C: 0/ 2 0% - SB_LEDDA_IP: 0/ 1 0% - SB_RGBA_DRV: 1/ 1 100% - ICESTORM_SPRAM: 4/ 4 100% -``` diff --git a/setups/examples/neorv32_Fomu_BoardTop_Minimal.vhd b/setups/osflow/board_tops/neorv32_Fomu_BoardTop_Minimal.vhd similarity index 100% rename from setups/examples/neorv32_Fomu_BoardTop_Minimal.vhd rename to setups/osflow/board_tops/neorv32_Fomu_BoardTop_Minimal.vhd diff --git a/setups/examples/neorv32_Fomu_BoardTop_MinimalBoot.vhd b/setups/osflow/board_tops/neorv32_Fomu_BoardTop_MinimalBoot.vhd similarity index 100% rename from setups/examples/neorv32_Fomu_BoardTop_MinimalBoot.vhd rename to setups/osflow/board_tops/neorv32_Fomu_BoardTop_MinimalBoot.vhd diff --git a/setups/examples/neorv32_Fomu_BoardTop_MixedLanguage.vhd b/setups/osflow/board_tops/neorv32_Fomu_BoardTop_MixedLanguage.vhd similarity index 100% rename from setups/examples/neorv32_Fomu_BoardTop_MixedLanguage.vhd rename to setups/osflow/board_tops/neorv32_Fomu_BoardTop_MixedLanguage.vhd diff --git a/setups/examples/neorv32_Fomu_BoardTop_UP5KDemo.vhd b/setups/osflow/board_tops/neorv32_Fomu_BoardTop_UP5KDemo.vhd similarity index 100% rename from setups/examples/neorv32_Fomu_BoardTop_UP5KDemo.vhd rename to setups/osflow/board_tops/neorv32_Fomu_BoardTop_UP5KDemo.vhd diff --git a/setups/examples/neorv32_Fomu_MixedLanguage_ClkGen.v b/setups/osflow/board_tops/neorv32_Fomu_MixedLanguage_ClkGen.v similarity index 100% rename from setups/examples/neorv32_Fomu_MixedLanguage_ClkGen.v rename to setups/osflow/board_tops/neorv32_Fomu_MixedLanguage_ClkGen.v diff --git a/setups/examples/neorv32_OrangeCrab_BoardTop_MinimalBoot.vhd b/setups/osflow/board_tops/neorv32_OrangeCrab_BoardTop_MinimalBoot.vhd similarity index 100% rename from setups/examples/neorv32_OrangeCrab_BoardTop_MinimalBoot.vhd rename to setups/osflow/board_tops/neorv32_OrangeCrab_BoardTop_MinimalBoot.vhd diff --git a/setups/examples/neorv32_UPduino_BoardTop_MinimalBoot.vhd b/setups/osflow/board_tops/neorv32_UPduino_BoardTop_MinimalBoot.vhd similarity index 100% rename from setups/examples/neorv32_UPduino_BoardTop_MinimalBoot.vhd rename to setups/osflow/board_tops/neorv32_UPduino_BoardTop_MinimalBoot.vhd diff --git a/setups/examples/neorv32_UPduino_BoardTop_UP5KDemo.vhd b/setups/osflow/board_tops/neorv32_UPduino_BoardTop_UP5KDemo.vhd similarity index 100% rename from setups/examples/neorv32_UPduino_BoardTop_UP5KDemo.vhd rename to setups/osflow/board_tops/neorv32_UPduino_BoardTop_UP5KDemo.vhd diff --git a/setups/examples/neorv32_iCESugar_BoardTop_Minimal.vhd b/setups/osflow/board_tops/neorv32_iCESugar_BoardTop_Minimal.vhd similarity index 100% rename from setups/examples/neorv32_iCESugar_BoardTop_Minimal.vhd rename to setups/osflow/board_tops/neorv32_iCESugar_BoardTop_Minimal.vhd diff --git a/setups/examples/neorv32_iCESugar_BoardTop_MinimalBoot.vhd b/setups/osflow/board_tops/neorv32_iCESugar_BoardTop_MinimalBoot.vhd similarity index 100% rename from setups/examples/neorv32_iCESugar_BoardTop_MinimalBoot.vhd rename to setups/osflow/board_tops/neorv32_iCESugar_BoardTop_MinimalBoot.vhd From a369598ba4c27b704fc8fa86f0dac7086f069aaa Mon Sep 17 00:00:00 2001 From: stnolting Date: Sat, 7 Aug 2021 22:17:53 +0200 Subject: [PATCH 2/8] [setups/osflow] re-added makefile --- setups/osflow/Makefile | 92 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 92 insertions(+) create mode 100644 setups/osflow/Makefile diff --git a/setups/osflow/Makefile b/setups/osflow/Makefile new file mode 100644 index 000000000..af7cd3ca4 --- /dev/null +++ b/setups/osflow/Makefile @@ -0,0 +1,92 @@ +OSFLOW := . +BOARD_TOPS := ./board_tops +TEMPLATES := ../../rtl/templates +MV := mv + +.DEFAULT_GOAL := help + +TASK := clean $(BITSTREAM) + +FOMU_REV ?= pvt +OrangeCrab_REV ?= r02-25F +UPduino_REV ?= v3 + +#ifndef BOARD +#$(error BOARD needs to be set to 'Fomu', 'iCESugar', 'UPDuino' or 'OrangeCrab' !) +#endif + +run: + $(eval TASK ?= clean $(BITSTREAM)) + $(MAKE) -C $(OSFLOW) -f common.mk \ + BOARD_SRC=$(BOARD_TOPS)/neorv32_$(BOARD)_BoardTop_$(DESIGN).vhd \ + TOP=neorv32_$(BOARD)_BoardTop_$(DESIGN) \ + ID=$(DESIGN) \ + $(TASK) + IMPL="$${BITSTREAM%%.*}"; for item in ".bit" ".svf"; do \ + if [ -f "$(OSFLOW)/$$IMPL$$item" ]; then \ + $(MV) "$(OSFLOW)/$$IMPL$$item" ./; \ + fi \ + done + +# Boards + +Fomu: +ifeq ($(DESIGN),Minimal) + $(eval IMEM_SRC := ../../rtl/core/neorv32_imem.vhd) +else + $(eval IMEM_SRC := devices/ice40/neorv32_imem.ice40up_spram.vhd) +endif + $(MAKE) \ + BITSTREAM=neorv32_$(BOARD)_$(FOMU_REV)_$(DESIGN).bit \ + NEORV32_MEM_SRC="${IMEM_SRC} devices/ice40/neorv32_dmem.ice40up_spram.vhd" \ + run + +iCESugar: + $(MAKE) \ + BITSTREAM=neorv32_$(BOARD)_$(DESIGN).bit \ + run + +UPduino: + $(MAKE) \ + BITSTREAM=neorv32_$(BOARD)_$(UPduino_REV)_$(DESIGN).bit \ + run + +OrangeCrab: + $(MAKE) \ + BITSTREAM=neorv32_$(BOARD)_$(OrangeCrab_REV)_$(DESIGN).bit \ + NEORV32_MEM_SRC="../../rtl/core/neorv32_imem.vhd ../../rtl/core/neorv32_dmem.vhd" \ + run + +# Designs + +Minimal: + $(MAKE) \ + DESIGN=$@ \ + DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_Minimal*.vhd \ + $(BOARD) + +MinimalBoot: + $(MAKE) \ + DESIGN=$@ \ + DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_MinimalBoot.vhd \ + $(BOARD) + +UP5KDemo: + $(MAKE) \ + DESIGN=$@ \ + DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_UP5KDemo.vhd \ + $(BOARD) + +MixedLanguage: + $(MAKE) \ + DESIGN=$@ \ + DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_Minimal*.vhd \ + NEORV32_VERILOG_SRC='devices/ice40/sb_ice40_components.v ../board_tops/neorv32_Fomu_MixedLanguage_ClkGen.v' \ + $(BOARD) + +# Help + +help: + @echo "Open-Source Synthesis, P&R, Routing and Bitstream Generation" + @echo "Usage: make BOARD= " + @echo "Example: make BOARD=Fomu Minimal" From 8a46f27b25a6cfb576d19993b79d87ebc79dfc5e Mon Sep 17 00:00:00 2001 From: stnolting Date: Sat, 7 Aug 2021 22:22:10 +0200 Subject: [PATCH 3/8] [.github] adapted "Implementation" workflow --- .github/workflows/Implementation.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/Implementation.yml b/.github/workflows/Implementation.yml index 8f44f608f..20cbc367f 100644 --- a/.github/workflows/Implementation.yml +++ b/.github/workflows/Implementation.yml @@ -48,12 +48,12 @@ jobs: - name: '🚧 Generate ${{ matrix.board }} ${{ matrix.design }} bitstream' uses: docker://ghcr.io/stnolting/neorv32/impl with: - args: make -C setups/examples BOARD=${{ matrix.board }} ${{ matrix.design }} + args: make -C setups/osflow BOARD=${{ matrix.board }} ${{ matrix.design }} - name: '📤 Upload Artifact: ${{ matrix.board }} ${{ matrix.design }} bitstream and reports' uses: actions/upload-artifact@v2 with: name: ${{ matrix.board }}-${{ matrix.design }} path: | - setups/examples/${{ matrix.bitstream }} + setups/osflow/${{ matrix.bitstream }} setups/osflow/${{ matrix.board }}/*-report.txt From e145d3c20fb24b71ad98a887e3bf8f5c429e8f3a Mon Sep 17 00:00:00 2001 From: stnolting Date: Sat, 7 Aug 2021 22:22:33 +0200 Subject: [PATCH 4/8] [setups/osflow] added new "board_top" dir to README --- setups/osflow/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/setups/osflow/README.md b/setups/osflow/README.md index fe933eddd..d259ff1c0 100644 --- a/setups/osflow/README.md +++ b/setups/osflow/README.md @@ -6,6 +6,7 @@ open source toolchains. Synthesis based on [ghdl-yosys](https://github.com/ghdl/ ## Folder Structure * `boards`: board-specific makefiles for generating bitstreams +* `board_top`: board-specific top entities (board wrappers; may include FPGA-specific modules) * `constraints`: physical constraints (mainly pin mappings) * `devices`: FPGA-specific primitives and optimized processor modules (like memories) From 7aacec16ac3bde0776096e84123451dfc249a5c6 Mon Sep 17 00:00:00 2001 From: stnolting Date: Mon, 9 Aug 2021 17:29:46 +0200 Subject: [PATCH 5/8] [setups/osflow/README] comment on "partial makefiles" --- setups/osflow/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setups/osflow/README.md b/setups/osflow/README.md index d259ff1c0..3dbce555e 100644 --- a/setups/osflow/README.md +++ b/setups/osflow/README.md @@ -5,7 +5,7 @@ open source toolchains. Synthesis based on [ghdl-yosys](https://github.com/ghdl/ ## Folder Structure -* `boards`: board-specific makefiles for generating bitstreams +* `boards`: board-specific _partial makefiles_ (used in by main makefile `Makefile`) for generating bitstreams * `board_top`: board-specific top entities (board wrappers; may include FPGA-specific modules) * `constraints`: physical constraints (mainly pin mappings) * `devices`: FPGA-specific primitives and optimized processor modules (like memories) From fc9cb6d15c9046d37f6c44ebf383bd6e43112e57 Mon Sep 17 00:00:00 2001 From: stnolting Date: Mon, 9 Aug 2021 17:30:09 +0200 Subject: [PATCH 6/8] [setups/osflow] removed obsolete variables --- setups/osflow/Makefile | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/setups/osflow/Makefile b/setups/osflow/Makefile index af7cd3ca4..247bee1e3 100644 --- a/setups/osflow/Makefile +++ b/setups/osflow/Makefile @@ -1,5 +1,3 @@ -OSFLOW := . -BOARD_TOPS := ./board_tops TEMPLATES := ../../rtl/templates MV := mv @@ -17,14 +15,14 @@ UPduino_REV ?= v3 run: $(eval TASK ?= clean $(BITSTREAM)) - $(MAKE) -C $(OSFLOW) -f common.mk \ - BOARD_SRC=$(BOARD_TOPS)/neorv32_$(BOARD)_BoardTop_$(DESIGN).vhd \ + $(MAKE) -f common.mk \ + BOARD_SRC=./board_tops/neorv32_$(BOARD)_BoardTop_$(DESIGN).vhd \ TOP=neorv32_$(BOARD)_BoardTop_$(DESIGN) \ ID=$(DESIGN) \ $(TASK) IMPL="$${BITSTREAM%%.*}"; for item in ".bit" ".svf"; do \ - if [ -f "$(OSFLOW)/$$IMPL$$item" ]; then \ - $(MV) "$(OSFLOW)/$$IMPL$$item" ./; \ + if [ -f "./$$IMPL$$item" ]; then \ + $(MV) "./$$IMPL$$item" ./; \ fi \ done From 7c6fafcb4390b8e08eac762124e6cc696069da00 Mon Sep 17 00:00:00 2001 From: stnolting Date: Mon, 9 Aug 2021 17:31:44 +0200 Subject: [PATCH 7/8] [setups/osflow] fixed verilog module path --- setups/osflow/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setups/osflow/Makefile b/setups/osflow/Makefile index 247bee1e3..d9d4cd9a0 100644 --- a/setups/osflow/Makefile +++ b/setups/osflow/Makefile @@ -79,7 +79,7 @@ MixedLanguage: $(MAKE) \ DESIGN=$@ \ DESIGN_SRC=$(TEMPLATES)/processor/neorv32_ProcessorTop_Minimal*.vhd \ - NEORV32_VERILOG_SRC='devices/ice40/sb_ice40_components.v ../board_tops/neorv32_Fomu_MixedLanguage_ClkGen.v' \ + NEORV32_VERILOG_SRC='devices/ice40/sb_ice40_components.v board_tops/neorv32_Fomu_MixedLanguage_ClkGen.v' \ $(BOARD) # Help From 9ff3e040ca0c02fa0b1e618e954f6cd8b7ef42fb Mon Sep 17 00:00:00 2001 From: stnolting Date: Sun, 15 Aug 2021 09:54:40 +0200 Subject: [PATCH 8/8] minor README edits (wip) --- setups/osflow/README.md | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) diff --git a/setups/osflow/README.md b/setups/osflow/README.md index 3dbce555e..db900c3d3 100644 --- a/setups/osflow/README.md +++ b/setups/osflow/README.md @@ -5,6 +5,7 @@ open source toolchains. Synthesis based on [ghdl-yosys](https://github.com/ghdl/ ## Folder Structure +* `.`: Main makefile (main entry point) and partial-makefiles for synthesis, place & route and bitstream generation * `boards`: board-specific _partial makefiles_ (used in by main makefile `Makefile`) for generating bitstreams * `board_top`: board-specific top entities (board wrappers; may include FPGA-specific modules) * `constraints`: physical constraints (mainly pin mappings) @@ -15,13 +16,30 @@ open source toolchains. Synthesis based on [ghdl-yosys](https://github.com/ghdl/ :construction: **TODO - Under Construction** :construction: +* local installation of the tools +* using containers + ## How To Run -:construction: **TODO - Under Construction** :construction: +The `Makefile` in this folder is the main entry point. To run the whole process of synthesis, place & route and bitstream +generation run: + +**Prototype:** +``` +make BOARD= +``` -```shell -make BOARD= +**Example:** ``` +make BOARD=Fomu Minimal +``` + +`` specifies the actual FPGA board and implicitly sets the FPGA type. The currently supported FPGA board +targets are listed in the `boards/` folder where each partial-makefile corresponds to a supported platform. + +`` is used to define the actual SoC top. Available SoCs are located in +[`rtl/templates/processor`](https://github.com/stnolting/neorv32/tree/master/rtl/templates/processor). + See https://github.com/stnolting/neorv32/blob/master/.github/workflows/Implementation.yml