From: Florent Kermarrec Date: Sat, 28 Feb 2015 22:34:57 +0000 (+0100) Subject: kx705: add programmer parameter X-Git-Tag: 24jan2021_ls180~2099^2~229 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=eb8ba145debed1c737add7bf42c0f7a6e2fe05a1;p=litex.git kx705: add programmer parameter --- diff --git a/mibuild/platforms/kc705.py b/mibuild/platforms/kc705.py index d47c627b..1a3f7b51 100644 --- a/mibuild/platforms/kc705.py +++ b/mibuild/platforms/kc705.py @@ -378,7 +378,7 @@ _connectors = [ ) ] -def Platform(*args, toolchain="vivado", **kwargs): +def Platform(*args, toolchain="vivado", programmer="xc3sprog", **kwargs): if toolchain == "ise": xilinx_platform = XilinxISEPlatform elif toolchain == "vivado": @@ -396,7 +396,12 @@ def Platform(*args, toolchain="vivado", **kwargs): xilinx_platform.__init__(self, "xc7k325t-ffg900-2", _io, crg_factory, _connectors) def create_programmer(self): - return XC3SProg("jtaghs1_fast", "bscan_spi_kc705.bit") + if programmer == "xc3sprog": + return XC3SProg("jtaghs1_fast", "bscan_spi_kc705.bit") + elif programmer == "vivado": + return VivadoProgrammer() + else: + raise ValueError("{} programmer is not supported".format(programmer)) def do_finalize(self, fragment): try: @@ -415,4 +420,5 @@ def Platform(*args, toolchain="vivado", **kwargs): self.add_platform_command("CONFIG DCI_CASCADE = \"33 32 34\";") else: self.add_platform_command("set_property DCI_CASCADE {{32 34}} [get_iobanks 33]") + return RealPlatform(*args, **kwargs)