]> sigrok.org Git - libsigrokdecode.git/commitdiff
x2444m: Add some shorter annotation strings as well.
authorUwe Hermann <redacted>
Sat, 10 Nov 2018 17:48:37 +0000 (18:48 +0100)
committerUwe Hermann <redacted>
Sat, 10 Nov 2018 17:48:37 +0000 (18:48 +0100)
decoders/x2444m/pd.py

index 751e6d36feb4f5a7ba994379e6a13d0ba00a3fdf..2fa4d3848e9dfbafd58a778b7187f862e1489455 100644 (file)
@@ -64,10 +64,11 @@ class Decoder(srd.Decoder):
 
     def putreadwrite(self, ss, es, reg, idx, addr, value):
         self.put(ss, es, self.out_ann,
-                 [idx, ['%s: %s => 0x%4.4x' % (reg, addr, value)]])
+                 [idx, ['%s: %s => 0x%4.4x' % (reg, addr, value),
+                        '%s: %s => 0x%4.4x' % (reg[0], addr, value), reg[0]]])
 
     def putcmd(self, ss, es, reg, idx):
-        self.put(ss, es, self.out_ann, [idx, ['%s' % reg]])
+        self.put(ss, es, self.out_ann, [idx, [reg, reg[0]]])
 
     def decode(self, ss, es, data):
         ptype, mosi, miso = data