Installation manual
CNC 8055
CNC 8055i
PLC PROGRAMMING
10.
SOFT: V02.2X
·455·
Directing instructions
10.2 Directing instructions
They provide the PLC with information about the type of module and how it must be executed.
The directing instructions available at the PLC are:
PRG, PEt, CY1
Define the module type.
PRG Main module.
CY1 First cycle module.
PE Periodic module. It is executed every t milliseconds.
For example: PE 100 is executed every 100 ms.
END
It indicates the end of the module. If this is not defined, the PLC understands that this module ends
in the last block of the program.
Example of programming using the directing instruction END:
Example of programming without using the directing instruction END:
L
Label. Used to identify a program line, and is only used when references or program jumps are made.
It is represented with the letter L followed by up to 4 digits (1-2000), no order needs to be followed
and numbers may even be skipped.
If there are 2 or more labels with the same number in a single program, the PLC will show the
corresponding error when compiling it.
DEF
Symbol definition. Allows a symbol to be associated with any PLC variable, it being possible to
reference this variable throughout the program by means of the variable name or by means of the
associated symbol.
Example:
It is also possible to associate a symbol to any number which can be given in decimal, with or without
a sign, or hexadecimal format preceded with the "$" sign.
CY1
——-
END
PRG
——-
END
PE 100
——-
END
Beginning of module CY1.
End of module CY1.
Beginning of module PRG.
End of module PRG.
Beginning of module PE.
End of module PE.
CY1
——-
PRG
——-
PE 100
——-
——
Beginning of module CY1.
Beginning of module PRG.
Beginning of module PE.
End of modules CY1, PRG and PE.
DEF EMERG I1
Assigns the EMERG symbol to input I1, so any reference throughout the program to EMERG will be
interpreted by the PLC as a reference to I1.