]> sigrok.org Git - libsigrokdecode.git/blobdiff - decoders/parallel/pd.py
Change PD options to be a tuple of dictionaries.
[libsigrokdecode.git] / decoders / parallel / pd.py
index b2903d20e4b41425a4edc2163d990f095d1ee0e8..8f2176c70e8988c439246fdf2f44f670710a9457 100644 (file)
@@ -72,12 +72,14 @@ class Decoder(srd.Decoder):
     outputs = ['parallel']
     probes = []
     optional_probes = probe_list(8)
-    options = {
-        'clock_edge': ['Clock edge to sample on', 'rising'],
-        'wordsize': ['Word size of the data', 1],
-        'endianness': ['Endianness of the data', 'little'],
-        'format': ['Data format', 'hex'],
-    }
+    options = (
+        {'id': 'clock_edge', 'desc': 'Clock edge to sample on',
+            'default': 'rising', 'values': ('rising', 'falling')},
+        {'id': 'wordsize', 'desc': 'Word size of the data',
+            'default': 1},
+        {'id': 'endianness', 'desc': 'Endianness of the data',
+            'default': 'little', 'values': ('little', 'big')},
+    )
     annotations = [
         ['items', 'Items'],
         ['words', 'Words'],