]> sigrok.org Git - libsigrokdecode.git/blobdiff - decoders/graycode/pd.py
adxl345: Use SrdIntEnum for annotation classes.
[libsigrokdecode.git] / decoders / graycode / pd.py
index 09f4a0e5e441a48e926289b9d369e0da66dc052d..f3d45abcc0d0f544a28b0125c7aacd381ddac45b 100644 (file)
@@ -77,10 +77,10 @@ class Decoder(srd.Decoder):
     id = 'graycode'
     name = 'Gray code'
     longname = 'Gray code and rotary encoder'
-    desc = 'Accumulate rotary encoder increments, provide timing statistics.'
+    desc = 'Accumulate rotary encoder increments, provide statistics.'
     license = 'gplv2+'
     inputs = ['logic']
-    outputs = ['graycode']
+    outputs = []
     tags = ['Encoding']
     optional_channels = tuple(
         {'id': 'd{}'.format(i), 'name': 'D{}'.format(i), 'desc': 'Data line {}'.format(i)}
@@ -94,12 +94,12 @@ class Decoder(srd.Decoder):
         ('phase', 'Phase'),
         ('increment', 'Increment'),
         ('count', 'Count'),
-        ('turns', 'Turns'),
+        ('turn', 'Turn'),
         ('interval', 'Interval'),
         ('average', 'Average'),
         ('rpm', 'Rate'),
     )
-    annotation_rows = tuple((u, v, (i,)) for i, (u, v) in enumerate(annotations))
+    annotation_rows = tuple((u + 's', v + 's', (i,)) for i, (u, v) in enumerate(annotations))
 
     def __init__(self):
         self.reset()