From 9fd6a0cd043b759a6cee2ed27b28a93d35033f47 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Tue, 20 Mar 2018 16:57:10 +0000 Subject: [PATCH] add spi interface --- src/interface_decl.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/interface_decl.py b/src/interface_decl.py index f1a3b4e..9b420e9 100644 --- a/src/interface_decl.py +++ b/src/interface_decl.py @@ -190,3 +190,12 @@ if __name__ == '__main__': print assert pinmunge(str(twi)) == pinmunge(twiinterface_decl) + spi = Interface([{'name': 'sclk_{0}', 'action': True}, + {'name': 'mosi_{0}', 'action': True}, + {'name': 'ss_{0}', 'action': True}, + {'name': 'miso_{0}'}, + ]) + print spi + print + assert pinmunge(str(spi)) == pinmunge(spiinterface_decl) + -- 2.30.2