![Omron CS1-H Series Operation Manual Download Page 52](http://html1.mh-extra.com/html/omron/cs1-h-series/cs1-h-series_operation-manual_742526052.webp)
37
Restrictions on Function Blocks
Section 2-3
Operation when the
Instance Is Not Executed
When the input to the function block’s EN input variable is OFF, the function
block is not called, so the internal variables of the instance do not change (val-
ues are retained). In the same way the output variables do not change when
EN is OFF (values are retained).
!Caution
An instance will not be executed while its EN input variable is OFF, so Differ-
entiation and Timer instructions will not be initialized while EN is OFF. If Differ-
entiation or Timer instructions are being used, use the Always ON Flag
(P_On) for the EN input condition and include the instruction’s input condition
within the function block definition.
Nesting
A function block cannot be called from another function block, i.e., nesting is
not supported.
2-3
Restrictions on Function Blocks
Ladder Programming
Restrictions
There are some restrictions on instructions used in ladder programs.
Instructions Prohibited in
Function Block Definitions
The following instructions cannot be used in function block definitions. A com-
pile error will occur if any of these instructions is used.
• Block Programming Instructions (All instructions, including BPRG and
BEND)
• Subroutine Instructions (SBS, GSBS, RET, MCRO, SBN, GSBN, and
GRET)
• Jump Instructions (JMP, CJP, CJPN, and JME)
• Step Instructions (STEP and SNXT)
• Immediate Refresh Instructions (!)
• I/O REFRESH Instruction (IORF)
• TMHH and TMHHX Instructions
• CV Address Conversion Instructions (FRMCV and TOCV)
FB
EN ENO
1.0
P_Off
P_On
ENO
1.0
P_Off
P_On
Program
FB definition
Body
Execution results:
Output variable 1.0 is turned OFF, but
internal variable a retains its previous value.
If the programming were entered
directly into the program instead of in a
function block definition, both bit 1.0
and variable a would be turned OFF.
Program
Internal
variable a
Internal
variable a
FB1
FB2
Program
Instance A
Instance A: FB1
Instance X: FB2
Summary of Contents for CS1-H Series
Page 3: ...iv...
Page 5: ...vi...
Page 7: ...viii TABLE OF CONTENTS...
Page 15: ...xvi Application Precautions 4...
Page 151: ...136 Procedures Section 3 2...
Page 153: ...138 Data Types Appendix A...
Page 177: ...162 External Variables Appendix C...
Page 181: ...166 Revision History...