252 VT1422A Command Reference Chapter 7
ALGorithm

ALGorithm:UPDate[:IMMediate]

ALGorithm:UPDate[:IMMediate] requests an immediate update of any scalar, array,
algorithm code, ALG:STATE, or ALG:SCAN:RATIO changes that are pending.

Comments Variables and algorithms can be accepted during Phase1-INPUT or

Phase 2-UPDATE in Figure 7-1 when INIT is active. All writes to variables and
algorithms occur to their buffered elements upon receipt. However, these
changes do not take effect until the ALG:UPD:IMM command is processed at
the beginning of the UPDATE phase. The update command can be received at
any time prior to the UPDATE phase and will be the last command accepted.
Note that the ALG:UPD:WINDow command specifies the maximum number
of updates to do. If no update command is pending when entering the UPDATE
phase, then this time is dedicated to receiving more changes from the system.
As soon as the ALG:UPD:IMM command is received, no further changes are
accepted until all updates are complete. A query of an algorithm value following
an UPDate command will not be executed until the UPDate completes; this may
be a useful synchronizing method.
When Accepted: Before or after INIT.
Related Commands: ALG:UPDATE:WINDOW, ALG:SCALAR,
ALG:ARRAY, ALG:STATE and ALG:SCAN:RATIO, ALG:DEF
(with swapping enabled)
Send with VXIplug&play Function: hpe1422_cmd(...)
Command
Sequence
The following example shows three scalars being written with the associated update
command following. See ALG:UPD:WINDOW.
ALG:SCAL ALG1','Setpoint',25 provide 3 new alg scalar values
ALG:SCAL 'ALG1','P_factor',1.3
ALG:SCAL 'ALG2','P_factor',1.7
ALG:UPD update values in alg
ALG:SCAL? 'ALG2','Setpoint' query for new updated scalar
4
OUTPUT
outputtable
sentto SCP
channels
4
OUTPUT
outputtable
sentto SCP
channels
1
INPUT
fromSCP
channels,
analog&
digital
1
INPUT
fromSCP
channels,
analog&
digital
2
UPDATE
variables&
algorothms
SetbyALG:OUTPUT:DELay(ifany)
Trigger Eve nt TriggerEvent
3
EXECUTE ALGS
executeall enabled algorithms
Figure 7-1. Updating Variables and Algorithms