diff options
Diffstat (limited to 'decoders')
-rw-r--r-- | decoders/can/pd.py | 4 | ||||
-rw-r--r-- | decoders/lm75/pd.py | 5 | ||||
-rw-r--r-- | decoders/onewire_link/pd.py | 27 | ||||
-rw-r--r-- | decoders/parallel/pd.py | 5 | ||||
-rw-r--r-- | decoders/spi/pd.py | 4 | ||||
-rw-r--r-- | decoders/usb_packet/pd.py | 3 |
6 files changed, 20 insertions, 28 deletions
diff --git a/decoders/can/pd.py b/decoders/can/pd.py index 51b7a72..af8168c 100644 --- a/decoders/can/pd.py +++ b/decoders/can/pd.py @@ -33,8 +33,8 @@ class Decoder(srd.Decoder): {'id': 'can_rx', 'name': 'CAN RX', 'desc': 'CAN bus line'}, ) options = ( - {'id': 'bitrate', 'desc': 'Bitrate', 'default': 1000000}, # 1Mbit/s - {'id': 'sample_point', 'desc': 'Sample point', 'default': 70.0}, # 70% + {'id': 'bitrate', 'desc': 'Bitrate (bits/s)', 'default': 1000000}, + {'id': 'sample_point', 'desc': 'Sample point (%)', 'default': 70.0}, ) annotations = ( ('data', 'CAN payload data'), diff --git a/decoders/lm75/pd.py b/decoders/lm75/pd.py index bdd8cb0..449916a 100644 --- a/decoders/lm75/pd.py +++ b/decoders/lm75/pd.py @@ -49,8 +49,9 @@ class Decoder(srd.Decoder): inputs = ['i2c'] outputs = ['lm75'] options = ( - {'id': 'sensor', 'desc': 'Sensor type', 'default': 'lm75'}, - {'id': 'resolution', 'desc': 'Resolution', 'default': 9, + {'id': 'sensor', 'desc': 'Sensor type', 'default': 'lm75', + 'values': ('lm75',)}, + {'id': 'resolution', 'desc': 'Resolution (bits)', 'default': 9, 'values': (9, 10, 11, 12)}, ) annotations = ( diff --git a/decoders/onewire_link/pd.py b/decoders/onewire_link/pd.py index d603dba..ceb5da2 100644 --- a/decoders/onewire_link/pd.py +++ b/decoders/onewire_link/pd.py @@ -37,33 +37,24 @@ class Decoder(srd.Decoder): ) options = ( {'id': 'overdrive', - 'desc': 'Overdrive mode', - 'default': 'no'}, + 'desc': 'Overdrive mode', 'default': 'no', 'values': ('yes', 'no')}, # Time options (specified in microseconds): {'id': 'cnt_normal_bit', - 'desc': 'Normal mode sample bit time (μs)', - 'default': 15}, + 'desc': 'Normal mode sample bit time (μs)', 'default': 15}, {'id': 'cnt_normal_slot', - 'desc': 'Normal mode data slot time (μs)', - 'default': 60}, + 'desc': 'Normal mode data slot time (μs)', 'default': 60}, {'id': 'cnt_normal_presence', - 'desc': 'Normal mode sample presence time (μs)', - 'default': 75}, + 'desc': 'Normal mode sample presence time (μs)', 'default': 75}, {'id': 'cnt_normal_reset', - 'desc': 'Normal mode reset time (μs)', - 'default': 480}, + 'desc': 'Normal mode reset time (μs)', 'default': 480}, {'id': 'cnt_overdrive_bit', - 'desc': 'Overdrive mode sample bit time (μs)', - 'default': 2}, + 'desc': 'Overdrive mode sample bit time (μs)', 'default': 2}, {'id': 'cnt_overdrive_slot', - 'desc': 'Overdrive mode data slot time (μs)', - 'default': 7.3}, + 'desc': 'Overdrive mode data slot time (μs)', 'default': 7.3}, {'id': 'cnt_overdrive_presence', - 'desc': 'Overdrive mode sample presence time (μs)', - 'default': 10}, + 'desc': 'Overdrive mode sample presence time (μs)', 'default': 10}, {'id': 'cnt_overdrive_reset', - 'desc': 'Overdrive mode reset time (μs)', - 'default': 48}, + 'desc': 'Overdrive mode reset time (μs)', 'default': 48}, ) annotations = ( ('bit', 'Bit'), diff --git a/decoders/parallel/pd.py b/decoders/parallel/pd.py index cae269f..330d514 100644 --- a/decoders/parallel/pd.py +++ b/decoders/parallel/pd.py @@ -74,9 +74,8 @@ class Decoder(srd.Decoder): 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', + {'id': 'wordsize', 'desc': 'Data wordsize', 'default': 1}, + {'id': 'endianness', 'desc': 'Data endianness', 'default': 'little', 'values': ('little', 'big')}, ) annotations = ( diff --git a/decoders/spi/pd.py b/decoders/spi/pd.py index d0e3409..7d84b3d 100644 --- a/decoders/spi/pd.py +++ b/decoders/spi/pd.py @@ -84,9 +84,9 @@ class Decoder(srd.Decoder): 'values': (0, 1)}, {'id': 'cpha', 'desc': 'Clock phase', 'default': 0, 'values': (0, 1)}, - {'id': 'bitorder', 'desc': 'Bit order within the SPI data', + {'id': 'bitorder', 'desc': 'Bit order', 'default': 'msb-first', 'values': ('msb-first', 'lsb-first')}, - {'id': 'wordsize', 'desc': 'Word size of SPI data', 'default': 8}, + {'id': 'wordsize', 'desc': 'Word size', 'default': 8}, ) annotations = ( ('miso-data', 'MISO data'), diff --git a/decoders/usb_packet/pd.py b/decoders/usb_packet/pd.py index 61acd4f..5dbbcdb 100644 --- a/decoders/usb_packet/pd.py +++ b/decoders/usb_packet/pd.py @@ -152,7 +152,8 @@ class Decoder(srd.Decoder): inputs = ['usb_signalling'] outputs = ['usb_packet'] options = ( - {'id': 'signalling', 'desc': 'Signalling', 'default': 'full-speed'}, + {'id': 'signalling', 'desc': 'Signalling', + 'default': 'full-speed', 'values': ('full-speed', 'low-speed')}, ) annotations = ( ('sync-ok', 'SYNC'), |