
354
Command Details
Section 6-3
Repeat FOR
(FOR...NEXT)
Processing is repeated for the specified number of times.
Command type
FOR:
Multiple execution command
NEXT: Multiple execution command
Format
<Default value setting> (
←
can be omitted)
FOR_W<work registers for repeat count> L<repeat end value> S<number of
increment steps>;
<processing>
NEXT;
Ex: FOR_W#DL0002 L1000 S1;
INC MOVE [J01]100.00 [J02]200.00;
NEXT;
Operand
Note
(1) Word data is extended to long word data with a sign in the MC Unit.
(2) Figures below the decimal point are to be omitted.
Description
• Processing between FOR and NEXT will be repeatedly executed until
Work resisters for repeat count becomes equal to or greater than Repeat
end value.
• When decrementing (when No. of increment steps is signed “minus”), the
condition will be until Repeat end value becomes equal to or greater than
Work register for repeat count.
• Number of increment steps specifies the incrementing amount of Work
resisters for repeat count. If negative value is set, it will be the decrement-
ing amount.
WHILE
WEND
Conditional
expression
True
False
Processing
Operand
Setting range
Decimal
Variable specification
INC/ ABL
influ-
ence
Bit
Word
Long
word
Real
number
Indirect
specifi-
cation
Work registers for
repeat count
Variable
No
No
No
Yes
No
No
No
Repeat end value
1 to
2147483647
No
No
Yes (See
note 1.)
Yes
Yes (See
note 2.)
Yes
No
Number of increment
steps
−
2147483648 to
2147483647
No
No
Yes (See
note 1.)
Yes
Yes (See
note 2.)
Yes
No
Содержание CS1W-MCH71 -
Страница 2: ...CS1W MCH71 CJ1W MCH71 Motion Control Unit Operation Manual Revised June 2008 ...
Страница 3: ...iv ...
Страница 29: ...xxx ...
Страница 33: ...xxxiv ...
Страница 35: ...xxxvi ...
Страница 39: ...xl ...
Страница 69: ...24 Performance Section 1 7 ...
Страница 99: ...54 Connecting MECHATROLINK Devices Section 3 5 ...
Страница 283: ...238 Saving Data Section 5 4 ...
Страница 417: ...372 Command Details Section 6 3 ...