38
5 MODULE DEDICATED INSTRUCTION
5.1 Analog Instruction
Program example
• The following program restores the offset/gain setting value to the A/D converter module mounted on the I/O numbers from
X/Y10 to X/Y1F when the flag turns ON.
[Structured ladder/FBD]
[ST]
IF(Var_Flag_Inst=TRUE)THEN (* Instruction flag ON *)
SET(TRUE, Var_Flag_Exe); (* Turns execution flag ON *)
END_IF;
IF(Var_Flag_Exe=TRUE)THEN (* Execution flag ON *)
G_OGSTOR(TRUE, H01, Var_ControlData, Var_Result); (* Restores setting value *)
IF(Var_Result[0]=TRUE)THEN (* Execution finished *)
IF(Var_Result[1]=FALSE)THEN (* Normal completion *)
RST(TRUE, Var_Flag_Exe); (* Turns execution flag OFF *)
ELSE (* Error completion *)
END_IF;
END_IF;
END_IF;
Turns execution
flag ON
Restores setting value
Error completion
Normal completion
Turns execution
flag OFF
Process on error completion
(* Process on error completion *)
Содержание MELSEC System Q
Страница 1: ...MELSEC Q L Structured Programming Manual Special Instructions ...
Страница 2: ......
Страница 307: ...10 SFC CONTROL INSTRUCTION 10 2 SFC Transition Condition Comment Read 305 10 MEMO ...
Страница 309: ...I 307 MEMO ...
Страница 315: ......