summaryrefslogtreecommitdiff
path: root/decoders
diff options
context:
space:
mode:
authorUwe Hermann <uwe@hermann-uwe.de>2011-11-27 22:12:37 +0100
committerUwe Hermann <uwe@hermann-uwe.de>2011-11-27 22:20:01 +0100
commitc4262fd6b2f8ef540b8cc93ac61956d89062d2be (patch)
treebe2d695f573d2d5f979b990281b240068b80dea0 /decoders
parent5dd9af5bdc48c0b90512b2782bad893f76ee4a0b (diff)
downloadlibsigrokdecode-c4262fd6b2f8ef540b8cc93ac61956d89062d2be.tar.gz
libsigrokdecode-c4262fd6b2f8ef540b8cc93ac61956d89062d2be.zip
srd: i2c.py: Docstrings should use """.
This is the most commonly used and recommended method for docstrings.
Diffstat (limited to 'decoders')
-rw-r--r--decoders/i2c.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/decoders/i2c.py b/decoders/i2c.py
index 71bfb6c..2301c3c 100644
--- a/decoders/i2c.py
+++ b/decoders/i2c.py
@@ -185,19 +185,19 @@ class Decoder():
pass
def is_start_condition(self, scl, sda):
- '''START condition (S): SDA = falling, SCL = high'''
+ """START condition (S): SDA = falling, SCL = high"""
if (self.oldsda == 1 and sda == 0) and scl == 1:
return True
return False
def is_data_bit(self, scl, sda):
- '''Data sampling of receiver: SCL = rising'''
+ """Data sampling of receiver: SCL = rising"""
if self.oldscl == 0 and scl == 1:
return True
return False
def is_stop_condition(self, scl, sda):
- '''STOP condition (P): SDA = rising, SCL = high'''
+ """STOP condition (P): SDA = rising, SCL = high"""
if (self.oldsda == 0 and sda == 1) and scl == 1:
return True
return False
@@ -215,7 +215,7 @@ class Decoder():
return out
def find_address_or_data(self, scl, sda):
- '''Gather 8 bits of data plus the ACK/NACK bit.'''
+ """Gather 8 bits of data plus the ACK/NACK bit."""
out = o = []
if self.startsample == -1: