Remove useless _blinky.build_and_program() function.
authorwhitequark <whitequark@whitequark.org>
Sun, 4 Aug 2019 09:35:14 +0000 (09:35 +0000)
committerwhitequark <whitequark@whitequark.org>
Sun, 4 Aug 2019 09:35:14 +0000 (09:35 +0000)
nmigen_boards/_blinky.py
nmigen_boards/blackice.py
nmigen_boards/blackice_ii.py
nmigen_boards/ice40_hx1k_blink_evn.py
nmigen_boards/ice40_hx8k_b_evn.py
nmigen_boards/icestick.py
nmigen_boards/kc705.py
nmigen_boards/tinyfpga_bx.py
nmigen_boards/versa_ecp5.py
nmigen_boards/versa_ecp5_5g.py

index 87ea57bcfa1025dbe24386ff467643f99caf457f..a9bbde9e5e39aee52e6d104b6d4b84ce0686004b 100644 (file)
@@ -25,7 +25,3 @@ class Blinky(Elaboratable):
             m.d.sync += ctr.eq(ctr - 1)
 
         return m
-
-
-def build_and_program(platform_cls, **kwargs):
-    platform_cls().build(Blinky(), do_program=True, **kwargs)
index 2ec16a1dc2ea03523134070ce1390efffc3186f0..aa84d5eb073eb6e9a4858a250e6c57106081005e 100644 (file)
@@ -73,5 +73,5 @@ class BlackIcePlatform(LatticeICE40Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(BlackIcePlatform)
+    from ._blinky import Blinky
+    BlackIcePlatform().build(Blinky(), do_program=True)
index da303a9bc55b544e3ce474672c72bfd6bcff9e73..b17221c955f0745856eb6b032f9457f40ed37867 100644 (file)
@@ -75,5 +75,5 @@ class BlackIceIIPlatform(LatticeICE40Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(BlackIceIIPlatform)
+    from ._blinky import Blinky
+    BlackIceIIPlatform().build(Blinky(), do_program=True)
index 7ada8c844365494a3bec238425d73a3e33ca46c2..a3233b934820e2f743ec3a1bfdd09f0f352648a7 100644 (file)
@@ -47,5 +47,5 @@ class ICE40HX1KBlinkEVNPlatform(LatticeICE40Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(ICE40HX1KBlinkEVNPlatform)
+    from ._blinky import Blinky
+    ICE40HX1KBlinkEVNPlatform().build(Blinky(), do_program=True)
index 39b478d8207b97a89a13dd2ce98cd882ce6dc09c..31fd0137a1468a7ed2874ba8f5c39ca6953bed6b 100644 (file)
@@ -67,5 +67,5 @@ class ICE40HX8KBEVNPlatform(LatticeICE40Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(ICE40HX8KBEVNPlatform)
+    from ._blinky import Blinky
+    ICE40HX8KBEVNPlatform().build(Blinky(), do_program=True)
index bdeb11248947a549b2c814aec55800d33f06c910..dccf34c1bdb240d97594d8d1546dd2511c02eac4 100644 (file)
@@ -53,5 +53,5 @@ class ICEStickPlatform(LatticeICE40Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(ICEStickPlatform)
+    from ._blinky import Blinky
+    ICEStickPlatform().build(Blinky(), do_program=True)
index 91e4a5b8aab13eab070d9531568f838cc550d966..613c0ba883364e35aad40be14de91c377c9cd575 100644 (file)
@@ -44,5 +44,5 @@ class KC705Platform(Xilinx7SeriesPlatform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(KC705Platform)
+    from ._blinky import Blinky
+    KC705Platform().build(Blinky(), do_program=True)
index 5e272cb61b4563744a00c264856c0a2bd4d88fd5..aefddb7ad4a145e136471eac1c1eefabd00453cb 100644 (file)
@@ -50,5 +50,5 @@ class TinyFPGABXPlatform(LatticeICE40Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(TinyFPGABXPlatform)
+    from ._blinky import Blinky
+    TinyFPGABXPlatform().build(Blinky(), do_program=True)
index 4462e4d8222516a7b9e6d54ec27b34e3f76a858c..e20f8cc9c511639c9ed945d221c766a1894c5a16 100644 (file)
@@ -180,5 +180,5 @@ class VersaECP5Platform(LatticeECP5Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(VersaECP5Platform)
+    from ._blinky import Blinky
+    VersaECP5Platform().build(Blinky(), do_program=True)
index d6441f4426cee8176c883b91cd5426c9706edeae..02fa8b1844d4a68f5cc31971164012d60eb48865 100644 (file)
@@ -10,5 +10,5 @@ class VersaECP55GPlatform(VersaECP5Platform):
 
 
 if __name__ == "__main__":
-    from ._blinky import build_and_program
-    build_and_program(VersaECP55GPlatform)
+    from ._blinky import Blinky
+    VersaECP55GPlatform().build(Blinky(), do_program=True)