0% found this document useful (0 votes)
243 views

1703 PAC Control Commands Quick Reference

Opto 22

Uploaded by

jotaruiz30
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
243 views

1703 PAC Control Commands Quick Reference

Opto 22

Uploaded by

jotaruiz30
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Chapter 1

Commands Quick Reference


Commands with an asterisk* are available only in PAC Control Professional. The Type column
shows whether the OptoScript command is a function command (F) or a procedure command
(P). Function commands return a value from their action; procedure commands do not.

Analog Point
PAC Control Command
Calculate & Set Analog Gain
Calculate & Set Analog Offset
Get & Clear Analog Filtered Value*
Get & Clear Analog Maximum Value
Get & Clear Analog Minimum Value
Get & Clear Analog Totalizer Value
Get Analog Filtered Value*
Get Analog Maximum Value
Get Analog Minimum Value
Get Analog Square Root Filtered Value*
Get Analog Sqaure Root Value*
Get Analog Totalizer Value
Ramp Analog Output
Set Analog Filter Weight
Set Analog Gain
Set Analog Load Cell Fast Settle Level
Set Analog Load Cell Filter Weight
Set Analog Offset
Set Analog Totalizer Rate
Set Analog TPO Period

OptoScript Equivalent (Arguments)


CalcSetAnalogGain(On Point)
CalcSetAnalogOffset(On Point)
GetClearAnalogFilteredValue(From)
GetClearAnalogMaxValue(From)
GetClearAnalogMinValue(From)
GetClearAnalogTotalizerValue(From)
GetAnalogFilteredValue(From)
GetAnalogMaxValue(From)
GetAnalogMinValue(From)
GetAnalogSquareRootFilteredValue(From)
GetAnalogSquareRootValue(From)
GetAnalogTotalizerValue(From)
RampAnalogOutput(Ramp Endpoint, Units/Sec, Point to Ramp)
SetAnalogFilterWeight(To, On Point)
SetAnalogGain(To, On Point)
SetAnalogLoadCellFastSettleLevel(To, On Point)
SetAnalogLoadCellFilterWeight(To, On Point)
SetAnalogOffset(To, On Point)
SetAnalogTotalizerRate(To Seconds, On Point)
SetAnalogTpoPeriod(To, On Point)

Type

F
F
F
F
F
F
F
F
F
F
F
F
P
P
P
P
P
P
P
P

Chart
PAC Control Command
Call Chart
Calling Chart Running?
Calling Chart Stopped?
Calling Chart Suspended?
Chart Running?
Chart Stopped?
Chart Suspended?
Continue Calling Chart
Continue Chart
Get Chart Status
Start Chart
Stop Chart
Suspend Chart

OptoScript Equivalent (Arguments)


CallChart(Chart)
IsCallingChartRunning()
IsCallingChartStopped()
IsCallingChartSuspended()
IsChartRunning(Chart)
IsChartStopped(Chart)
IsChartSuspended(Chart)
ContinueCallingChart()
ContinueChart(Chart)
GetChartStatus(Chart)
StartChart(Chart)
StopChart(Chart)
SuspendChart(Chart)

1703-120305PAC Control Commands Quick Reference

Type

F
F
F
F
F
F
F
F
F
F
F
F
F

11

Communication
PAC Control Command
Accept Incoming Communication
Clear Communication Receive Buffer
Close Communication
Communication Open?
Get Active Interrupt Mask
Get Communication Handle Value
Get End-Of-Message Terminator
Get Number of Characters Waiting

OptoScript Equivalent (Arguments)


