From a5fe0af50dcf58dfbfd6e2e28cb16a8825815126 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Thu, 22 Mar 2018 04:49:52 +0000 Subject: [PATCH] rename twi to consistent naming convention --- src/interface_decl.py | 4 ++-- src/interface_def.py | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/interface_decl.py b/src/interface_decl.py index 936c77d..36a1990 100644 --- a/src/interface_decl.py +++ b/src/interface_decl.py @@ -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}, diff --git a/src/interface_def.py b/src/interface_def.py index 6e5ed70..5ea37c7 100644 --- a/src/interface_def.py +++ b/src/interface_def.py @@ -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; ''' -- 2.30.2