Build FPGA for the uwg30 wcsp package

Signed-off-by: Joachim Strömbergson <joachim@assured.se>
This commit is contained in:
Joachim Strömbergson 2023-12-21 13:49:58 +01:00 committed by dehanj
parent fcccee8ec8
commit bec34f0b11
No known key found for this signature in database
GPG Key ID: 3707A9DBF4BB8F1A
3 changed files with 47 additions and 12 deletions

View File

@ -26,7 +26,7 @@ ICESTORM_PATH ?=
# bits wide; an EBR is 128 32-bits words)
BRAM_FW_SIZE ?= 1536
PIN_FILE ?= application_fpga_tk1.pcf
PIN_FILE ?= application_fpga_tk1_uwg30.pcf
SIZE ?= llvm-size
OBJCOPY ?= llvm-objcopy
@ -221,7 +221,7 @@ synth.json: $(FPGA_SRC) $(VERILOG_SRCS) bram_fw.hex $(P)/data/uds.hex $(P)/data/
$(filter %.v, $^)
application_fpga.asc: synth.json $(P)/data/$(PIN_FILE)
$(NEXTPNR_PATH)nextpnr-ice40 --ignore-loops --up5k --package sg48 --json $< \
$(NEXTPNR_PATH)nextpnr-ice40 --ignore-loops --up5k --package uwg30 --json $< \
--pcf $(P)/data/$(PIN_FILE) --asc $@
application_fpga.bin: application_fpga.asc bram_fw.hex firmware.hex
@ -291,7 +291,7 @@ check-hardware:
# Post build analysis.
#-------------------------------------------------------------------
timing: application_fpga.asc $(P)/data/$(PIN_FILE)
$(ICESTORM_PATH)icetime -c 18 -tmd up5k -P sg48 -p $(P)/data/$(PIN_FILE) -t $<
$(ICESTORM_PATH)icetime -c 18 -tmd up5k -P uwg30 -p $(P)/data/$(PIN_FILE) -t $<
view: tb_application_fpga_vcd
gtkwave $< application_fpga.gtkw

View File

@ -0,0 +1,40 @@
#=======================================================================
#
# application_fpga_tk1_uwg30.pcf
# ------------------------------
# Pin constraints file for the Application FPGA design to be used
# on the tk1 board with the CH552 MCU used as a USB-serial chip.
# This version targets the UWG30 package.
#
#
# Copyright (C) 2022 - Tillitis AB
# SPDX-License-Identifier: GPL-2.0-only
#
#=======================================================================
# UART.
set_io interface_rx A2
set_io interface_tx A1
# set_io interface_cts 27
# set_io interface_rts 28
# Touch sense.
set_io touch_event B1
# GPIOs.
#set_io app_gpio1 36
#set_io app_gpio2 38
#set_io app_gpio3 45
#set_io app_gpio4 46
# LEDs
set_io led_r A5
set_io led_b B5
set_io led_g C5
#=======================================================================
# EOF application_fpga_tk1_uwg30.pcf
#=======================================================================

View File

@ -22,11 +22,6 @@ module application_fpga(
input wire touch_event,
input wire app_gpio1,
input wire app_gpio2,
output wire app_gpio3,
output wire app_gpio4,
output wire led_r,
output wire led_g,
output wire led_b
@ -333,10 +328,10 @@ module application_fpga(
.led_g(led_g),
.led_b(led_b),
.gpio1(app_gpio1),
.gpio2(app_gpio2),
.gpio3(app_gpio3),
.gpio4(app_gpio4),
.gpio1(),
.gpio2(),
.gpio3(),
.gpio4(),
.cs(tk1_cs),
.we(tk1_we),