add dual use gpio options

This commit is contained in:
Pepijn de Vos 2024-08-16 15:56:24 +02:00
parent cbb1adfa7b
commit 039be2a248
1 changed files with 6 additions and 0 deletions

View File

@ -17,6 +17,7 @@ class GowinApiculaToolchain(YosysNextPNRToolchain):
def __init__(self):
super().__init__()
self.options = {}
self.additional_cst_commands = []
def build_io_constraints(self):
@ -37,6 +38,11 @@ class GowinApiculaToolchain(YosysNextPNRToolchain):
top = self._build_name
)
# use_mspi_as_gpio and friends
for option, value in self.options.items():
if option.startswith("use_") and value:
self._packer_opts += " --" + option[4:]
YosysNextPNRToolchain.finalize(self)
# family is gowin but NextPNRWrapper needs to call 'nextpnr-himbaechel' not 'nextpnr-gowin'