28.08.2013 Views

CNC 8035 - Programming manual - Fagor Automation

CNC 8035 - Programming manual - Fagor Automation

CNC 8035 - Programming manual - Fagor Automation

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Programming</strong> <strong>manual</strong><br />

12.<br />

PROGRAM CONTROL INSTRUCTIONS<br />

Flow control instructions<br />

<strong>CNC</strong> <strong>8035</strong><br />

·T· MODEL<br />

(SOFT V16.3X)<br />

·258·<br />

(IF condition ELSE )<br />

This instruction analyzes the given condition that must be a relational expression. If the condition<br />

is true (result equal to 1), will be executed, otherwise (result equal to 0) will<br />

be executed.<br />

Example:<br />

(IF (P8 EQ 12.8) CALL 3 ELSE PCALL 5, A2, B5, D8)<br />

If P8 = 12.8 executes the mnemonic (CALL3)<br />

If P812.8 executes the mnemonic (PCALL 5, A2, B5, D8)<br />

The instruction can lack the ELSE part, i.e., it will be enough to program IF condition .<br />

Example:<br />

(IF (P8 EQ 12.8) CALL 3)<br />

Both and can be expressions or instructions, except for mnemonics IF and<br />

SUB.<br />

Due to the fact that in a high level block local parameters can be named by means of letters,<br />

expressions of this type can be obtained:<br />

(IF (E EQ 10) M10)<br />

If the condition of parameter P5 (E) having a value of 10 is met, the miscellaneous function M10<br />

will not be executed, since a high level block cannot have ISO code commands. In this case M10<br />

represents the assignment of value 10 to parameter P12, i.e., one can program either:<br />

(IF (E EQ 10) M10) or (IF (P5 EQ 10) P12=10)

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

Saved successfully!

Ooh no, something went wrong!