summaryrefslogtreecommitdiff
path: root/decoders
diff options
context:
space:
mode:
authorGerhard Sittig <gerhard.sittig@gmx.net>2020-11-07 13:49:06 +0100
committerGerhard Sittig <gerhard.sittig@gmx.net>2020-11-11 20:18:47 +0100
commit239e15df5015e7ea1282cab404e5a63db08f988d (patch)
treeda9c35b40ee117015ceccc7d56e62889676284ba /decoders
parent4f4e035397fa0770d47bf8b663e87651e0709511 (diff)
downloadlibsigrokdecode-239e15df5015e7ea1282cab404e5a63db08f988d.tar.gz
libsigrokdecode-239e15df5015e7ea1282cab404e5a63db08f988d.zip
parallel: adjust Python output to match its documentation
The parallel decoder documented the layout of the Python output but used to emit something different (mere data values). Add the bit width of data items and the bus cycle count for demultiplexed words, to match the documented layout. No harm was done, there are no in-tree decoders which stack on top of the parallel decoder.
Diffstat (limited to 'decoders')
-rw-r--r--decoders/parallel/pd.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/decoders/parallel/pd.py b/decoders/parallel/pd.py
index b4dbdb3..71d8833 100644
--- a/decoders/parallel/pd.py
+++ b/decoders/parallel/pd.py
@@ -140,8 +140,7 @@ class Decoder(srd.Decoder):
txts = [self.fmt_word.format(word)]
self.putg(ss, es, Ann.WORD, txts)
- self.putpy(ss, es, 'WORD', word)
- # self.putpy(ss, es, 'WORD', (word, bus_width, word_size))
+ self.putpy(ss, es, 'WORD', (word, bus_width, word_size))
if len(items) != word_size:
txts = ['incomplete word size', 'word size', 'ws']
@@ -177,8 +176,7 @@ class Decoder(srd.Decoder):
es = now
txts = [self.fmt_item.format(data)]
self.putg(ss, es, Ann.ITEM, txts)
- self.putpy(ss, es, 'ITEM', data)
- # self.putpy(ss, es, 'ITEM', (data, bus_width))
+ self.putpy(ss, es, 'ITEM', (data, bus_width))
# Optionally queue the currently seen item.
if item is not None: