]> sigrok.org Git - libsigrokdecode.git/blobdiff - decoders/arm_itm/pd.py
cjtag: Drop some unused method arguments.
[libsigrokdecode.git] / decoders / arm_itm / pd.py
index 15ffe7223277023a7e5b87583492333a8082f451..8ceeac464ae6545872a30ef3f166755c430b85f6 100644 (file)
@@ -41,10 +41,11 @@ class Decoder(srd.Decoder):
     id = 'arm_itm'
     name = 'ARM ITM'
     longname = 'ARM Instrumentation Trace Macroblock'
-    desc = 'Trace data from Cortex-M / ARMv7m ITM module.'
+    desc = 'ARM Cortex-M / ARMv7m ITM trace protocol.'
     license = 'gplv2+'
     inputs = ['uart']
-    outputs = ['arm_itm']
+    outputs = []
+    tags = ['Debug/trace']
     options = (
         {'id': 'objdump', 'desc': 'objdump path',
             'default': 'arm-none-eabi-objdump'},
@@ -54,7 +55,7 @@ class Decoder(srd.Decoder):
             'default': ''},
     )
     annotations = (
-        ('trace', 'Trace information'),
+        ('trace', 'Trace info'),
         ('timestamp', 'Timestamp'),
         ('software', 'Software message'),
         ('dwt_event', 'DWT event'),
@@ -68,18 +69,21 @@ class Decoder(srd.Decoder):
         ('function', 'Current function'),
     )
     annotation_rows = (
-        ('trace', 'Trace information', (0, 1)),
-        ('software', 'Software trace', (2,)),
-        ('dwt_event', 'DWT event', (3,)),
-        ('dwt_watchpoint', 'DWT watchpoint', (4,)),
-        ('dwt_exc', 'Exception trace', (5,)),
-        ('dwt_pc', 'Program counter', (6,)),
-        ('mode', 'Current mode', (7, 8, 9)),
-        ('location', 'Current location', (10,)),
-        ('function', 'Current function', (11,)),
+        ('traces', 'Trace info', (0, 1)),
+        ('softwares', 'Software traces', (2,)),
+        ('dwt_events', 'DWT events', (3,)),
+        ('dwt_watchpoints', 'DWT watchpoints', (4,)),
+        ('dwt_excs', 'Exception traces', (5,)),
+        ('dwt_pcs', 'Program counters', (6,)),
+        ('modes', 'Current modes', (7, 8, 9)),
+        ('locations', 'Current locations', (10,)),
+        ('functions', 'Current functions', (11,)),
     )
 
     def __init__(self):
+        self.reset()
+
+    def reset(self):
         self.buf = []
         self.syncbuf = []
         self.swpackets = {}