EasyManua.ls Logo

Fagor 8070 BL - Arithmetic and Logic Expressions

Fagor 8070 BL
444 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Programming manual.
CNC 8070
1.
CREATING A PROGRAM.
Arithmetic and logic expressions.
·52·
(REF: 1709)
1.12 Arithmetic and logic expressions.
An expression is any valid combination of operators, constants, parameters and variables.
Expressions may be used to program the numerical portion of any function, statement, etc.
The priorities of the operators and the way they can be associated determine how these
expressions are calculated:
Brackets should be used in order to clarify the order in which the expression is to be
evaluated. Using redundant or additional brackets will neither cause errors nor slow down
the execution.
P3 = P4/P5 - P6 * P7 - P8/P9
P3 = [P4/P5] - [P6 * P7] - [P8/P9]
Arithmetic expressions.
Their result is a numerical value. They consist of a combination of arithmetic and binary
operators with constants, parameters and variables.
This type of expressions may also be used to assign values to parameters and variables:
P100 = P9 P101 = P[P7] P102 = P[P8 + SIN[P8*20]]
P103 = V.G.TOOL
V.G.FIXT[1].X=20 V.G.FIXT[1].Y=40 V.G.FIXT[1].Z=35
Relational expressions.
Their result is a TRUE or a FALSE. They combine relational and logic operators with
arithmetic expressions, constants, parameters and variables.
... [P8==12.6] ...
It compares if the value of P8 is equal to 12.6.
... ABS[SIN[P4]] > 0.8 ...
It compares if the absolute value of the sine of P4 is greater than 0.8.
... [[P8<=12] + [ABS[SIN[P4]] >=0.8] * [V.G.TOOL==1]] ...
Priority from highest to lowest To be associated
Functions, - (change sign) from right to left.
** (exponent), MOD (remainder) from left to right.
* (multiplication, logic AND), / (division) from left to right.
+ (suma, OR lógico), - (resta) from left to right.
Relational operators from left to right.
& (AND),^ (XOR) from left to right.
| (OR) from left to right.

Table of Contents

Related product manuals