beautypg.com

Definitions, Field variable declarations, Changing frame fields – Teledyne LeCroy STX M6-1 SAS_SATA Protocol Analyzer User Manual User Manual

Page 399: Preprocessor integer arithmetic

background image

    

Sierra M6‐4 SAS/SATA Protocol Analyzer User Manual

397

Sierra Trainer Generation Language

LeCroy Corporation

Definitions

Chain Definition:

Without any parameters, the chain is sent once.

With “Repeat” and “Idle” parameters, the chain is sent N times and then nothing
is sent (idle) M times. “Repeat” and “Idle” are optional.

Frame Definition

Without any parameters, send the frame based in default values.

With “RunningDisp” ON, send the frames based on default values and insert a
running disparity error.

With parameters overriding or adding to a template frame, with or without injec‐
tion of an overriding or adding to a template frame, with or without injection of
running disparity error.

Field Variable Declarations

You can declare a variable (var_name) as a frame of type (frame_type):

$var_name = frame_type

Note:

Frame variables can be declared/re‐declared and used many times.

Changing Frame Fields

You can change some fields in a frame variable.

Change var_name { field_name = value }

Preprocessor Integer Arithmetic

You can declare DWORD variables, make arithmetic operations, and use them in field and
parameters assignments.

Note:

Arithmetic expressions are allowed only in numeric variable assignments.

Examples:

Legal Operations

x = 2

y = ( z = 12 ) + ( SOME_DEC_DATA + 36 ) / 8

z = 0x1 << 5

s = "Some Hex Data" # constant may be used in operations

x++

y--

z += ( x + y )

x = ( ( y & 0xFF ) >> 5 ) / 12

SOF ( Repeat = x, Idle = y )