09.12.2012 Views

Basic Characteristics RAPID

Basic Characteristics RAPID

Basic Characteristics RAPID

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Incr Increments by 1<br />

Example<br />

Arguments<br />

Example<br />

Syntax<br />

Incr is used to add 1 to a numeric variable or persistent.<br />

Incr reg1;<br />

1 is added to reg1, i.e. reg1:=reg1+1.<br />

Incr Name<br />

Name Data type: num<br />

The name of the variable or persistent to be changed.<br />

WHILE stop_production=0 DO<br />

produce_part;<br />

Incr no_of_parts;<br />

TPWrite "No of produced parts= "\Num:=no_of_parts;<br />

ENDWHILE<br />

The number of parts produced is updated on the teach pendant each cycle.<br />

Production continues to run as long as the signal stop_production is not set.<br />

Incr<br />

[ Name ’:=’ ] < var or pers (INOUT) of num > ’;’<br />

Related information<br />

Described in:<br />

Decrementing a variable by 1 Instructions - Decr<br />

Adding any value to a variable Instructions - Add<br />

Changing data using an arbitrary<br />

expression, e.g. multiplication<br />

Instructions - :=<br />

<strong>RAPID</strong> Reference Manual 8-Incr-1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!