]> sigrok.org Git - libsigrokdecode.git/blobdiff - decoders/xfp/pd.py
Probes, optional probes and annotations now take a tuple.
[libsigrokdecode.git] / decoders / xfp / pd.py
index 623052382ee30b80561d05deb721367b080591cf..975215ac6c7a7d5ba64dfd686c00bc9182db6223 100644 (file)
 ## along with this program; if not, see <http://www.gnu.org/licenses/>.
 ##
 
-# XFP protocol decoder
-
 import sigrokdecode as srd
-import os
 
 MODULE_ID = {
     0x01: 'GBIC',
@@ -202,13 +199,10 @@ class Decoder(srd.Decoder):
     license = 'gplv3+'
     inputs = ['i2c']
     outputs = ['xfp']
-    probes = []
-    optional_probes = []
-    options = {}
-    annotations = [
-        ['XFP field names and values', 'XFP structure field names and values'],
-        ['XFP fields', 'XFP structure fields'],
-    ]
+    annotations = (
+        ('fieldnames-and-values', 'XFP structure field names and values'),
+        ('fields', 'XFP structure fields'),
+    )
 
     def __init__(self, **kwargs):
         # Received data items, used as an index into samplenum/data