X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=decoders%2Fdali%2Fpd.py;h=5dd577db1affe50d49b567473e0977f2a86f4b79;hb=10aeb8ea8b183394cebc0033f048f49f4262b57d;hp=bdb3fe65bacd447d634575f853976084d05d3a55;hpb=3b44d89ee67b7dce3f6e2d7a948d94bd18d5b26c;p=libsigrokdecode.git diff --git a/decoders/dali/pd.py b/decoders/dali/pd.py index bdb3fe6..5dd577d 100644 --- a/decoders/dali/pd.py +++ b/decoders/dali/pd.py @@ -56,6 +56,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 = [], [], [] @@ -202,7 +205,7 @@ class Decoder(srd.Decoder): bit = 0 while True: # TODO: Come up with more appropriate self.wait() conditions. - (dali,) = self.wait({'skip': 1}) + (dali,) = self.wait() if self.options['polarity'] == 'active-high': dali ^= 1 # Invert.