summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--decoders/onewire_transport/onewire_transport.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/decoders/onewire_transport/onewire_transport.py b/decoders/onewire_transport/onewire_transport.py
index 5481bd7..e787091 100644
--- a/decoders/onewire_transport/onewire_transport.py
+++ b/decoders/onewire_transport/onewire_transport.py
@@ -95,9 +95,11 @@ class Decoder(srd.Decoder):
self.state = "UNRECOGNIZED"
elif (self.state == "READ SCRATCHPAD"):
self.put(ss, es, self.out_ann, [0, ['SCRATCHPAD DATA: 0x%02x' % (val)]])
- elif (self.state == "TEMPERATURE CONVERSION"):
+ elif (self.state == "CONVERT TEMPERATURE"):
self.put(ss, es, self.out_ann, [0, ['TEMPERATURE CONVERSION STATUS: 0x%02x' % (val)]])
+ elif (self.state in command.values()):
+ self.put(ss, es, self.out_ann, [0, ['TODO "%s": 0x%02x' % (self.state, val)]])
elif (self.state == "UNRECOGNIZED"):
- self.put(ss, es, self.out_ann, [0, ['UNRECOGNIZED: 0x%02x' % (val)]])
+ self.put(ss, es, self.out_ann, [0, ['UNRECOGNIZED COMMAND: 0x%02x' % (val)]])
else:
raise Exception('Invalid state: %s' % self.state)