Type
AcceptIncomingCommunication(Communication Handle)
F
ClearCommunicationReceiveBuffer(Communication Handle)
P
CloseCommunication(Communication Handle)
F
IsCommunicationOpen(Communication Handle)
F
GetActiveInterruptMask()
F
GetCommunicationHandleValue(From, To)
F
GetEndOfMessageTerminator (Communication Handle)
F
GetNumCharsWaiting(On Communication Handle)
F
HttpGet(Response Content, Response Header, Get Header, Security
F
HTTP Get
Mode, URL Path, Put HTTP Status In, Port, Hostname)
HttpPostFromStringTable(Response Content, Response Header, Post
F
HTTP Post from String Table
Content, Post Header, Security Mode, URL Path, Put HTTP Status
In, Port, Hostname)
HTTP Post Calculate Content Length HttpPostCalcContentLength(Post Content, Post Header, Length Index)
F
ListenForIncomingCommunication(Communication Handle)
Listen for Incoming Communication
F
OpenOutgoingCommunication(Communication Handle)
Open Outgoing Communication
F
ReceiveChar(Communication Handle)
Receive Character
F
ReceiveNChars(Put In, Number of Characters, Communication Handle)
Receive N Characters
F
ReceiveNumTable
F
Receive Numeric Table
(Length, Start at Index, Of Table, Communication Handle)
ReceiveNumTableEx
F
Receive Numeric Table Ex
(Length, Start at Index, Endian Mode, Bytes per Value, Of Table,
Communication Handle)
ReceiveNumVariable
F
Receive Numeric Variable
(Endian mode, Number of Bytes, Put in, Communication Handle)
ReceivePtrTable
F
Receive Pointer Table
(Length, Start at Index, Of Table, Communication Handle)
ReceiveString(Put In, Communication Handle)
Receive String
F
ReceiveStrTable
F
Receive String Table
(Length, Start at Index, Of Table, Communication Handle)
Send Communication Handle Command SendCommunicationHandleCommand(Communication Handle, Command)
F
SendEmail(Server Information, Recipients, Message Body)
Send Email
F
SendEmailWithAttachments (Server Information, Recipients, Message
F
Send Email with Attachments
Body, Attachment File Names)
SetCommunicationHandleValue(Value, Communication Handle)
Set Communication Handle Value
P
SetEndOfMessageTerminator(Communication Handle, To Character)
Set End-Of-Message Terminator
P
TransferNChars(Destination Handle, Source Handle, Num Chars)
Transfer N Characters
F
TransmitChar(Character, Communication Handle)
Transmit Character
F
TransmitNewLine(Communication Handle)
Transmit NewLine
F
TransmitNumTable
F
Transmit Numeric Table
(Length, Start at Index, Of Table, Communication Handle)
TransmitPtrTable
F
Transmit Pointer Table
(Length, Start at Index, Of Table, Communication Handle)
TransReceMisticIoHexStringWithCrc
F
Transmit/Receive Mistic I/O Hex String*
(Hex String, On Port, Put Result in)
TransmitReceiveString(String, Communication Handle, Put Result in)
Transmit/Receive String
F
TransmitString(String, Communication Handle)
Transmit String
F
TransmitStrTable
F
Transmit String Table
(Length, Start at Index, Of Table, Communication Handle)

Control Engine
PAC Control Command
Calculate Strategy CRC
Erase Files in Permanent Storage
Get Available File Space
Get Control Engine Address
Get Control Engine Type
Get Firmware Version
Load Files From Permanent Storage
Retrieve Strategy CRC
Save Files To Permanent Storage

Copyright 2012 Opto 22

OptoScript Equivalent (Arguments)


CalcStrategyCrc()
EraseFilesInPermanentStorage()
GetAvailableFileSpace(File System Type)
GetControlEngineAddress()
GetEngineType()
GetFirmwareVersion(Put in)
LoadFilesFromPermanentStorage()
RetrieveStrategyCrc()
SaveFilesToPermanentStorage()

Type

F
F
F
F
F
P
F
F
F

Control Engine (Continued)


PAC Control Command
Start Alternate Host Task

OptoScript Equivalent (Arguments)


StartAlternateHostTask()

Type

Digital Point
PAC Control Command
Clear All Latches
Clear Counter
Clear Off-Latch
Clear On-Latch

OptoScript Equivalent (Arguments)


Type
ClearAllLatches(On I/O Unit)
P
ClearCounter(On Point)
P
ClearOffLatch(On Point)
P
ClearOnLatch(On Point)
P
GenerateNPulses
P
Generate N Pulses
(On Time (Seconds), Off Time (Seconds), Number of Pulses, On Point)
GetClearCounter(From Point)
Get & Clear Counter
F
GetClearOffLatch(From Point)
Get & Clear Off-Latch
F
GetClearOnLatch(From Point)
Get & Clear On-Latch
F
GetRestartOffPulseMeasurement(From Point)
Get & Restart Off-Pulse Measurement
F
GetRestartOffTimeTotalizer(From Point)
Get & Restart Off-Time Totalizer
F
GetRestartOnPulseMeasurement(From Point)
Get & Restart On-Pulse Measurement
F
GetRestartOnTimeTotalizer(From Point)
Get & Restart On-Time Totalizer
F
GetRestartPeriod(From Point)
Get & Restart Period
F
GetCounter(From Point)
Get Counter
F
GetFrequency(From Point)
Get Frequency
F
GetOffLatch(From Point)
Get Off-Latch
F
GetOffPulseMeasurement(From Point)
Get Off-Pulse Measurement
F
GetOffPulseMeasurementCompleteStatus(From Point)
Get Off-Pulse Measurement Complete Status
F
GetOffTimeTotalizer(From Point)
Get Off-Time Totalizer
F
GetOnLatch(From Point)
Get On-Latch
F
GetOnPulseMeasurement(From Point)
Get On-Pulse Measurement
F
GetOnPulseMeasurementCompleteStatus(From Point)
Get On-Pulse Measurement Complete Status
F
GetOnTimeTotalizer(From Point)
Get On-Time Totalizer
F
GetPeriod(From Point)
Get Period
F
Get Period Measurement Complete Status GetPeriodMeasurementCompleteStatus(From Point)
F
IsOff(Point)
Off?
F
IsOffLatchSet(On Point)
Off-Latch Set?
F
IsOn(Point)
On?
F
IsOnLatchSet(On Point)
On-Latch Set?
F
SetTpoPercent(To Percent, On Point)
Set TPO Percent
P
SetTpoPeriod(To Seconds, On Point)
Set TPO Period
P
StartContinuousSquareWave
P
Start Continuous Square Wave
(On Time (Seconds), Off Time (Seconds), On Point)
StartCounter(On Point)
Start Counter
P
StartOffPulse(Off Time (Seconds), On Point)
Start Off-Pulse
P
StartOnPulse(On Time (Seconds), On Point)
Start On-Pulse
P
StopCounter(On Point)
Stop Counter
P
TurnOff(Output)
Turn Off
P
TurnOn(Output)
Turn On
P

