rename twi to consistent naming convention
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Thu, 22 Mar 2018 04:49:52 +0000 (04:49 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Thu, 22 Mar 2018 04:49:52 +0000 (04:49 +0000)
src/interface_decl.py
src/interface_def.py

index 936c77d86d4adef2830a9d3f9389a7f3deda3f18..36a1990b6dcdf5ee1dc0b841e009c8a2c8c50451 100644 (file)
@@ -149,8 +149,8 @@ spiinterface_decl = Interface([{'name': 'spi{0}_sclk', 'action': True},
                                {'name': 'spi{0}_miso'},
                                ])
 
-twiinterface_decl = Interface([{'name': 'sda{0}', 'outen': True},
-                               {'name': 'scl{0}', 'outen': True},
+twiinterface_decl = Interface([{'name': 'twi{0}_sda', 'outen': True},
+                               {'name': 'twi{0}_scl', 'outen': True},
                                ])
 
 sdinterface_decl = Interface([{'name': 'sd{0}_clk', 'action': True},
index 6e5ed707515c7304c27537a9b23f0d79dc05a626..5ea37c7aa58fa738f56d8dc4886fbe00fb7f1edd 100644 (file)
@@ -38,21 +38,21 @@ spiinterface_def = '''
 
 twiinterface_def = '''
 
-      method Action sda{0}_out (Bit#(1) in);
+      method Action twi{0}_sda_out (Bit#(1) in);
          wrtwi{0}_sda_out<=in;
       endmethod
-      method Action sda{0}_outen (Bit#(1) in);
+      method Action twi{0}_sda_outen (Bit#(1) in);
          wrtwi{0}_sda_outen<=in;
       endmethod
-      method sda{0}_in=wrtwi{0}_sda_in;
+      method twi{0}_sda_in=wrtwi{0}_sda_in;
 
-      method Action scl{0}_out (Bit#(1) in);
+      method Action twi{0}_scl_out (Bit#(1) in);
          wrtwi{0}_scl_out<=in;
       endmethod
-      method Action scl{0}_outen (Bit#(1) in);
+      method Action twi{0}_scl_outen (Bit#(1) in);
          wrtwi{0}_scl_outen<=in;
       endmethod
-      method scl{0}_in=wrtwi{0}_scl_in;
+      method twi{0}_scl_in=wrtwi{0}_scl_in;
 
 '''