USB-PD TDMP Instruction Manual
Appendix A: Automating the Decoder
As with all other oscilloscope settings, decoder features such as result table configuration and export can be
configured remotely using COM Automation.
Note: The examples shown here were taken from a CAN FD decoding, but all decoder result tables share the
same Automation structure.
Configuring the Decoder
The object path to the decoder Control Variables (CVARs) is:
app.SerialDecode.Decode
n
Where
n
is the decoder number, 1 to 4. All relevant decoder objects will be nested under this. Use the MAUI Browser
utility (installed on the oscilloscope desktop) to view the entire object hierarchy.
Accessing the Result Table
The decoder Result Table is a complex matrix with secondary tables nested within some of its cells. The table data
can be accessed using the Automation object:
app.SerialDecode.Decode
n
.out.Result.cellvalue(
RowA
,
ColA
)(
RowB
,
ColB
)
Where:
n
:= 1 to 4
RowA
:= 0 to K (0=Row Index Number)
ColA
:= 0 to L (0=Column Header)
RowB
:= 0=MeasuredValue, 1=StartTime, 2=StopTime
ColB
:= 0 to M
Complicating the matter of accessing the table is that there are two types of cell that may appear in the Result table,
Simple Cell and Table Cell, which are accessed in slightly different ways, and that some columns are always hidden
from view, yet they are still counted among the columns when querying.
Reading the Structure of the Result Table
In order to successfully access the data, it is necessary to first ascertain how many rows and columns are actually in
your decoder result table, and what cell type is used for the column of data you wish to read.
To do this, we have provided the script, ExampleTableSerialDecode.vbs, which by default installs into oscilloscope:
C:\LeCroy\XStream\Scripts\Automation\ExampleTableSerialDecode.vbs.
Tip: This script may also be used as a basis for your own remote control programs, or used as is to read
decoder table data.
30
Содержание USB-PD TDMP
Страница 1: ...USB PD TDMP Trigger Decode Measure Graph and Physical Layer Tests...
Страница 38: ......