X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=decoders%2Fdsi%2Fpd.py;h=7ce95179f9aa7f9a254793b37229ecfcd235253f;hb=d4364948d0356f0659e1777cf771ed5bfc1f2072;hp=35a122542f532dc6f1dc15347dedd8fab68a1bb4;hpb=de594dd1322a839636b086c9d9f21bfc12297d1f;p=libsigrokdecode.git diff --git a/decoders/dsi/pd.py b/decoders/dsi/pd.py index 35a1225..7ce9517 100644 --- a/decoders/dsi/pd.py +++ b/decoders/dsi/pd.py @@ -27,10 +27,11 @@ class Decoder(srd.Decoder): id = 'dsi' name = 'DSI' longname = 'Digital Serial Interface' - desc = 'DSI lighting control protocol.' + desc = 'Digital Serial Interface (DSI) lighting protocol.' license = 'gplv2+' inputs = ['logic'] - outputs = ['dsi'] + outputs = [] + tags = ['Embedded/industrial', 'Lighting'] channels = ( {'id': 'dsi', 'name': 'DSI', 'desc': 'DSI data line'}, ) @@ -51,6 +52,9 @@ class Decoder(srd.Decoder): ) def __init__(self): + self.reset() + + def reset(self): self.samplerate = None self.samplenum = None self.edges, self.bits, self.ss_es_bits = [], [], [] @@ -108,7 +112,7 @@ class Decoder(srd.Decoder): raise SamplerateError('Cannot decode without samplerate.') bit = 0 while True: - (self.dsi,) = self.wait({'skip': 1}) + (self.dsi,) = self.wait() if self.options['polarity'] == 'active-high': self.dsi ^= 1 # Invert.