X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=decoders%2Ftransitioncounter.py;h=ded3a3d1c8361acb6f9b9e3a8066e8e0920e150c;hb=acba48696ef9dd516d2cdf90f89e099deb7e1a73;hp=5b12927bceb61f04641a5df38526d7da2930ab4a;hpb=56202222ed83ff030239bb23be8296574674c4f7;p=libsigrokdecode.git diff --git a/decoders/transitioncounter.py b/decoders/transitioncounter.py index 5b12927..ded3a3d 100644 --- a/decoders/transitioncounter.py +++ b/decoders/transitioncounter.py @@ -31,9 +31,11 @@ class Decoder(srd.Decoder): license = 'gplv2+' inputs = ['logic'] outputs = ['transitioncounts'] - probes = [ - ] # TODO? + probes = [] options = {} + annotations = [ + ['TODO', 'TODO'], + ] def __init__(self, **kwargs): self.channels = -1 @@ -46,7 +48,7 @@ class Decoder(srd.Decoder): def report(self): pass - def decode(self, timeoffset, duration, data): + def decode(self, ss, es, data): for (samplenum, s) in data: @@ -96,5 +98,5 @@ class Decoder(srd.Decoder): if outdata != []: # self.put(0, 0, self.out_proto, out_proto) - self.put(0, 0, self.out_ann, outdata) + self.put(0, 0, self.out_ann, [0, [str(outdata)]])