3.16 ALT (Alternate out)
■
Ladder diagram
■
Devices that can be specified (indicated by ●)
Operand
Bit device
Specification of bit of
word device
Index modifier
X Y R L T C P E SR IN OT DT.n LD.n
bit ● ● ● ● ● ● ● ●
■
Outline of operation
● When the operation result up to immediately before changes (rises) from OFF to ON, the
specified coil ON/OFF is inverted.
● The ON/OFF state of the specified coil is held until the ALT instruction specifying the coil is
executed next. (Flip-flop control)
■
Operation Example
X100
R0
Leading
edge
Leading
edge
Leading
edge
ON/OFF states of output R0 is inverted whenever X100 changes from the OFF to
ON states (rises).
■
Precautions for programming
● The ALT instruction detects rising from OFF to ON of the input and inverts the output.
● While the input continues to be ON, it is inverted only during rise. After that it is not inverted.
● The output will not be inverted for the first scan if the input is already ON when the operation
mode is switched to RUN or the power is turned on in the RUN mode.
● Be careful when using this instruction with an instruction that changes the order of instruction
execution such as MC - MCE or JP - LBL (1 to 6, shown below), because the operation of
the instruction may change depending on the timing of the instruction execution and input.
1) MC - MCE instructions
2) JP - LBL instructions
3) LOOP - LBL instructions
3.16 ALT (Alternate out)
3-34 WUME-FP7CPUPGR-12