6 - 35
6 DriveProgramming Commands
DriveProgramming User’s Manual (I622-E1)
6-5 Arithmetic Operation and Logical Operation Commands
6
Example
Dec (Decrement by 1)
Command Description Argument
Decrements <value> by 1. Value: any variable
Format
Flowchart method Text language method
↓
dec <value>
Note If an overflow or underflow occurs, the DriveProgramming detects it as an error. Take neces-
sary measures in the application so that they do not occur.
Flowchart Text
Block number
Operation
1 Assigns 100 to U(02).
2 Subtracts 1 from U(02).
3 Waits for 1.00 second with the “wait” command.
4 Jumps to the block 2: loop_ unconditionally.