Error Handling
PAC Control Command
Add Message to Queue
Add User Error to Queue
Add User I/O Unit Error to Queue
Caused a Chart Error?
Caused an I/O Unit Error?
Clear All Errors
Copy Current Error to String
Disable I/O Unit Causing Current Error
Enable I/O Unit Causing Current Error

OptoScript Equivalent (Arguments)


AddMessageToQueue(Severity, Message)
AddUserErrorToQueue(Error Number)
AddUserIoUnitErrorToQueue(Error Number, I/O Unit)
HasChartCausedError(Chart)
HasIoUnitCausedError(I/O Unit)
ClearAllErrors()
CurrentErrorToString(Delimiter, String)
DisableIoUnitCausingCurrentError()
EnableIoUnitCausingCurrentError()

1703-120305PAC Control Commands Quick Reference

Type

P
P
P
F
F
P
P
P
P

33

Error Handling (Continued)


PAC Control Command
Error?
Error on I/O Unit?
Get Error Code of Current Error
Get Error Count
Get ID of Block Causing Current Error
Get Line Causing Current Error
Get Name of Chart Causing Current Error
Get Name of I/O Unit Causing Current Error
Get Severity of Current Error
Remove Current Error and Point to Next Error
Stop Chart on Error
Suspend Chart on Error

OptoScript Equivalent (Arguments)


IsErrorPresent()
IsErrorOnIoUnit()
GetErrorCodeOfCurrentError()
GetErrorCount()
GetIdOfBlockCausingCurrentError()
GetLineCausingCurrentError()
GetNameOfChartCausingCurrentError(Put in)
GetNameOfIoUnitCausingCurrentError(Put in)
GetSeverityOfCurrentError()
RemoveCurrentError()
StopChartOnError()
SuspendChartOnError()

Type

F
F
F
F
F
F
P
P
F
P
P
F

I/O Unit
PAC Control Command
Clear I/O Unit Congfigured Flag
Get I/O Unit as Binary Value
Get I/O Unit as Binary Value 64
Get Target Address State*
I/O Unit Ready?
IVAL Move Numeric Table to I/O Unit

OptoScript Equivalent (Arguments)


Type
ClearIoUnitConfiguredFlag(I/O Unit)
P
GetIoUnitAsBinaryValue(I/O Unit)
F
GetIoUnitAsBinaryValue64(I/O Unit)
F
GetTargetAddressState(Enable Mask, Active Mask, I/O Unit)
P
IsIoUnitReady(I/O Unit)
F
IvalMoveNumTableToIoUnit(Start at Index, Of Table, Move to)
P
P
IVAL Move Numeric Table to I/O Unit Ex IvalMoveNumTableToIoUnitEx
(From Table, With Starting Index, To I/O Unit)
MoveIoUnitToNumTable(I/O Unit, Starting Index, Of Table)
Move I/O Unit to Numeric Table
P
MoveIoUnitToNumTableEx(From I/O Unit, To Table, With Starting Index) P
Move I/O Unit to Numeric Table Ex
MoveNumTableToIoUnit(Start at Index, Of Table, Move to)
Move Numeric Table to I/O Unit
P
MoveNumTableToIoUnitEx(From Table, With Starting Index, To I/O Unit) P
Move Numeric Table to I/O Unit Ex
SetAllTargetAddressStates(Must-On Mask, Must-Off Mask, Active Mask)
Set All Target Address States*
P
SetIoUnitConfiguredFlag(For I/O Unit)
Set I/O Unit Configured Flag
P
SetIoUnitFromMomo(Must-On Mask, Must-Off Mask, Digital I/O Unit)
Set I/O Unit from MOMO Masks
P
SetTargetAddressState
P
Set Target Address State*
(Must-On Mask, Must-Off Mask, Active Mask, I/O Unit)
WriteIoUnitConfigToEeprom(On I/O Unit)
Write I/O Unit Configuration to EEPROM
P

I/O UnitEvent Message


PAC Control Command
Get I/O Unit Event Message State
Get I/O Unit Event Message Text
Set I/O Unit Event Message State
Set I/O Unit Event Message Text

OptoScript Equivalent (Arguments)


