From e22ec2920f4b9fd3280d1128a08fcab27f57b8c8 Mon Sep 17 00:00:00 2001 From: whitequark Date: Wed, 5 Jun 2019 02:48:41 +0000 Subject: [PATCH] Typos and style fixes. NFC. --- nmigen/build/plat.py | 2 +- nmigen/vendor/lattice_ice40.py | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/nmigen/build/plat.py b/nmigen/build/plat.py index 6098b2a..43f0472 100644 --- a/nmigen/build/plat.py +++ b/nmigen/build/plat.py @@ -195,7 +195,7 @@ class TemplatedPlatform(Platform): def toolchain_prepare(self, fragment, name, **kwargs): # This notice serves a dual purpose: to explain that the file is autogenerated, - # and to incorporate + # and to incorporate the nMigen version into generated code. autogenerated = "Automatically generated by nMigen {}. Do not edit.".format(__version__) def emit_design(backend): diff --git a/nmigen/vendor/lattice_ice40.py b/nmigen/vendor/lattice_ice40.py index 5b4d7aa..bb539ef 100644 --- a/nmigen/vendor/lattice_ice40.py +++ b/nmigen/vendor/lattice_ice40.py @@ -16,7 +16,7 @@ class LatticeICE40Platform(TemplatedPlatform): Available overrides: * ``verbose``: enables logging of informational messages to standard error. - * ``read_opts``: adds options for ``read`` Yosys command. + * ``read_verilog_opts``: adds options for ``read_verilog`` Yosys command. * ``synth_opts``: adds options for ``synth_ice40`` Yosys command. * ``script_after_read``: inserts commands after ``read_ilang`` in Yosys script. * ``script_after_synth``: inserts commands after ``synth_ice40`` in Yosys script. @@ -76,9 +76,9 @@ class LatticeICE40Platform(TemplatedPlatform): """, "{{name}}_pre_pack.py": r""" # {{autogenerated}} - {% for port, frequency in platform.iter_clock_constraints() -%} + {% for port_name, frequency in platform.iter_clock_constraints() -%} {# Clock in MHz #} - ctx.addClock("{{port}}", {{frequency/1000000}}) + ctx.addClock("{{port_name}}", {{frequency/1000000}}) {% endfor%} """, } @@ -92,9 +92,9 @@ class LatticeICE40Platform(TemplatedPlatform): """, r""" {{get_tool("nextpnr-ice40")}} - {{quiet("-q")}} + {{quiet("--quiet")}} {{get_override("nextpnr_opts")|default(["--placer","heap"])|join(" ")}} - -l {{name}}.tim + --log {{name}}.tim {{platform._nextpnr_device_options[platform.device]}} --package {{platform.package|lower}} --json {{name}}.json -- 2.30.2