Visara Master Console Center Scripting Guide Manuale Utente Pagina 1

Navigare online o scaricare Manuale Utente per Accessori per computer Visara Master Console Center Scripting Guide. Visara Master Console Center Scripting Guide User Manual Manuale Utente

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 262
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti

Sommario

Pagina 1 - Scripting Guide

VisaraMaster Console CenterScripting GuideP/N 707131-001

Pagina 2 - Notices

About This Guide Scripting Guide 10 The MCC Documentation Set In addition to this manual, you may need to refer to other manuals in the MCC docume

Pagina 3 - Contents

Chapter 5 Script Commands Scripting Guide 100 Manifest Constant Value Associated String/Reason ICLErr_Mvs_InvMsgCnt 4020 Invalid message count

Pagina 4 - Scripting Guide 4

Chapter 5 Script Commands Scripting Guide 101 EXEC Syntax: EXEC( $ScriptName[, Parm1, ...]) ==> ReturnValue Description: Executes a script who

Pagina 5 - Scripting Guide 5

Chapter 5 Script Commands Scripting Guide 102 $ScriptName := “script1” ELSE $ScriptName := “script2” ENDIF %ReturnValue := EXEC( $ScriptName,

Pagina 6 - Scripting Guide 6

Chapter 5 Script Commands Scripting Guide 103 FCLOSE Syntax: FCLOSE( %FileNum) Description: Closes an open file. Action: Closes a file opened wit

Pagina 7 - Scripting Guide 7

Chapter 5 Script Commands Scripting Guide 104 FDELETE Syntax: FDELETE( $FileName) ==> %Success Description: Permanently deletes a file. Action

Pagina 8

Chapter 5 Script Commands Scripting Guide 105 FEXISTS Syntax: FEXISTS( $FileName) ==> %Success Description: Determines if a file exists. Actio

Pagina 9 - About This Guide

Chapter 5 Script Commands Scripting Guide 106 FILENO Syntax FILENO(%FileHandle) ==> %FileDescriptor Description: Obtains the system integer fil

Pagina 10 - The MCC Documentation Set

Chapter 5 Script Commands Scripting Guide 107 FINDSTR Syntax: FINDSTR( $String, $Substring) ==> $FoundText Description: Searches a string for

Pagina 11 - Chapter 1 Script Overview

Chapter 5 Script Commands Scripting Guide 108 FMODTIME Syntax: FMODTIME( File) ==> %EpochSeconds Description: Returns the time value of a last

Pagina 12 - Script Concepts

Chapter 5 Script Commands Scripting Guide 109 FOPEN Syntax: FOPEN( $FileName[, %Mode]) ==> %FileHandle Description: Opens a file for I/O acces

Pagina 13 - Script Source Structure

Scripting Guide 11 Chapter 1 Script Overview This chapter describes:  Script concepts  Script structures  Master scripts  Reserved scripts 

Pagina 14 - Master Scripts

Chapter 5 Script Commands Scripting Guide 110 Example: %Handle := FOPEN( “SYS5”, OVERWRITE) $FileName := “SYS5” %Mode := APPEND %Handle := FOPEN(

Pagina 15 - Reserved Scripts

Chapter 5 Script Commands Scripting Guide 111 FORMATSTR Syntax: FORMATSTR( $String [, expr1, [expr2, ..., [exprn]..]]) ==> $Formatted Descript

Pagina 16 - #logswap.scr

Chapter 5 Script Commands Scripting Guide 112 $Return := FORMATSTR( "The value is: %10d.", %Value2 ) LOG( LOG_EXEC, $Return, 12 ) OU

Pagina 17 - #shutdn.scr

Chapter 5 Script Commands Scripting Guide 113 Conversion Specifications Syntax Each conversion specification in the String parameter has the follo

Pagina 18 - Executing Scripts

Chapter 5 Script Commands Scripting Guide 114 A field width can be indicated by an * (asterisk) instead of a digit string. In this case, an integ

Pagina 19 - Scripting Guide 19

Chapter 5 Script Commands Scripting Guide 115 x, X Accepts an integer value and converts it to unsigned hexadecimal notation. The letters abcdef

Pagina 20

Chapter 5 Script Commands Scripting Guide 116 FPOS Syntax: FPOS( %FileNum) ==> %Position Description: Returns an open file’s current record po

Pagina 21 - Chapter 2 Advanced Topics

Chapter 5 Script Commands Scripting Guide 117 FREAD Syntax: FREAD( %FileNum, var1[, var2, ..., [varn]...]) ==> %QtyRead Description: Reads val

Pagina 22 - Script Writing Guidelines

Chapter 5 Script Commands Scripting Guide 118 FRENAME Syntax: FRENAME( $CurrentName, $NewName) ==> %Success Description: Renames a file. Actio

Pagina 23 - Scripting Guide 23

Chapter 5 Script Commands Scripting Guide 119 FREWIND Syntax: FREWIND( %FileNum) Description: Moves an open file’s current record pointer to the

Pagina 24 - MCC Concepts

Chapter 1 Script Overview Scripting Guide 12 Overview The Master Console Center Global Control Language (MCC GCL) is a powerful high-level program

Pagina 25 - Object Key

Chapter 5 Script Commands Scripting Guide 120 FSEEK Syntax: FSEEK( %FileNum, %Position) ==> %Success Description: Moves an open file’s current

Pagina 26 - Object Field

Chapter 5 Script Commands Scripting Guide 121 FWRITE Syntax: FWRITE( %FileNum, expr [, %NEWLINE] ) ==> %Success Description: Writes the expres

Pagina 27 - Object Action

Chapter 5 Script Commands Scripting Guide 122 GETENV Syntax: GETENV($Variable) ==> $Value Description: Obtains the current value of the given e

Pagina 28

Chapter 5 Script Commands Scripting Guide 123 GETPID Syntax: GETPID() ==> %ProcessId Description: Obtains the system process identifier for thi

Pagina 29 - Icon Class/Icon Name

Chapter 5 Script Commands Scripting Guide 124 GOSUB Syntax: GOSUB *Label Description: Immediately transfers script execution to the specified lab

Pagina 30 - Scripting Guide 30

Chapter 5 Script Commands Scripting Guide 125 GOTO Syntax: GOTO *Label Description: Immediately transfers script execution to the specified label

Pagina 31 - MIB OID

Chapter 5 Script Commands Scripting Guide 126 HEXSTR Syntax: HEXSTR( %Number) ==> $Hex Description: Converts an integer to a hex string. Actio

Pagina 32

Chapter 5 Script Commands Scripting Guide 127 HMCEXEC Syntax: HMCEXEC(%ObjID, $Action [, parm1, ...]) => %RetVal Description: Send a command t

Pagina 33 - Chapter 3 Script Syntax

Chapter 5 Script Commands Scripting Guide 128 Possible HMC actions and parameters CPC and Image Commands Action Description Optional Parameter(s

Pagina 34 - Structuring a Script

Chapter 5 Script Commands Scripting Guide 129 HUMID Syntax: HUMID( %Port) ==> %Humidity Description: Reads the current humidity from a sensor

Pagina 35 - − “scr” for script source

Chapter 1 Script Overview Scripting Guide 13 A script source file format is a standard ASCII file—it can be written anywhere and copied to the MCC

Pagina 36 - Variables

Chapter 5 Script Commands Scripting Guide 130 ICON Syntax: ICON( %Status[, $Message [, %Class [, $Name]]]) Description: Changes icon characterist

Pagina 37 - Numeric Variables

Chapter 5 Script Commands Scripting Guide 131 Notes: 1. Refer to Manifest Constants on page 42 for the constants reference list. 2. The defaul

Pagina 38 - Using and Naming Arrays

Chapter 5 Script Commands Scripting Guide 132 ICONMSG Syntax: ICONMSG( [%Class [, $Name]]) ==> $Message Description: Returns an icon’s current

Pagina 39 - Associative Arrays

Chapter 5 Script Commands Scripting Guide 133 ICONNAME Syntax: ICONNAME( [%Class [, %Port]]) ==> $Name Description: Returns an icon’s name. Ac

Pagina 40 - Date/Time

Chapter 5 Script Commands Scripting Guide 134 ICONSTATUS Syntax: ICONSTATUS( [%Class [, $Name]]) ==> %Status Description: Returns an icon’s cu

Pagina 41 - Expressions

Chapter 5 Script Commands Scripting Guide 135 IF Syntax: IF...[ELSE...]ENDIF IF Expression Group 1 command [More group 1 commands] [ELSE]

Pagina 42

Chapter 5 Script Commands Scripting Guide 136 INC Syntax: INC %Variable Description: Adds one to a numeric variable’s value. Action: The value in

Pagina 43 - Manifest Error Constants

Chapter 5 Script Commands Scripting Guide 137 JOIN Syntax: JOIN( $Array, $Delimiter) ==> $String Description: Combines the elements of an arra

Pagina 44

Chapter 5 Script Commands Scripting Guide 138 KEY Syntax: KEY( %Port, $Keys [,%Timeout]) ==> %RetCode Description: Enters a character string t

Pagina 45

Chapter 5 Script Commands Scripting Guide 139 a command being processed, and a console that has failed or hung. 5. The KEY command processing als

Pagina 46

Chapter 1 Script Overview Scripting Guide 14 Naming Scripts Each script must be given a unique name before it is saved and compiled. Note: The sc

Pagina 47 - Other Manifest Constants

Chapter 5 Script Commands Scripting Guide 140 KEY Command Return Values Manifest Constant Value Description Err_None 0 No error Err_Key_Timelock

Pagina 48

Chapter 5 Script Commands Scripting Guide 141 KEY Command Specifics Note: The KEY command is not case sensitive. Characters within brackets ([ o

Pagina 49

Chapter 5 Script Commands Scripting Guide 142 Keyboard Key Key Command INS (^a) or INSERT [INS] or [INSERT] IRPT [IPT] or [IRPT] ISTEP EOF [IS

Pagina 50 - Operators

Chapter 5 Script Commands Scripting Guide 143 LEFTSTR Syntax: LEFTSTR( $String, %Count) ==> $SubStr Description: Returns the leftmost specifie

Pagina 51 - Comment Statements

Chapter 5 Script Commands Scripting Guide 144 LEN Syntax: LEN( $StringExpr) ==> %Count Description: Returns the number of characters in a stri

Pagina 52 - Label Statements

Chapter 5 Script Commands Scripting Guide 145 LOG Syntax: LOG( %LogType, $Message[, %Status]) Description: Enters a message in a log. Action: The

Pagina 53 - Scripting Guide 53

Chapter 5 Script Commands Scripting Guide 146 LOWER Syntax: LOWER( $String) ==> $Lowercase Description: Converts uppercase characters to lower

Pagina 54 - Regular Expressions

Chapter 5 Script Commands Scripting Guide 147 MKDTEMP Syntax: MKDTEMP($Pattern) ==> $DirectoryName Description: Creates a unique temporary dire

Pagina 55 - Subexpressions

Chapter 5 Script Commands Scripting Guide 148 MKSTEMP Syntax: MKSTEMP($Pattern) ==> %FileHandle Description: Opens a unique temporary file for

Pagina 56 - Scripting Guide 56

Chapter 5 Script Commands Scripting Guide 149 MKTEMP Syntax: MKTEMP($Pattern) ==> $FileName Description: Returns a unique file name. Action: Cr

Pagina 57 - Bracket Expressions

Chapter 1 Script Overview Scripting Guide 15 Reserved Scripts Every MCC system includes a set of reserved scripts. Reserved scripts automatically

Pagina 58

Chapter 5 Script Commands Scripting Guide 150 MONIKER Syntax: MONIKER() ==> $Name Description: Obtains the product name. Action: Returns the pr

Pagina 59

Chapter 5 Script Commands Scripting Guide 151 OBJEXEC Syntax: OBJEXEC( %ObjID, $Action[, Parms...]) ==> %ReturnValue Description: Executes an

Pagina 60 - Description

Chapter 5 Script Commands Scripting Guide 152 OBJGET Syntax: OBJGET( %ObjID, $ObjFieldName) ==> $CurrentValue Description: Returns the current

Pagina 61 - Scripting Guide 61

Chapter 5 Script Commands Scripting Guide 153 OBJGETARRAY Syntax: OBJGETARRAY( %ObjID, $AssocArray) ==> %ErrCode Description: Populates an ass

Pagina 62 - Alternation

Chapter 5 Script Commands Scripting Guide 154 OBJID Syntax: OBJID( %Class, $ObjKeyExpr) ==> %ObjectID Description: Returns the ID (unique only

Pagina 63 - Order Type Symbols

Chapter 5 Script Commands Scripting Guide 155 //This example builds an array of ObjIDs, for use // with the QOPEN command. $Lpar1 := “9672-1:BETA

Pagina 64 - Character Description

Chapter 5 Script Commands Scripting Guide 156 OBJIDARRAY Syntax: OBJIDARRAY( %Class, %ObjIDParent, %AssocArray) ==> %Children Description: Pop

Pagina 65 - Collating Elements

Chapter 5 Script Commands Scripting Guide 157 LOG(LOG_EXEC, $aKidIDs[%Count] + “Object ID is: “ + / %aaKidIDs[$aKidIDs[%Count]], 1) INC %Count

Pagina 66

Chapter 5 Script Commands Scripting Guide 158 OBJSET Syntax: OBJSET( %ObjID, $ObjFieldName, $NewValue) ==> %ErrCode Description: Sets the curr

Pagina 67 - Chapter 5 Script Commands

Chapter 5 Script Commands Scripting Guide 159 OBJSETARRAY Syntax: OBJSETARRAY( %ObjID, $AssocArray) ==> %Success Description: Sets the field va

Pagina 68 - Script Command Types

Chapter 1 Script Overview Scripting Guide 16 Status Change Reserved Script Name Executed in Response MCC is started (this event is not a login)

Pagina 69 - AICONNAMES

Chapter 5 Script Commands Scripting Guide 160 RETURN OUTPUT: Current Status is: UNKNOWN Desired Status is: UNKNOWN Group Status is: NONE Current

Pagina 70

Chapter 5 Script Commands Scripting Guide 161 PARMS Syntax: PARMS var1[, var2 [, var3, ..., [varn]...]]] Description: Receives parameters into th

Pagina 71 - ALERTCREATE

Chapter 5 Script Commands Scripting Guide 162 PORT Syntax: PORT( %Class[, $IconName]) ==> %Port Description: Returns the port number for a con

Pagina 72 - ALERTDEL

Chapter 5 Script Commands Scripting Guide 163 QCLOSE Syntax: QCLOSE( %QueueID) Description: Closes a message queue. Action: Closes the specified

Pagina 73 - ALERTGETACTIVE

Chapter 5 Script Commands Scripting Guide 164 QOPEN Syntax: QOPEN( [%ObjIdArray]) ==> %QueueID Description: Opens a new queue of OS printer co

Pagina 74

Chapter 5 Script Commands Scripting Guide 165 commands does not function with an OS that uses an RS232 or Telnet connection with the no_printer fl

Pagina 75

Chapter 5 Script Commands Scripting Guide 166 QPREVIEW Syntax: QPREVIEW( %QueueID, $ResultArray) ==> %RetCode Description: For non-mainframe p

Pagina 76 - ALERTMOD

Chapter 5 Script Commands Scripting Guide 167 console, you may wish to key “exit” before issuing your QPREVIEW().) Example: // Get the Object IDs

Pagina 77

Chapter 5 Script Commands Scripting Guide 168 QREAD Syntax: QREAD( %QueueID, $MsgArray, %Wait[, $Filter]) ==> $MsgLine Description: Reads the

Pagina 78

Chapter 5 Script Commands Scripting Guide 169 the printer message queue. It is placed in the printer message queue after the user presses <ENT

Pagina 79

Chapter 1 Script Overview Scripting Guide 17  Parm 3. The name of the backup log. (A string.) The default #LOGSWAP.SCR script shipped with the

Pagina 80

Chapter 5 Script Commands Scripting Guide 170 QSKIP Syntax: QSKIP( %QueueID, %Skip) Description: Moves a current message pointer for a queue. Act

Pagina 81 - ASSOCKEYS

Chapter 5 Script Commands Scripting Guide 171 REPEAT Syntax: REPEAT...UNTIL REPEAT Commands UNTIL Expression Description: Repeats a sequence

Pagina 82

Chapter 5 Script Commands Scripting Guide 172 REPSTR Syntax: REPSTR( $String, %Count) ==> $RepeatedString Description: Returns a string repeat

Pagina 83 - BASEDIRECTORY

Chapter 5 Script Commands Scripting Guide 173 RETURN Syntax: RETURN [Expression] Description: Returns execution to the calling routine, passing a

Pagina 84 - BLOCKSCAN

Chapter 5 Script Commands Scripting Guide 174 RIGHTSTR Syntax: RIGHTSTR( $String, %Count) ==> $SubStr Description: Returns the right-most spec

Pagina 85

Chapter 5 Script Commands Scripting Guide 175 SCANB Syntax: SCANB( %Port, $Text, *Found) Description: Searches an OS console for a specified char

Pagina 86

Chapter 5 Script Commands Scripting Guide 176 SCANP Syntax: SCANP( %Port, $Text, %Wait, *Found[, $Array]) Description: Searches an OS console for

Pagina 87 - CLASSNAME

Chapter 5 Script Commands Scripting Guide 177 SCRIPTCANCEL Syntax: SCRIPTCANCEL($ScriptName,$Class,$Name) Description: Obtains the system integer

Pagina 88 - CLASSNUM

Chapter 5 Script Commands Scripting Guide 178 SCRIPTGETACTIVE Syntax: SCRIPTGETACTIVE($AssocArray) ==> %ErrCode Description: Retrieves informat

Pagina 89 - CPUPOWER

Chapter 5 Script Commands Scripting Guide 179 current WAIT command $ScriptInfo[6] 0 Number of seconds which remain for the current WAIT comman

Pagina 90

Chapter 1 Script Overview Scripting Guide 18 Executing Scripts There are four ways to execute a script:  Manually. A user selects a script for

Pagina 91

Chapter 5 Script Commands Scripting Guide 180 Examples: Simple Script to log all of the script information to the filtered message log: %rc := SC

Pagina 92

Chapter 5 Script Commands Scripting Guide 181 SCRNTEXT Syntax: SCRNTEXT( %Port, %Start, %Length) ==> $Text Description: A full or partial scr

Pagina 93

Chapter 5 Script Commands Scripting Guide 182 SECONDS Syntax: SECONDS() ==> %EpochSeconds Description: Returns the time value for the current

Pagina 94

Chapter 5 Script Commands Scripting Guide 183 SET Syntax: SET Variable := Expression Description: Make the contents of a variable equal to the sp

Pagina 95

Chapter 5 Script Commands Scripting Guide 184 SNMP_GET Syntax: SNMP_GET( $Alias, $MIBOID) ==> $Value Description: Retrieves the value of a spe

Pagina 96

Chapter 5 Script Commands Scripting Guide 185 SNMP_GETNEXT Syntax: SNMP_GETNEXT( $Alias, $MIBOID, $NextMIBOID) ==> $Value Description: Retriev

Pagina 97 - ERRORMSG

Chapter 5 Script Commands Scripting Guide 186 SNMP_GETTABLE Syntax: SNMP_GETTABLE( $Alias, $MIBOID, $TableArray[, $Delimiter]) ==> %ReturnCode

Pagina 98 - ERRORNUM

Chapter 5 Script Commands Scripting Guide 187 Example: // gets the table at “interfaces” from the named host // alias $Alias := “Galileo” $MIBOI

Pagina 99

Chapter 5 Script Commands Scripting Guide 188 SNMP_SET Syntax: SNMP_SET( $Alias, $MIBOID, $Value) ==> %ReturnCode Description: Sets the value

Pagina 100

Chapter 5 Script Commands Scripting Guide 189 SNMP_TRAPSEND Syntax: SNMP_TRAPSEND( $Alias, %TrapNum[, %EntNum [, $MIBOID ] [, $VARBINDS]]) ==>

Pagina 101

Chapter 1 Script Overview Scripting Guide 19 Using the EXEC Command A script may be executed from within another script with the EXEC command. Th

Pagina 102 - See Also:

Chapter 5 Script Commands Scripting Guide 190 Example: ************************************** Example 1 ************************************** $A

Pagina 103

Chapter 5 Script Commands Scripting Guide 191 SPLIT Syntax: SPLIT( $Array, $String, $Delimiter) Description: Populates an array with the fields o

Pagina 104 - FDELETE

Chapter 5 Script Commands Scripting Guide 192 START Syntax: START( ScriptName( Parms)[, %Class[, $Name]]) Description: Initiates execution of ano

Pagina 105 - FEXISTS

Chapter 5 Script Commands Scripting Guide 193 STOP Syntax: STOP( ScriptName[, %Class [, $Name]]) Description: Halts execution of a script. Action

Pagina 106

Chapter 5 Script Commands Scripting Guide 194 STR Syntax: STR( %Number) ==> $String Description: Converts a numeric expression to a string. Ac

Pagina 107 - FINDSTR

Chapter 5 Script Commands Scripting Guide 195 SUBSTR Syntax: SUBSTR( $String, %Start[, %Count]) ==> $SubStr Description: Extract a substring f

Pagina 108 - FMODTIME

Chapter 5 Script Commands Scripting Guide 196 SWITCH Syntax: SWITCH...CASE...[DEFAULT...]ENDSWITCH SWITCH Expression CASE SimpleExpr: [comm

Pagina 109

Chapter 5 Script Commands Scripting Guide 197 Example: SWITCH $Msg[ 3] CASE “IOS000I”: //call the IOS000 script to handle IOS000( $Msg[

Pagina 110

Chapter 5 Script Commands Scripting Guide 198 SYSEXEC Syntax: SYSEXEC( $String) ==> %Return Description: Executes a Unix command on the MCC ho

Pagina 111 - FORMATSTR

Chapter 5 Script Commands Scripting Guide 199 TEMP Syntax: TEMP( %Port) ==> %Temp Description: Reads the current temperature from a sensor uni

Pagina 112

Technical Support Contacting the Visara Intellicenter For US domestic customers, Visara provides technical support through its Intellicenter, 8:30 - 5

Pagina 114 - Scripting Guide 114

Chapter 5 Script Commands Scripting Guide 200 TIME Syntax: TIME( [$TimeString]) ==> %MidnightSeconds Description: Converts a time string to a

Pagina 115 - Scripting Guide 115

Chapter 5 Script Commands Scripting Guide 201 TIMESTR Syntax: TIMESTR( %EpochSeconds, $Format) ==> $Formatted Description: Formats epoch secon

Pagina 116

Chapter 5 Script Commands Scripting Guide 202 Date Related Codes for TIMESTR() Code Description Notes/Examples a Weekday short name Mon, Wed A

Pagina 117

Chapter 5 Script Commands Scripting Guide 203 Time Related Codes Code Description Notes/Examples H Hour number for a 24-hour clock with a leadi

Pagina 118 - FRENAME

Chapter 5 Script Commands Scripting Guide 204 TRIMSTR Syntax: TRIMSTR( $String[, %Where]) ==> $Trimmed Description: Removes leading and traili

Pagina 119 - FREWIND

Chapter 5 Script Commands Scripting Guide 205 UPPER Syntax: UPPER( $String) ==> $UpperString Description: Converts lowercase characters to up

Pagina 120 - Action:

Chapter 5 Script Commands Scripting Guide 206 VAL Syntax: VAL( $String) ==> %Number Description: Converts a string expression to a number. Act

Pagina 121

Chapter 5 Script Commands Scripting Guide 207 VERSION Syntax: VERSION() ==> $VersionStr Description: Returns a string giving the product and s

Pagina 122

Chapter 5 Script Commands Scripting Guide 208 WAITFOR Syntax: WAITFOR( %Seconds) Description: Pauses script execution for the specified number of

Pagina 123

Chapter 5 Script Commands Scripting Guide 209 WAITUNTIL Syntax: WAITUNTIL( %MidnightSeconds) Description: Pauses current script execution until t

Pagina 124

Scripting Guide 21 Chapter 2 Advanced Topics This chapter contains:  Script Writing Guidelines  Descriptions of key MCC features, such as ports,

Pagina 125

Chapter 5 Script Commands Scripting Guide 210 WHILE Syntax: WHILE...ENDWHILE WHILE Expression Commands ENDWHILE Description: Repeats a seque

Pagina 126

Scripting Guide 211 Chapter 6 Obsolete Material This chapter:  Lists discontinued intrinsic manifest constants and their replacements.  Describes

Pagina 127 - HMCEXEC

Chapter 6 Obsolete Material Scripting Guide 212 Overview As the Master Console Center has evolved, some constants and commands have been supersede

Pagina 128 - Image-only Commands

Chapter 6 Obsolete Material Scripting Guide 213 Manifest Constants The following table lists discontinued intrinsic manifest constants and their r

Pagina 129

Chapter 6 Obsolete Material Scripting Guide 214 Commands KEY Command (Date and Time Formats) The time and date KEY command formats have been depre

Pagina 130

Chapter 6 Obsolete Material Scripting Guide 215 EVENTCLOSE Syntax: EVENTCLOSE( %QueueID ) ==> %Status Description: Close an event queue. Actio

Pagina 131 - Notes:

Chapter 6 Obsolete Material Scripting Guide 216 EVENTOPEN Syntax: EVENTOPEN( %Source [, $OsNameArray] ) ==> %QueueID Description: Opens a conn

Pagina 132 - ICONMSG

Chapter 6 Obsolete Material Scripting Guide 217 Notes: 1. Currently, the only Event Source supported is “PATROL_EVENTS”. 2. More than one queu

Pagina 133 - ICONNAME

Chapter 6 Obsolete Material Scripting Guide 218 EVENTREAD Syntax: EVENTREAD(%QueueIdArray,$EventArray[,%Wait])==>%Status Description: Returns

Pagina 134 - ICONSTATUS

Chapter 6 Obsolete Material Scripting Guide 219 Returns: Numeric value for %Status, as follows: Value Meaning 0 or event read Success -1

Pagina 135

Chapter 2 Advanced Topics Scripting Guide 22 Script Writing Guidelines The following coding guidelines and style suggestions increase code readabi

Pagina 136

Chapter 6 Obsolete Material Scripting Guide 220 // Close the previously opened queues. *done: %i := 1 WHILE( %i <= ALEN( %queueId ) ) %statu

Pagina 137

Chapter 6 Obsolete Material Scripting Guide 221 MVSCOMMAND Syntax: MVSCOMMAND( %ObjID, $CmdArray, $Output Array, %ErrArray $ErrorTextArray[, %Por

Pagina 138

Chapter 6 Obsolete Material Scripting Guide 222 generated output from each independently submitted command. Use the QREAD() command to process th

Pagina 139

Chapter 6 Obsolete Material Scripting Guide 223 14.23.53 P390 STC00019 GWLU62MC08 D T BY WATCHSNA USERID P390 <======= **

Pagina 140 - KEY Command Return Values

Chapter 6 Obsolete Material Scripting Guide 224 Manifest Constant Value Associated String ICLErr_MvsRsp_0019 10019 Add operator rejected; admin

Pagina 141 - KEY Command Specifics

Chapter 6 Obsolete Material Scripting Guide 225 QUEUE Syntax: QUEUE( Operation[, Port]) Description: Starts (stops and resets) a queue of OS print

Pagina 142 - Keyboard Key Key Command

Chapter 6 Obsolete Material Scripting Guide 226 QUEUE command operation parameter options Operation Constant Description ON Creates a message qu

Pagina 143 - LEFTSTR

Chapter 6 Obsolete Material Scripting Guide 227 READMSG Syntax: READMSG( $Msg, Wait, *Timeout[, Port [, Filter]]) Description: Reads the next mes

Pagina 144

Chapter 6 Obsolete Material Scripting Guide 228 Example: //======================================================= // Example 1 //===============

Pagina 145

Chapter 6 Obsolete Material Scripting Guide 229 TSOEREXX Syntax: TSOEREXX( %ObjID, $CmdArray, %ErrorArray, $ErrorTextArray) ==> %ReturnValue D

Pagina 146

Chapter 2 Advanced Topics Scripting Guide 23  To improve readability, put one blank line before and one after each control structure, such as IF

Pagina 147 - MKDTEMP

Chapter 6 Obsolete Material Scripting Guide 230 Example: // Sample TSOEREXX() call ARESET( $Cmds) ARESET( %Err) ARESET( $ErrMsg) %OsID := OBJID

Pagina 148 - MKSTEMP

Scripting Guide 231 Appendix A ASCII Character Values (including ISO-8859-1 ANSI “Latin 1” values) hex dec Char hex dec Char hex dec Char hex dec

Pagina 149

Scripting Guide 232 (continued from previous page) 80 128 PAD A0 160 NS C0192À E0224à HOP High Octet Preset 81 129 HOP A1 161 ¡ C1193Á E1

Pagina 150 - MONIKER

Scripting Guide 233 Appendix B Command Syntax Appendix B contains two tables:  The first table lists information by command types.  The second ta

Pagina 151 - OBJEXEC

Appendix B Command Syntax Scripting Guide 234 Command Syntax—By Command Type Command Command Type Description Syntax ALARM Alerting Gene

Pagina 152

Appendix B Command Syntax Scripting Guide 235 Command Command Type Description Syntax KEY Console Message Enters a character string to t

Pagina 153 - OBJGETARRAY

Appendix B Command Syntax Scripting Guide 236 EVENTCLOSE Event Closes a specified event queue. Events are no longer available from the

Pagina 154

Appendix B Command Syntax Scripting Guide 237 FPOS File Returns an open file’s current record pointer position. FPOS(%FileNum)==>%Po

Pagina 155

Appendix B Command Syntax Scripting Guide 238 GOSUB Flow Control Immediately transfers script execution to the specified label and waits

Pagina 156 - OBJIDARRAY

Appendix B Command Syntax Scripting Guide 239 WHILE (ENDWHILE) Flow Control Repeats a sequence of commands while an expression evaluates

Pagina 157

Chapter 2 Advanced Topics Scripting Guide 24 MCC Concepts Ports Each MCC console interface has a unique number that is assigned when the system is

Pagina 158

Appendix B Command Syntax Scripting Guide 240 OBJSET Object Manager Populates an associative numeric array with object IDs from the chi

Pagina 159 - OBJSETARRAY

Appendix B Command Syntax Scripting Guide 241 SCRIPTGETACTIVE Scripting Retrieves information on all active scripts into an associative

Pagina 160

Appendix B Command Syntax Scripting Guide 242 WAITUNTIL Time Pauses current script execution until the specified time is reached. WAITU

Pagina 161

Appendix B Command Syntax Scripting Guide 243 FINDSTR Variable Searches a string for a regular expression pattern. FINDSTR($String,$Subs

Pagina 162

Appendix B Command Syntax Scripting Guide 244 LOWER Variable Converts uppercase characters to lowercase. LOWER($String)==>$Lowercase

Pagina 163

Appendix B Command Syntax Scripting Guide 245 VERSION Variable Returns a string giving the product and script language version levels.

Pagina 164

Appendix B Command Syntax Scripting Guide 246 Command Syntax—By Command Command Command Type Description Syntax AICONNAMES Variable Fill

Pagina 165

Appendix B Command Syntax Scripting Guide 247 Command Command Type Description Syntax BASEDIRECTORY Variable Obtains the base directory

Pagina 166 - QPREVIEW

Appendix B Command Syntax Scripting Guide 248 Command Command Type Description Syntax ERRORNUM Misc. Returns the error number for the mo

Pagina 167

Appendix B Command Syntax Scripting Guide 249 Command Command Type Description Syntax FREAD File Reads values from an open file into var

Pagina 168

Chapter 2 Advanced Topics Scripting Guide 25 Object Name The object name is, obviously enough, the name of an object. In object-oriented terms, t

Pagina 169

Appendix B Command Syntax Scripting Guide 250 Command Command Type Description Syntax ICONNAME Alerting Returns an icon’s name. ICONNAM

Pagina 170

Appendix B Command Syntax Scripting Guide 251 MVSCOMMAND Event Enters commands to MVS using the GW-MVS agent (optional software). MVSCO

Pagina 171

Appendix B Command Syntax Scripting Guide 252 QOPEN Console Message Opens a new queue of OS printer console messages. QOPEN([%ObjIDArray]

Pagina 172

Appendix B Command Syntax Scripting Guide 253 SET Variable Make the contents of a variable equal to the specified expression. SETVariabl

Pagina 173

Appendix B Command Syntax Scripting Guide 254 TEMP Physical Interface Control Reads the current temperature from a sensor unit. TEMP(%Po

Pagina 174 - RIGHTSTR

Scripting Guide 255 IndexAICONNAMES Syntax— AICONNAMES( $AssocArray, %Class, $ParentIcon)...71 ALAR

Pagina 175

Index Scripting Guide 256 numeric...43 string...

Pagina 176

Index Scripting Guide 257 Object Manager ...26 icon class ...

Pagina 177 - SCRIPTCANCEL

Index Scripting Guide 258 Syntax—SCRNTEXT( %Port, %Start, %Length) ==> $Text...183 SECONDS S

Pagina 178 - SCRIPTGETACTIVE

Index Scripting Guide 259 ICONSTATUS( [%Class [, $Name]]) ==> %Status...136

Pagina 179

Chapter 2 Advanced Topics Scripting Guide 26 Object ID The Object ID is an integer value generated by the GCL scripting language to refer to an ob

Pagina 180 - Examples:

Index Scripting Guide 260 Syntax—WHILE...ENDWHILE ...212

Pagina 183

Chapter 2 Advanced Topics Scripting Guide 27 Object Action The status of objects can change with time. You can use object actions to wait for tho

Pagina 184 - SNMP_GET

Chapter 2 Advanced Topics Scripting Guide 28 Object Action Type Description Parameters Return Value takes two seconds to perform some processing,

Pagina 185 - SNMP_GETNEXT

Chapter 2 Advanced Topics Scripting Guide 29 Icon Class/Icon Name A script executes on an object in a class. Objects are represented by an icon d

Pagina 186 - SNMP_GETTABLE

Scripting Guide 3 Contents Technical Support ... 2 Contacting the

Pagina 187

Chapter 2 Advanced Topics Scripting Guide 30 The default class and name for a script are determined when the script begins executing:  A script

Pagina 188 - SNMP_SET

Chapter 2 Advanced Topics Scripting Guide 31 SNMP A full discussion of SNMP (Simple Network Management Protocol) is beyond the scope of this guide

Pagina 190

Scripting Guide 33 Chapter 3 Script Syntax This chapter contains:  General Scripting Syntax  Basic Overviews of: − Variables − Date/Time − Exp

Pagina 191

Chapter 3 Script Syntax Scripting Guide 34 General Script Syntax Information General Syntax of a Script The general structure of a script file is

Pagina 192

Chapter 3 Script Syntax Scripting Guide 35  A script file name comprises up to eight characters followed by a period “.” and a fixed three chara

Pagina 193

Chapter 3 Script Syntax Scripting Guide 36 Variables Using and Naming Variables  Variables may be character strings, numerics, or arrays; array

Pagina 194

Chapter 3 Script Syntax Scripting Guide 37 Numeric Variables  Numeric variable names are prefixed with a percent sign “%”.  The maximum value

Pagina 195

Chapter 3 Script Syntax Scripting Guide 38 Arrays Using and Naming Arrays  There are two types of arrays, integer arrays and string arrays. Int

Pagina 196

Chapter 3 Script Syntax Scripting Guide 39 Normal Arrays Normal arrays are indexed by any expression that evaluates to a positive integer value. T

Pagina 197

Contents Scripting Guide 4 Chapter 3 Script Syntax... 33 General S

Pagina 198 - SYSEXEC

Chapter 3 Script Syntax Scripting Guide 40 Date/Time The date and time type functions allow great flexibility in manipulating and formatting of ti

Pagina 199

Chapter 3 Script Syntax Scripting Guide 41 Expressions There are two types of expressions, String and Numeric. String Expressions String expressio

Pagina 200

Chapter 3 Script Syntax Scripting Guide 42 Manifest Constants Intrinsic manifest constants have been defined to make scripts easier to read, write

Pagina 201 - TIMESTR

Chapter 3 Script Syntax Scripting Guide 43 List of Intrinsic Manifest Constants Manifest Error Constants Manifest Error Constants Value Associat

Pagina 202

Chapter 3 Script Syntax Scripting Guide 44 Manifest Error Constants Value Associated String not run. Err_Mvs1 4012 General MVS error. Err_Mvs_

Pagina 203 - Miscellaneous Codes

Chapter 3 Script Syntax Scripting Guide 45 Manifest Error Constants Value Associated String Err_Key_CantReadStatus 5109 Err_Key_ConsoleNotLock

Pagina 204 - TRIMSTR

Chapter 3 Script Syntax Scripting Guide 46 Manifest Error Constants Value Associated String ICLErr_MvsRsp_0022 10022 Cannot delete last admini

Pagina 205

Chapter 3 Script Syntax Scripting Guide 47 Other Manifest Constants Other Manifest Constants Value Assoc. String On 1 True 1 Asc 1 Left 1

Pagina 206

Chapter 3 Script Syntax Scripting Guide 48 Other Manifest Constants Value Assoc. String SkipEnd 2 SkipNext 1 Status_Error 1 Status_Warnin

Pagina 207 - VERSION

Chapter 3 Script Syntax Scripting Guide 49 Other Manifest Constants Value Assoc. String Hmc_SnaAddr HMC_SnaAddr Hmc_MachModel HMC_MachModel

Pagina 208 - WAITFOR

Contents Scripting Guide 5 AICONNAMES... 69 ALARM...

Pagina 209 - WAITUNTIL

Chapter 3 Script Syntax Scripting Guide 50 Operators Mathematical The following mathematical operators may be used in numeric expressions: Charac

Pagina 210

Chapter 3 Script Syntax Scripting Guide 51 The following Boolean syntax may be used: Syntax Means == Equals < Less than > Greater than <=

Pagina 211 - Chapter 6 Obsolete Material

Chapter 3 Script Syntax Scripting Guide 52 Label Statements Label statements are used as a reference point within a script to which processing can

Pagina 212

Scripting Guide 53 Chapter 4 Regular Expressions This chapter discusses regular expressions including:  Bracket expressions  Special characters 

Pagina 213 - Manifest Constants

Chapter 4 Regular Expressions Scripting Guide 54 Regular Expressions Regular expressions (REs) or patterns are textual statements including specia

Pagina 214 - Commands

Chapter 4 Regular Expressions Scripting Guide 55 [^.] Match anything EXCEPT a dot. [^A-Z] Match anything EXCEPT an upper case letter. Subexpres

Pagina 215 - EVENTCLOSE

Chapter 4 Regular Expressions Scripting Guide 56 Rules for Building Regular Expressions When using the rules to build regular expressions (REs), f

Pagina 216 - EVENTOPEN

Chapter 4 Regular Expressions Scripting Guide 57 An RE ordinary character or an RE special character preceded by a backslash or a period matches a

Pagina 217

Chapter 4 Regular Expressions Scripting Guide 58 Inside bracket expressions, the following are true:  The special characters ‘.’ , ‘*’, ‘[‘, an

Pagina 218 - EVENTREAD

Chapter 4 Regular Expressions Scripting Guide 59 The rules in Table 9. Bracket Expression Rules. apply to:  Creating and using matching and non

Pagina 219 - Returns:

Contents Scripting Guide 6 HEXSTR... 126 HMCEXE

Pagina 220

Chapter 4 Regular Expressions Scripting Guide 60 Bracket Expression Rule Description Equivalence Class Expression Specifies a set of collating el

Pagina 221 - MVSCOMMAND

Chapter 4 Regular Expressions Scripting Guide 61 Matching Multiple Characters in Bracket Expressions The following rules are used to build multipl

Pagina 222

Chapter 4 Regular Expressions Scripting Guide 62 Alternation If ’x’ and ‘y’ are REs, then ‘x|y’ is an RE matching any string that is matched by ei

Pagina 223 - Possible Error Codes

Chapter 4 Regular Expressions Scripting Guide 63 Precedence of Special Characters The order of precedence, from high to low, is shown below: Order

Pagina 224

Chapter 4 Regular Expressions Scripting Guide 64 Special Characters in Regular Expressions Table 12. Regular Expressions, Special Characters desc

Pagina 225

Chapter 4 Regular Expressions Scripting Guide 65 Character Description the quantity. | OR. "A|B" matches either "A" or "

Pagina 227 - READMSG

Scripting Guide 67 Chapter 5 Script Commands This chapter:  Discusses the types of script commands  Gives information about script syntax  Lis

Pagina 228

Chapter 5 Script Commands Scripting Guide 68 Conventions in this Chapter When writing scripts, text placed in brackets “[]” is an optional paramet

Pagina 229 - TSOEREXX

Chapter 5 Script Commands Scripting Guide 69 AICONNAMES Syntax: AICONNAMES( $AssocArray, %Class, $ParentIcon) Description: Fill an array with all

Pagina 230

Contents Scripting Guide 7 SNMP_GETTABLE... 186 SNMP_SET...

Pagina 231

Chapter 5 Script Commands Scripting Guide 70 ALARM Syntax: ALARM( %Operation) Description: Generates a repetitive alarm tone (beep) at the MCC te

Pagina 232

Chapter 5 Script Commands Scripting Guide 71 ALERTCREATE Syntax: ALERTCREATE( %Status, %State, $Source, $MsgText, $UserNote) ==> %AlertID Desc

Pagina 233 - Appendix B Command Syntax

Chapter 5 Script Commands Scripting Guide 72 ALERTDEL Syntax: ALERTDEL( %AlertID) ==> %ErrCode Description: Deletes an existing Alert. Action:

Pagina 234 - Description Syntax

Chapter 5 Script Commands Scripting Guide 73 ALERTGETACTIVE Syntax: ALERTGETACTIVE($AssocArray) ==>%ErrCode Description: Retrieves information

Pagina 235

Chapter 5 Script Commands Scripting Guide 74 $AlertInfo[14] 'Quilt' source computer/OS $AlertInfo[15] message $AlertInfo[16] &a

Pagina 236

Chapter 5 Script Commands Scripting Guide 75 See Also: ALERTMOD, ALERTCREATE, ALERTDEL

Pagina 237

Chapter 5 Script Commands Scripting Guide 76 ALERTMOD Syntax: ALERTMOD( %AlertID, %AlertField, NewValue) ==> %ErrCode Description: Modifies th

Pagina 238 - (ENDIF) Flow

Chapter 5 Script Commands Scripting Guide 77 ARESET Syntax: ARESET( Array) Description: Reset the contents of an array to “empty”. Action: All el

Pagina 239 - (ENDWHILE) Flow

Chapter 5 Script Commands Scripting Guide 78 ASCII Syntax: ASCII( $String) ==> %Value Description: Given a string $String, returns the integer

Pagina 240

Chapter 5 Script Commands Scripting Guide 79 ASCRN Syntax: ASCRN( $Array, %Port) Description: Fill an array with the full text of a console scree

Pagina 241

Contents Scripting Guide 8 List of Tables Table 1. List of MCC Reserved Scripts executed in response to status changes...

Pagina 242

Chapter 5 Script Commands Scripting Guide 80 ASORT Syntax: ASORT( NormArray, %Direction) Description: Sort a normal array. Action: The data eleme

Pagina 243

Chapter 5 Script Commands Scripting Guide 81 ASSOCKEYS Syntax: ASSOCKEYS( AssocArray, $NormArray) ==> %RetVal Description: Populate a normal s

Pagina 244

Chapter 5 Script Commands Scripting Guide 82 ATSTR Syntax: ATSTR( $String, $Substring) ==> %StartPos Description: Returns the starting positio

Pagina 245

Chapter 5 Script Commands Scripting Guide 83 BASEDIRECTORY Syntax: BASEDIRECTORY() ==> $DirectoryString Description: Obtains the base directory

Pagina 246 - Command Syntax—By Command

Chapter 5 Script Commands Scripting Guide 84 BLOCKSCAN Syntax: BLOCKSCAN( %Wait, *Timeout [, $Array]) ...ENDBLOCK Description: Enables up to 256

Pagina 247

Chapter 5 Script Commands Scripting Guide 85 See Also: SCANB, SCANP

Pagina 248

Chapter 5 Script Commands Scripting Guide 86 CHR Syntax: CHR( %Number) ==> $String Description: Given an integer in the range 0 to 255, return

Pagina 249

Chapter 5 Script Commands Scripting Guide 87 CLASSNAME Syntax: CLASSNAME( [%Class]) ==> $ClassName Description: Returns the class name for a c

Pagina 250

Chapter 5 Script Commands Scripting Guide 88 CLASSNUM Syntax: CLASSNUM( [$ClassName]) ==> %Class Description: Returns the class number for a c

Pagina 251

Chapter 5 Script Commands Scripting Guide 89 CPUPOWER Syntax: CPUPOWER( %Port, %Operation) Description: Switches a CPU’s power ON or OFF. Action:

Pagina 252

Scripting Guide 9 About This Guide Purpose of This Guide This guide illustrates the Master Console Center Global Control Language (MCC GCL). It assu

Pagina 253

Chapter 5 Script Commands Scripting Guide 90 DATE Syntax: DATE( [$DateString]) ==> %EpochSeconds Description: Converts a date string to a date

Pagina 254

Chapter 5 Script Commands Scripting Guide 91 DEC Syntax: DEC %Variable Description: Subtracts one from a numeric variable’s value. Action: The va

Pagina 255 - Scripting Guide 255

Chapter 5 Script Commands Scripting Guide 92 DECODE Syntax: DECODE ($String[, $Key]) ==> $Result Description: Decodes a GCL string, for exampl

Pagina 256 - Scripting Guide 256

Chapter 5 Script Commands Scripting Guide 93 DIUNIT Syntax: DIUNIT( %Port) ==> %Status Description: Check the status of a device connected to

Pagina 257 - Scripting Guide 257

Chapter 5 Script Commands Scripting Guide 94 DOUNIT Syntax: DOUNIT( %Port[, %Operation]) ==> %DOSwitch Description: Controls the device connec

Pagina 258 - Scripting Guide 258

Chapter 5 Script Commands Scripting Guide 95 ENCODE Syntax: ENCODE ($String[,$Key]) ==> $Result Description: Encodes a GCL string, for example

Pagina 259 - Scripting Guide 259

Chapter 5 Script Commands Scripting Guide 96 END Syntax: END Description: Ends the execution of the script thread. Action: The execution of the c

Pagina 260 - Scripting Guide 260

Chapter 5 Script Commands Scripting Guide 97 ERRORMSG Syntax: ERRORMSG( %ErrNum)==> $ErrMsg Description: Returns the error message associated

Pagina 261

Chapter 5 Script Commands Scripting Guide 98 ERRORNUM Syntax: ERRORNUM() ==> %ErrNum Description: Returns the error number for the most recent

Pagina 262 - 707131-001

Chapter 5 Script Commands Scripting Guide 99 Manifest Constant Value Associated String/Reason Support. Err_Mvs_NoComm 4001 Unable to communicate

Commenti su questo manuale

Nessun commento