GetIoUnitEventMsgState(I/O Unit, Event Message #, Put Result in)
GetIoUnitEventMsgText(I/O Unit, Event Message #, Put Result in)
SetIoUnitEventMsgState(I/O Unit, Event Message #, State)
SetIoUnitEventMsgText(I/O Unit, Event Message #, Message Text)

Type

F
F
F
F

I/O UnitMemory Map


PAC Control Command
Read Number from I/O Unit Memory Map

OptoScript Equivalent (Arguments)


ReadNumFromIoUnitMemMap(I/O Unit, Mem address, To)
ReadNumTableFromIoUnitMemMap
Read Numeric Table from I/O Unit Memory Map
(Length, Start Index, I/O Unit, Mem address, To)
ReadStrFromIoUnitMemMap(Length, I/O Unit, Mem address, To)
Read String from I/O Unit Memory Map
Read String Table from I/O Unit Memory Map ReadStrTableFromIoUnitMemMap
(Length, Start Index, I/O Unit, Mem address, To)
WriteNumToIoUnitMemMap(I/O Unit, Mem address, Variable)
Write Number to I/O Unit Memory Map
Write Numeric Table to I/O Unit Memory Map WriteNumTableToIoUnitMemMap
(Length, Start Index, I/O Unit, Mem address, Table)
WriteStrTableToIoUnitMemMap
Write String Table to I/O Unit Memory Map
(Length, Start Index, I/O Unit, Mem address, Table)

Copyright 2012 Opto 22

Type

F
F
F
F
F
F
F

I/O UnitMemory Map (Continued)


PAC Control Command
Write String to I/O Unit Memory Map

OptoScript Equivalent (Arguments)


WriteStrToIoUnitMemMap(I/O Unit, Mem address, Variable)

Type

I/O UnitScratch Pad


PAC Control Command
Get I/O Unit Scratch Pad Bits
Get I/O Unit Scratch Pad Float Element

OptoScript Equivalent (Arguments)


Type
GetIoUnitScratchPadBits(I/O Unit, Put Result in)
F
GetIoUnitScratchPadFloatElement(I/O Unit, Index, Put Result in) F
GetIoUnitScratchPadFloatTable
F
Get I/O Unit Scratch Pad Float Table
(I/O Unit, Length, From Index, To Index, To Table)
Get I/O Unit Scratch Pad Integer 32 Element GetIoUnitScratchPadInt32Element(I/O Unit, Index, Put Result in) F
GetIoUnitScratchPadInt32Table
F
Get I/O Unit Scratch Pad Integer 32 Table
(I/O Unit, Length, From Index, To Index, To Table)
GetIoUnitScratchPadStringElement
F
Get I/O Unit Scratch Pad String Element
(I/O Unit, Index, Put Result in)
GetIoUnitScratchPadStringTable
F
Get I/O Unit Scratch Pad String Table
(I/O Unit, Length, From Index, To Index, To Table)
F
Set I/O Unit Scratch Pad Bits from MOMO Mask SetIoUnitScratchPadBitsFromMomo
(I/O Unit, Must-On Mask, Must-Off Mask)
SetIoUnitScratchPadFloatElement(I/O Unit, Index, From)
Set I/O Unit Scratch Pad Float Element
F
SetIoUnitScratchPadFloatTable
F
Set I/O Unit Scratch Pad Float Table
(I/O Unit, Length, To Index, From Index, From Table)
Set I/O Unit Scratch Pad Integer 32 Element SetIoUnitScratchPadInt32Element(I/O Unit, Index, From)
F
SetIoUnitScratchPadInt32Table
F
Set I/O Unit Scratch Pad Integer 32 Table
(I/O Unit, Length, To Index, From Index, From Table)
SetIoUnitScratchPadStringElement(I/O Unit, Index, From)
Set I/O Unit Scratch Pad String Element
F
SetIoUnitScratchPadStringTable
F
Set I/O Unit Scratch Pad String Table
(I/O Unit, Length, To Index, From Index, From Table)

Logical
PAC Control Command
AND
AND?
Bit AND
Bit AND?
Bit Clear
Bit Change
Bit Copy
Bit NOT
Bit NOT?
Bit Off in Numeric Table Element?
Bit Off?
Bit On in Numeric Table Element?
Bit On?
Bit OR
Bit OR?
Bit Rotate
Bit Set
Bit Shift
Bit Test
Bit XOR
Bit XOR?
Equal to Numeric Table Element?
Equal?
Flip Flop JK
Float to Int32 Bits
Get High Bits of Integer 64
Get Low Bits of Integer 64
Greater Than Numeric Table Element?

OptoScript Equivalent (Arguments)


x and y
See AND
x bitand y
See Bit AND
BitClear(Item, Bit to Clear)
BitChange(Set flag, Bit to Change, Output)
BitCopy(Server Bit to Set, Destination, Destination Index,
Bit to Read, Source, Source Index)
bitnot x
See Bit NOT
IsBitOffInNumTableElement(At Index, Of Table, Bit)
IsBitOff(In, Bit)
IsBitOnInNumTableElement(At Index, Of Table, Bit)
IsBitOn(In, Bit)
x bitor y
See Bit OR
BitRotate(Item, Count)
BitSet(Item, Bit to Set)
x << nBitsToShift
BitTest(Item, Bit to Test)
x bitxor y
See Bit XOR
n == nt[0]
x == y
FlipFlopJK(Set [J], Reset [K], Output [Q])
FloatToInt32Bits(Server URL)
GetHighBitsOfInt64(High Bits From)
GetLowBitsOfInt64(Integer 64)
x > nt[0]

1703-120305PAC Control Commands Quick Reference

Type

F
F
F
F
F
P
F
F
F
F
F
F
F
F
F
F
F
F
F
F
F
F
F
P
F
F
F
F

55

Logical (Continued)
PAC Control Command
Greater Than or Equal to Numeric Table Element?
Greater Than or Equal?
Greater?
Int32 to Float Bits
Less Than Numeric Table Element?
Less Than or Equal to Numeric Table Element?
Less Than or Equal?
Less?
Make Integer 64
Move 32 Bits
NOT
Not Equal to Numeric Table Element?
Not Equal?
NOT?
Numeric Table Element Bit Clear
Numeric Table Element Bit Set
Numeric Table Element Bit Test
OR
OR?
Set Variable False
Set Variable True
Test Equal
Test Greater
Test Greater or Equal
Test Less
Test Less or Equal
Test Not Equal
Test Within Limits
Variable False?
Variable True?
Within Limits?
XOR
XOR?

OptoScript Equivalent (Arguments)


x >= t[0]
x >= y
x > y
Int32ToFloatBits(nInt32)
x < nt[0]
x <= nt[0]
x <= y
x < y
MakeInt64(High Integer, Low Integer)
Move32Bits(From, To)
not x
n <> nt[0]
x <> y
not x
NumTableElementBitClear
(Element Index, Of Integer Table, Bit to Clear)
NumTableElementBitSet
(Element Index, Of Integer Table, Bit to Set)
NumTableElementBitTest
(Element Index, Of Integer Table, Bit to Test)
x or y
See OR
SetVariableFalse(Variable)
SetVariableTrue(Variable)
See Equal?
See Greater?
See Greater Than or Equal?
See Less?
See Less Than or Equal?
See Not Equal?
See Within Limits?
IsVariableFalse(Variable)
IsVariableTrue(Variable)
IsWithinLimits(Value, Low Limit, High Limit)
x xor y
See XOR

Type

F
F
F
F
F
F
F
F
F
P
F
F
F
F
P
P
F
F
F
P
P
F
F
F
F
F
F
F
F
F
F
F
F

Mathematical
PAC Control Command
Absolute Value
Add
Arccosine
Arcsine
Arctangent
Clamp Float Table Element
Clamp Float Variable
Clamp Integer 32 Table Element
Clamp Integer 32 Variable
Complement
Cosine
Decrement Variable
Divide
Generate Random Number
Hyperbolic Cosine
Hyperbolic Sine
Hyperbolic Tangent
Increment Variable

OptoScript Equivalent (Arguments)


AbsoluteValue(Of)
x + y
Arccosine(Of)
Arcsine(Of)
Arctangent(Of)
ClampFloatTableElement
(High Limit, Low Limit, Element
ClampFloatVariable(High Limit, Low
ClampInt32TableElement
(High Limit, Low Limit, Element
ClampInt32Variable(High Limit, Low
-x
Cosine(Of)
DecrementVariable(Variable)
x / y
GenerateRandomNumber()
HyperbolicCosine(Of)
HyperbolicSine(Of)
HyperbolicTangent(Of)
IncrementVariable(Variable)

Copyright 2012 Opto 22

Type

Index, Of Float Table)


Limit, Float Variable)
Index, Of Integer 32 Table)
Limit, Integer 32 Variable)

F
F
F
F
F
P
P
P
P
P
F
P
F
F
F
F
F
P

Mathematical (Continued)
PAC Control Command
Maximum
Minimum
Modulo
Multiply
Natural Log
Raise e to Power
Raise to Power
Round
Seed Random Number
Sine
Square Root
Subtract
Tangent
Truncate

OptoScript Equivalent (Arguments)


Max(Compare, With)
Min(Compare, With)
x % y
x * y
NaturalLog(Of)
RaiseEToPower(Exponent)
Power(Raise, To the)
Round(Value)
SeedRandomNumber()
Sine(Of)
SquareRoot(Of)
x - y
Tangent(Of)
Truncate(Value)

Type

F
F
F
F
F
F
F
F
P
F
F
F
F
F

Miscellaneous
PAC Control Command
Comment (Block)
Comment (Single Line)
Flag Lock
Flag Unlock
Float Valid?

OptoScript Equivalent (Arguments)


Type
/* block comment */
P
// single line comment
F
FlagLock(Flag, Timeout)
F
FlagUnlock(Flag, Force unlock)
F
IsFloatValid(Float)
F
F
Generate Reverse CRC-16 on Table (32 bit) GenerateReverseCrc16OnTable32
(Start Value, Table, Starting Element, Number of Elements)
GetLengthOfTable(Table)
Get Length of Table
F
GetTypeFromName(Name)
Get Type From Name
F
GetValueFromName(Name, Put Result In)
Get Value From Name
F
x = y;
Move
P
x = nt[0];
Move from Numeric Table Element
F
nt1[0] = nt2[5];
Move Numeric Table Element to Numeric Table
P
MoveNumTableToNumTable
P
Move Numeric Table to Numeric Table
(From Table, From Index, To Table, To Index, Length)
nt[0] = x;
Move to Numeric Table Element
P
MoveToNumTableElements(From, Start Index, End Index, Of Table) P
Move to Numeric Table Elements
ShiftNumTableElements(Shift Count, Table)
Shift Numeric Table Elements
P

PIDEthernet
PAC Control Command
Get PID Configuration Flags
Get PID Current Input
Get PID Current Setpoint
Get PID Feed Forward
Get PID Feed Forward Gain
Get PID Forced Output When Input Over Range
Get PID Forced Output When Input Under Range
Get PID Gain
Get PID Input
Get PID Input High Range
Get PID Input Low Range
Get PID Max Output Change
Get PID Min Output Change
Get PID Mode
Get PID Output
Get PID Output High Clamp
Get PID Output Low Clamp
Get PID Scan Time

OptoScript Equivalent (Arguments)


GetPidConfigFlags(PID Loop)
GetPidCurrentInput(PID Loop)
GetPidCurrentSetpoint(PID Loop)
GetPidFeedForward(PID Loop)
GetPidFeedForwardGain(PID Loop)
GetPidForcedOutputWhenInputOverRange(PID Loop)
GetPidForcedOutputWhenInputUnderRange(PID Loop)
GetPidGain(PID Loop)
GetPidInput(PID Loop)
GetPidInputHighRange(PID Loop)
GetPidInputLowRange(PID Loop)
GetPidMaxOutputChange(PID Loop)
GetPidMinOutputChange(PID Loop)
GetPidMode(PID Loop)
GetPidOutput(PID Loop)
GetPidOutputHighClamp(PID Loop)
GetPidOutputLowClamp(PID Loop)
GetPidScanTime(PID Loop)

1703-120305PAC Control Commands Quick Reference

Type

F
F
F
F
F
F
F
F
F
F
F
F
F
F
F
F
F
F

77

PIDEthernet (Continued)
PAC Control Command
Get PID Setpoint
Get PID Status Flags
Get PID Tune Derivative
Get PID Tune Integral
Set PID Configuration Flags
Set PID Feed Forward
Set PID Feed Forward Gain
Set PID Forced Output When Input Over Range
Set PID Forced Output When Input Under Range
Set PID Gain
Set PID Input
Set PID Input High Range
Set PID Input Low Range
Set PID Max Output Change
Set PID Min Output Change
Set PID Mode
Set PID Output
Set PID Output High Clamp
Set PID Output Low Clamp
Set PID Scan Time
Set PID Setpoint
Set PID Tune Derivative
Set PID Tune Integral

OptoScript Equivalent (Arguments)


Type
GetPidSetpoint(PID Loop)
F
GetPidStatusFlags(PID Loop)
F
GetPidTuneDerivative(PID Loop)
F
GetPidTuneIntegral(PID Loop)
F
SetPidConfigFlags(PID Loop, Configuration Flags)
P
SetPidFeedForward(PID Loop, Feed Forward)
P
SetPidFeedForwardGain(PID Loop, Feed Fwd Gain)
P
SetPidForcedOutputWhenInputOverRange(PID Loop, Forced Output) P
SetPidForcedOutputWhenInputUnderRange(PID Loop, Forced Output) P
SetPidGain(PID Loop, Gain)
P
SetPidInput(PID Loop, Input)
P
SetPidInputHighRange(PID Loop, High Range)
P
SetPidInputLowRange(PID Loop, Low Range)
P
SetPidMaxOutputChange(PID Loop, Max Change)
P
SetPidMinOutputChange(PID Loop, Min Change)
P
SetPidMode(PID Loop, Mode)
P
SetPidOutput(PID Loop, Output)
P
SetPidOutputHighClamp(PID Loop, High Clamp)
P
SetPidOutputLowClamp(PID Loop, Low Clamp)
P
SetPidScanTime(PID Loop, Scan Time)
P
SetPidSetpoint(PID Loop, Setpoint)
P
SetPidTuneDerivative(PID Loop, Derivative)
P
SetPidTuneIntegral(PID Loop, Integral)
P

Pointers
PAC Control Command
Clear Pointer
Clear Pointer Table Element
Get Pointer From Name
Move from Pointer Table Element
Move to Pointer
Move to Pointer Table Element
Pointer Equal to Null?
Pointer Table Element Equal to Null?

OptoScript Equivalent (Arguments)


pn1 = null;
pt[0] = null;
GetPointerFromName(Name, Pointer)
pn = pt[0];
pn = &n;
pt[0] = &n;
pn == null
pt[0] == null

Type

F
P
P
F
F
F
F
F

Simulation
PAC Control Command
Communication to All I/O Points Enabled?
Communication To All I/O Units Enabled?
Disable Communication to All I/O Points
Disable Communication to All I/O Units
Disable Communication to Event/Reaction*
Disable Communication to I/O Unit
Disable Communication to Mistic PID Loop*
Disable Communication to PID Loop
Disable Communication to Point
Disable Event/Reaction Group*
Enable Communication to All I/O Points
Enable Communication to All I/O Units
Enable Communication to Event/Reaction*
Enable Communication to I/O Unit
Enable Communication to Mistic PID Loop*
Enable Communication to PID Loop
Enable Communication to Point
Enable Event/Reaction Group*

Copyright 2012 Opto 22

OptoScript Equivalent (Arguments)


IsCommToAllIoPointsEnabled()
IsCommToAllIoUnitsEnabled()
DisableCommuncationToAllIoPoints()
DisableCommunicationToAllIoUnits()
DisableCommunicationToEventReaction (Event/Reaction)
DisableCommunicationToIoUnit(I/O Unit)
DisableCommunicationtoMisticPidLoop(PID Loop)
DisableCommunicationtoPidLoop(PID Loop)
DisableCommunicationToPoint(Point)
DisableEventReactionGroup(E/R Group)
EnableCommunicationToAllIoPoints()
EnableCommunicationToAllIoUnits()
EnableCommunicationToEventReaction(Event/Reaction)
EnableCommunicationToIoUnit(I/O Unit)
EnableCommunicationToMisticPidLoop(PID Loop)
EnableCommunicationtoPidLoop(PID Loop)
EnableCommunicationToPoint(Point)
EnableEventReactionGroup(E/R Group)

Type

F
F
P
P
P
P
P
P
P
P
P
P
P
P
P
P
P
P

Simulation (Continued)
PAC Control Command
Event/Reaction Communication Enabled?
Event/Reaction Group Communication Enabled?*
I/O Point Communication Enabled?
I/O Unit Communication Enabled?
IVAL Set Analog Point
IVAL Set Counter
IVAL Set Frequency
IVAL Set I/O Unit from MOMO Masks
IVAL Set Mistic PID Control Word*
IVAL Set Mistic PID Process Term*
IVAL Set Off-Latch
IVAL Set Off-Pulse
IVAL Set Off-Totalizer
IVAL Set On-Latch
IVAL Set On-Pulse
IVAL Set On-Totalizer
IVAL Set Period
IVAL Set TPO Percent
IVAL Set TPO Period
IVAL Turn Off
IVAL Turn On
Mistic PID Loop Communication Enabled?*
PID Loop Communication Enabled?

OptoScript Equivalent (Arguments)


IsEventReactionCommEnabled (Event/Reaction)
IsEventReactionGroupEnabled(E/R Group)
IsIoPointCommEnabled(I/O Point)
IsIoUnitCommEnabled(I/O Unit)
IvalSetAnalogPoint(To, On Point)
IvalSetCounter(To, On Point)
IvalSetFrequency(To, On Point)
IvalSetiOUnitfromMOMO(On Mask, Off Mask, On I/O Unit)
IvalSetPidControlWord(On Mask, Off Mask, For PID Loop)
IvalSetMisticPidProcessTerm(To, On PID Loop)
IvalSetOffLatch(To, On Point)
IvalSetOffPulse(To, On Point)
IvalSetOffTotalizer(To, On Point)
IvalSetOnLatch(To, On Point)
IvalSetOnPulse(To, On Point)
IvalSetOnTotalizer(To, On Point)
IvalSetPeriod(To, On Point)
IvalSetTpoPercent(To, On Point)
IvalSetTpoPeriod(Value, On Point)
IvalTurnOff(Point)
IvalTurnOn(Point)
IsMisticPidLoopCommEnabled(PID Loop)
IsPidLoopCommEnabled(PID Loop)

Type

F
F
F
F
P
P
P
P
P
P
P
P
P
P
P
P
P
P
P
P
P
P
F

String
PAC Control Command
Append Character to String
Append String to String
Compare Strings
Convert Float to String
Convert Hex String to Number
Convert IEEE Hex String to Number
Convert Integer 32 to IP Address String
Convert IP Address String to Integer 32
Convert Mistic I/O Hex String to Float*
Convert Number to Formatted Hex String
Convert Number to Hex String
Convert Number to Mistic I/O Hex String*
Convert Number to String
Convert Number to String Field
Convert String to Float
Convert String to Integer 32
Convert String to Integer 64
Convert String to Lower Case
Convert String to Upper Case
Find Character in String
Find Substring in String
Generate Checksum on String
Generate Forward CCITT on String
Generate Forward CRC-16 on String
Generate Reverse CCITT on String
Generate Reverse CRC-16 on String
Get Nth Character
Get String Length
Get Substring
Move from String Table Element
Move String
Move to String Table Element
Move to String Table Elements

OptoScript Equivalent (Arguments)


Type
s1 += 'a';
P
s1 += s2;
P
CompareStrings(String 1, String 2)
F
FloatToString(Convert, Length, Decimals, Put Result in)
P
HexStringToNumber(Convert)
F
IEEEHexStringToNumber(Convert)
F
Int32ToIpAddressString(Convert, Put Result In)
F
IpAddressStringToInt32(Convert)
F
MisticIoHexToFloat(Convert)
F
NumberToFormattedHexString(Convert, Length, Put Result in)
P
NumberToHexString(Convert, Put Result in)
P
NumberToMisticIoHex(Convert, Put Result in)
P
NumberToString(Convert, Put Result in)
P
NumberToStringField(Convert, Length, Put Result in)
P
StringToFloat(Convert)
F
StringToInt32(Convert)
F
StringToInt64(Convert)
F
StringToLowerCase(Convert)
P
StringToUpperCase(Convert)
P
FindCharacterInString(Find, Start at Index, Of String)
F
FindSubstringInString(Find, Start at Index, Of String)
F
GenerateChecksumOnString(Start Value, On String)
F
GenerateForwardCcittOnString(Start Value, On String)
F
GenerateForwardCrc16OnString(Start Value, On String)
F
GenerateReverseCcittOnString(Start Value, On String)
F
GenerateReverseCrc16OnString(Start Value, On String)
F
GetNthCharacter(From String, Index)
F
GetStringLength(Of String)
F
GetSubstring
P
(From String, Start at Index, Num. Characters, Put Result in)
s = st[0];
P
s1 = s2;
P
st[0] = s;
P
MoveToStrTableElements(From, Start Index, End Index, Of Table)
P

1703-120305PAC Control Commands Quick Reference

99

String (Continued)
PAC Control Command
Set Nth Character
String Equal?
String Equal to String Table Element?
Trim String
Test Equal Strings
Verify Checksum on String
Verify Forward CCITT on String
Verify Forward CRC-16 on String
Verify Reverse CCITT on String
Verify Reverse CRC-16 on String

OptoScript Equivalent (Arguments)


SetNthCharacter(To, In String, At Index)
s1 == s2
s == st[0]
TrimString(String, Option)
See String Equal?
VerifyChecksumOnString(Start Value, On String)
VerifyForwardCcittOnString(Start Value, On String)
VerifyForwardCrc16OnString(Start Value, On String)
VerifyReverseCcittOnString(Start Value, On String)
VerifyReverseCrc16OnString(Start Value, On String)

Type

F
F
F
F
F
F
F
F
F
F

Time/Date
PAC Control Command
Copy Date to String (DD/MM/YYYY)
Copy Date to String (MM/DD/YYYY)
Copy Time to String
Convert Date & Time to NTP Timestamp
Convert NTP Timestamp to Date & Time
Get Date & Time
Get Day
Get Day of Week
Get Hours
Get Julian Day
Get Minutes
Get Month
Get Seconds
Get Seconds Since Midnight
Get System Time
Get Time Zone Description
Get Time Zone Offset
Get Year
Set Date
Set Day
Set Hours
Set Minutes
Set Month
Set Seconds
Set Time
Set Time Zone Configuration
Set Year
Synchronize Clock SNTP

OptoScript Equivalent (Arguments)


Type
DateToStringDDMMYYYY(String)
P
DateToStringMMDDYYYY(String)
P
TimeToString(String)
P
DateTimeToNtpTimestamp(Date&Time, NTP Timestamp, Put Result in)
F
NtpTimestampToDateTime(Date&Time, NTP Timestamp, Put Result in)
F
GetDateTime(Table)
F
GetDay()
F
GetDayOfWeek()
F
GetHours()
F
GetJulianDay()
F
GetMinutes()
F
GetMonth()
F
GetSeconds()
F
GetSecondsSinceMidnight()
F
GetSystemTime()
F
GetTimeZoneDescription(Configuration, Description)
F
GetTimeZoneOffset(Configuration)
F
GetYear()
F
SetDate(To)
P
SetDay(To)
P
SetHours(To)
P
SetMinutes(To)
P
SetMonth(To)
P
SetSeconds(To)
P
SetTime(To)
P
SetTimeZoneConfiguration(Configuration)
F
SetYear(To)
P
SynchronizeClockSNTP(Timeout, Server URL, Put Result in)
F

Timing
PAC Control Command
Continue Timer
Delay (mSec)
Delay (Sec)
Down Timer Expired?
Get & Restart Timer
Pause Timer
Set Down Timer Preset Value
Set Up Timer Target Value
Start Timer
Stop Timer
Timer Expired?
Up Timer Target Time Reached?

10

OptoScript Equivalent (Arguments)


ContinueTimer(Timer)
DelayMsec(Milliseconds)
DelaySec(Seconds)
HasDownTimerExpired(Down Timer)
GetRestartTimer(Timer)
PauseTimer(Timer)
SetDownTimerPreset(Target Value, Down Timer)
SetUpTimerTarget(Target Value, Up Timer)
StartTimer(Timer)
StopTimer(Timer)
HasTimerExpired(Timer)
HasUpTimerReachedTargetTime(Up Timer)

Copyright 2012 Opto 22

Type

P
P
P
F
F
P
P
P
P
P
F
F

You might also like