diff options
author | Uwe Hermann <uwe@hermann-uwe.de> | 2012-06-13 19:09:05 +0200 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2012-06-14 01:21:00 +0200 |
commit | 140149cb9803789402328b01a378d43d59c5d8a7 (patch) | |
tree | 6021f9ccaa6ca211c6c63419ab850fb1c2fd9b59 /decoders/pan1321 | |
parent | 71077f34ffbd7d4015886a229edb2f2f827cb442 (diff) | |
download | libsigrokdecode-140149cb9803789402328b01a378d43d59c5d8a7.tar.gz libsigrokdecode-140149cb9803789402328b01a378d43d59c5d8a7.zip |
srd: Fix non-working PAN1321 decoder.
Diffstat (limited to 'decoders/pan1321')
-rw-r--r-- | decoders/pan1321/pan1321.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/decoders/pan1321/pan1321.py b/decoders/pan1321/pan1321.py index da981f2..773e02d 100644 --- a/decoders/pan1321/pan1321.py +++ b/decoders/pan1321/pan1321.py @@ -56,30 +56,30 @@ class Decoder(srd.Decoder): if s.startswith('AT+JSEC'): pin = s[-4:] self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Host set the Bluetooth PIN to ' + pin]]) + [0, ['Host set the Bluetooth PIN to ' + pin]]) elif s.startswith('AT+JSLN'): name = s[s.find(',') + 1:] self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Host set the Bluetooth name to ' + name]]) + [0, ['Host set the Bluetooth name to ' + name]]) else: self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Host sent unsupported command: %s' % s]]) + [0, ['Host sent unsupported command: %s' % s]]) self.cmd[rxtx] = '' def handle_device_reply(self, ss, es, rxtx, s): if s == 'ROK': self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Device initialized correctly']]) + [0, ['Device initialized correctly']]) elif s == 'OK': self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Device acknowledged last command']]) + [0, ['Device acknowledged last command']]) elif s.startswith('ERR'): error = s[s.find('=') + 1:] self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Device sent error code ' + error]]) + [0, ['Device sent error code ' + error]]) else: self.put(ss, es, self.out_ann, - [ANN_ASCII, ['Device sent an unknown reply: %s' % s]]) + [0, ['Device sent an unknown reply: %s' % s]]) self.cmd[rxtx] = '' def decode(self, ss, es, data): |