add uart interface
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Tue, 20 Mar 2018 16:58:09 +0000 (16:58 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Tue, 20 Mar 2018 16:58:09 +0000 (16:58 +0000)
src/interface_decl.py

index 9b420e9cccc68fe00d7ff8945732979163533d91..9e0825959de57aa7ff1c9078711fcc039e900451 100644 (file)
@@ -199,3 +199,10 @@ if __name__ == '__main__':
     print
     assert pinmunge(str(spi)) == pinmunge(spiinterface_decl)
 
+    uart = Interface([{'name': 'tx_{0}', 'action': True},
+                      {'name': 'rx_{0}'},
+                    ])
+    print uart
+    print
+    assert pinmunge(str(uart)) == pinmunge(uartinterface_decl)
+