Writing to the Trace32 command line through python

346 Views Asked by At

Hello I'm currently working on automating some tasks in Trace32 using python. I have no previous knowledge of Trace 32 so I'm trying to learn as I go. so far I've understood that I need to use lauterbach.trace32.rcl (the remote control API provided by lauterbach) in order to control the T32 instance however there's no clear documentation on how to use it to write commands and run files and so on.

the only documentation I've found is the 'app_python.pdf' which from what I understand only presents the legacy method using Ctypes & enum. so my question is can I find a syntax reference for connecting and controlling T32 variables and command line through python ?

2

There are 2 best solutions below

0
dev15 On

In app_python.pdf the chapter "lauterbach.trace32.rcl (PYRCL)" has some pointers, e.g. the link to the HTML documentation for the module can be found at <TRACE32 installation directory>/demo/api/python/rcl/doc/html/index.html.

1
Bobo Svangård On

Sending and executing command line commands, is as simple as executing (from python)

import lauterbach.trace32.rcl as t32
dbg = t32.autoconnect()
dbg.cmd("data.save.binary /tmp/test.raw zsd:0x%x--0x%x" % (adress1, address2)