beautypg.com

Teledyne LeCroy ST Automated Test Suite User Manual User Manual

Page 25

background image

25

########################################################################
# This function specifies that the verification is failed and the #
# script should complete its work. #
########################################################################

ScriptFailed()
{
out.Result = _VERIFICATION_FAILED;
}

########################################################################
# This function specifies that the verification is done and the #
# script should complete its work. #
########################################################################

ScriptDone()
{
out.Result = _VERIFICATION_PASSED;
}

########################################################################
# This function returns the name of the level where the current

#

# event occurred. #
########################################################################
GetLevelName()
{

level = in.Level;

level_name =

select

{

level == _IDLE

: "Idle";

level == _LINK

: "Link";

level == _OOB_SEQ

: "OOB_Seq";

level == _TRANSPORT : "Transp";

level == _ATA

: "ATA";

level == _SCSI

: "SCSI";

level == _SMP

: "SMP";

level == _TASK

: "TASK";


default : FormatEx("%d", level); #"Unknown";

};

return level_name;

}

########################################################################
# This function returns the name of the link speed where the current #
# event occurred. #
########################################################################
GetLinkSpeedName()
{

speed = in.LinkSpeed;

speed_name =

select

{

speed == _LINK_SPEED_1_5

: "1.5G";

speed == _LINK_SPEED_3_0

: "3G";

speed == _LINK_SPEED_6_0

: "6G";


default

: FormatEx("%d", speed); #"Unknown";

};

return speed_name;

}