]> sigrok.org Git - libsigrokdecode.git/blobdiff - decoders/xfp/pd.py
Backport recent changes from mainline.
[libsigrokdecode.git] / decoders / xfp / pd.py
index 27135e585a1c267a7990af2dc56469b9222bf1a6..ded76946702fd41eb285caec63f84bfb4c500505 100644 (file)
@@ -23,20 +23,24 @@ from common.plugtrx import (MODULE_ID, ALARM_THRESHOLDS, AD_READOUTS, GCS_BITS,
         ENHANCED_OPTS, AUX_TYPES)
 
 class Decoder(srd.Decoder):
-    api_version = 2
+    api_version = 3
     id = 'xfp'
     name = 'XFP'
     longname = '10 Gigabit Small Form Factor Pluggable Module (XFP)'
-    desc = 'Data structure describing display device capabilities.'
+    desc = 'XFP I²C management interface structures/protocol'
     license = 'gplv3+'
     inputs = ['i2c']
-    outputs = ['xfp']
+    outputs = []
+    tags = ['Networking']
     annotations = (
         ('fieldnames-and-values', 'XFP structure field names and values'),
         ('fields', 'XFP structure fields'),
     )
 
     def __init__(self):
+        self.reset()
+
+    def reset(self):
         # Received data items, used as an index into samplenum/data
         self.cnt = -1
         # Start/end sample numbers per data item