Atapi user-defined decoding, Assigning a script to atapi commands, Writing a script for atapi commands decoding – Teledyne LeCroy User-Defined Decoding (UDD) Advanced Script Language (ASL) Reference Manual User Manual
Page 25: Ssigning a, Cript to, Atapi, Ommands, Riting a, Cript for, Ecoding

22
ATAPI User-Defined Decoding
Assigning a Script to ATAPI Commands
Open a sample, then choose User defined decoding … from the Configuration pull-down menu to
display the following dialog. Select ATAPI & SCSI command(s) and assign a user-defined script to
the sample.
Writing a Script for ATAPI Commands Decoding
If you want the SCSI fields of a UDD ATAPI commands to have the same color as a SCSI
command fields, do the following.
A user-defined ATAPI command has two or more fields.
The first field must have the name Operation Code, with length 1 byte. The options of the
Operation Code field must be defined in the DefineOptions section of the script.
OperationCode =(
"Vendor 99", 0x99;
"Vendor 66", 0x66;
"Vendor 77", 0x77);
For example:
OperationCode = AddField(CURPOS,8,"Operation Code",
"Operation Code","Operation Code");
Otherwise, different fields can be defined, and the fields of UDD ATAPI commands would have the
same color as ATA-command fields.
If the length of the last field is not certain, define the last field with the length
LengthOf(INPUTDATA)- CURPOS – 8, as in following example:
VendorSpecific = AddField(CURPOS, LengthOf(INPUTDATA)- CURPOS – 8 ,
"Vendor Specific","Vendor Specific","Vendor Specific");