aboutsummaryrefslogtreecommitdiff
path: root/nmigen_boards/fomu_pvt.py
diff options
context:
space:
mode:
authorwhitequark <whitequark@whitequark.org>2021-12-10 07:38:00 +0000
committerwhitequark <whitequark@whitequark.org>2021-12-10 08:30:37 +0000
commitb968cfade961a329c26035ef8bfdf3058e95a9f1 (patch)
tree94891b950cb0547868877027230ff09b9cb56d4a /nmigen_boards/fomu_pvt.py
parentbd7fdd379d8b28f8b542f251a11ca28297e8fd6f (diff)
Rename nMigen to Amaranth HDL.
Diffstat (limited to 'nmigen_boards/fomu_pvt.py')
-rw-r--r--nmigen_boards/fomu_pvt.py54
1 files changed, 5 insertions, 49 deletions
diff --git a/nmigen_boards/fomu_pvt.py b/nmigen_boards/fomu_pvt.py
index 1303c0c..a935008 100644
--- a/nmigen_boards/fomu_pvt.py
+++ b/nmigen_boards/fomu_pvt.py
@@ -1,51 +1,7 @@
-import os
-import subprocess
+from amaranth_boards.fomu_pvt import *
+from amaranth_boards.fomu_pvt import __all__
-from nmigen.build import *
-from nmigen.vendor.lattice_ice40 import *
-from .resources import *
-
-__all__ = ["FomuPVTPlatform"]
-
-
-class FomuPVTPlatform(LatticeICE40Platform):
- device = "iCE40UP5K"
- package = "UWG30"
- default_clk = "clk48"
- resources = [
- Resource("clk48", 0, Pins("F4", dir="i"),
- Clock(48e6), Attrs(GLOBAL=True, IO_STANDARD="SB_LVCMOS")),
-
- *LEDResources(pins="A5", invert=True, attrs=Attrs(IO_STANDARD="SB_LVCMOS")),
- RGBLEDResource(0,
- r="B5", g="A5", b="C5", invert=True,
- attrs=Attrs(IO_STANDARD="SB_LVCMOS")
- ),
-
-
- DirectUSBResource(0, d_p="A1", d_n="A2", pullup="A4",
- attrs=Attrs(IO_STANDARD="SB_LVCMOS")),
-
- *SPIFlashResources(0,
- cs_n="C1", clk="D1", copi="F1", cipo="E1",
- attrs=Attrs(IO_STANDARD="SB_LVCMOS"),
- ),
-
- Resource("touch", 0, Pins("E4")),
- Resource("touch", 1, Pins("D5")),
- Resource("touch", 2, Pins("E5")),
- Resource("touch", 3, Pins("F5")),
- ]
-
- connectors = []
-
- def toolchain_program(self, products, name):
- dfu_util = os.environ.get("DFU_UTIL", "dfu-util")
- with products.extract("{}.bin".format(name)) as bitstream_filename:
- subprocess.check_call([dfu_util, "-D", bitstream_filename])
-
-
-if __name__ == "__main__":
- from .test.blinky import *
- FomuPVTPlatform().build(Blinky(), do_program=True)
+import warnings
+warnings.warn("instead of nmigen_boards.fomu_pvt, use amaranth_boards.fomu_pvt",
+ DeprecationWarning, stacklevel=2)