
LeCroy Corporation
Trainer Script Enhancements
410
Sierra M6
‐
2 SAS/SATA Protocol Analyzer User Manual
If/While in Logical Expressions
Like programming languages, scripts allow conditional statements.
The
if/while
syntaxes are:
If (expression)
{
….
}
else
{
….
}
While(@VarName)
{
…….
}
Note:
In this release,
while
condition is limited to simple variable values only. Combining operators is
not allowed in
while
expressions. You should move such expressions inside
while
block.
Note:
Nested
while
and
if
are supported.
Using Variable Values in Creating Patterns on Bus
In creating patterns to send on bus, trainer script allows using variables. In these cases,
because the created pattern is dynamic, it is not possible to do scrambling and calculating
in software code. These tasks are done in the hardware engine. To activate, set “Auto
scramble mode” in “on” state.
The following examples show uses of variables in creating patterns.
Use
variable
for
field
value:
SendOpenAddressFrameSSP
{
InitiatorPort = 0x1
InitiatorConnectionTag = @variableName1
…...
}
The constraints are:
Field Length bigger than 64 bit is not supported.
Field StartBitOffset and EndBitOffset should be in same DWORD, except for
length bigger than 32.