526
31 RUNNING A SAFETY PROGRAM
31.2 Safety Program
Safety program execution type
The standard program and safety program execution types are as follows.
Safety programs are executed as a fixed scan execution type program. However, safety programs perform safety control, and
therefore operation differs from standard fixed scan execution type programs in the following ways.
• They are unaffected by disabling interrupt instructions (EI instruction, DI instruction, and MASK instruction), and are
executed based on the safety cycle time.
• Of all interrupt programs that can be created by customers, the execution of safety programs is given highest priority.
• Safety cycle processing including safety programs prioritizes fixed periodicity. If the safety cycle time is exceeded, and
safety cycle processing is executed, processing is not performed in succession, but based on the interrupt timing of the
next cycle time.
When the program does not complete within the safety cycle time
Monitors whether execution of the safety program is completed within the safety cycle time, and if the program execution time
exceeds the next safety cycle time, an error occurs at the Safety CPU and safety function module. Note that if the next safety
cycle time is exceeded, the safety input
safety program is not executed following program completion, a safety cycle
processing error (error code: 1A01H) is detected at the Safety CPU, and the safety program is executed at the next safety
cycle time. Also, if execution of the program is completed after the safety cycle time has been exceeded, the safety cycle
processing time execution cycle error flag turns on, and the safety cycle processing time execution cycle error count is
incremented by one as follows.
Program
Execution type
Standard program
• Initial
• Scan
• Fixed scan
• Event
• Standby
Safety program
Fixed scan
Item
Safety cycle processing time
execution cycle error flag
Safety cycle processing time
execution cycle error count
Cause of safety cycle processing time
execution cycle error count being
incremented by one
Safety CPU
SM1888
SD1888
If error codes 1A00H, 1A01H occur
Safety function
module
Un\G54
If error code 1A00H occurs
Tsc: Safety cycle time
Tsio: Safety p Safety input/output processing time
(1): If safety input/output and safety program execution are not completed within the safety cycle time, interrupts during this period are ignored. Execute safety
input/output and safety programs from the next interrupt.
(2): If the time from safety input to safety output exceeds the safety cycle time, a continuation error will occur after safety processing is complete.
• Safety CPU: SM1888 turns ON, and the value in SD1888 is incremented by one.
• Safety function module: The value in Un\G54 is incremented by one.
C
B
A
C
B
A
Tsc
Tsc
Tsc
Tsio
Tsio
(1)
(2)
Safety output
(output refresh)
Safety program
(operation processing)
Safety input
(input refresh)
Summary of Contents for MELSEC iQ-R-R00CPU
Page 2: ......
Page 151: ...9 MONITOR FUNCTION 9 1 Real Time Monitor Function 149 9 MEMO ...
Page 323: ...18 SEQUENCE SCAN SYNCHRONIZATION SAMPLING FUNCTION 321 18 MEMO ...
Page 330: ...328 20 ROUTING SETTING 20 3 Precautions MEMO ...
Page 423: ...26 BASIC CONCEPT 26 8 State Transition of the Redundant System 421 26 MEMO ...
Page 1014: ...1012 APPX Appendix 15 Added and Enhanced Functions MEMO ...
Page 1027: ......