beautypg.com

Yaskawa YASNAC PC NC PLC Programming Manual User Manual

Page 57

background image

6 - 21

YASNAC PCNC PLC Programming Manual Chapter 6: PLC Instructions

d) Example

(6) SBI (Subtract Immediate) RR after operation: RR-

(a) Function

The instruction subtracts the specified numeric value from the content of the register and
stores the result to the register when the ST contact is ON (RR = 1). If the ST contact is
OFF (RR = 0), the instruction is not executed.

The RR content remains unchanged before and after the execution of the SBI instruction.

(b) Format

(c) Explanation

An ST contact must be entered before the SBI instruction.

The SBI instruction is executed in intervals of “4 × n” msec while the ST contact is
ON.

There is no function to detect underflow. Make sure that “numeric value contents of
register”.

(d) Example

(7) ANI (AND Immediate) RR after operation: RR-

(a) Function

The instruction executes AND between the specified numeric value and the content of the
register and stores the result to the register when the ST contact is ON (RR = 1). If the ST
contact is OFF (RR = 0), the instruction is not executed.

The RR content remains unchanged before and after the execution of the ANI instruction.

B A Paradym31 Variable Name