beautypg.com

Teledyne LeCroy ST Automated Test Suite User Manual User Manual

Page 24

background image

24

VSTools.inc File of Verification Script Tools

You should include the VSTools.inc include file in all verification scripts. This file contains important script
functions and is a supplement to the Verification Script Engine API provided by the application.It also has
some useful examples.


#########################################################################################
# Copyright (c) 1998 - 2005, LeCroy - All Rights Reserved #
# #
# VSTools.inc #
# #
# Verification Script Tools #
# version 1.0 #
# #
# NOTE: This file contains important script functions and is a supplement to the #
# Verification Script Engine API provided by the application. #
# #
# This file SHOULD be included in all verification scripts. #
#########################################################################################

%include "../IEEE/IEEECompanies.inc"
%include "VS_Primitives.inc"
%include "VS_constants.inc"

#########################################################################################
# Common Globals #
#########################################################################################

set State = 0; # Main state machine input.
# This variable may be used for implementation of different kinds of
# state machines.

set StartScript = 1; # indicates that it first run

set str = ""; # global buffer supposedly for string values
set val = 0; # global buffer supposedly for integer or other values

########################################################################################
# FUNCTIONS #
########################################################################################

####################################################################
# Common reset actions which should be performed for any #
# verification script preparing it for consecutive runs. #
# #
# The VSE will call this function for any script after it #
# has finished running. #
####################################################################

OnResetScript()
{
State = 0;
StartScript = 1;

ResetScript();
}

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

ScriptPassed()
{
out.Result = _VERIFICATION_PASSED;
}