
L-force | PLC Designer
What is What in PLC Designer
DMS 3.2 EN 02/2011 TD29 41
Implementation part:
LD iPar1
MUL iPar2
ST iMulErg
LD iPar1
EQ iPar2
ST xVergl
The multiplication result is saved in the variable ERG, and the result of the comparison
is saved in QUAD. An instance of FUB with the name INSTANCE is declared.
Calling FUB in IL:
Declaration part:
PROGRAM AWLaufruf
VAR
xQuad : BOOL;
fubinstanz : FUB;
iErg: INT:=0;
END_VAR
Implementation part:
CAL fubinstanz(iPar1:=5;iPar2:=5);
LD fubinstanz.xVergl
ST xQuad
LD fubinstanz.iMulErg
ST iErg
Calling FUB in ST (Declaration part as shown above for IL):
PROGRAM STaufruf
fubinstanz(iPar1:=5;iPar2:=5); bzw. fubinstanz;
QUAD:=fubinstanz.xVergl;
ERG:=funbinstanz.iMulErg;
Commentaires sur ces manuels