Possible Type Conversions - Siemens SINUMERIK 840D sl Programming Manual

Job planning
Hide thumbs Also See for SINUMERIK 840D sl:
Table of Contents

Advertisement

1.8

Possible type conversions

Function
Type conversion on assignment
The constant numeric value, the variable, or the expression assigned to a variable must be
compatible with the variable type. If this is this case, the type is automatically converted
when the value is assigned.
Possible type conversions
from
REAL
INT
BOOL
CHAR
STRING
AXIS
FRAME
Explanation
*
1)
2)
3)
4)
Note
If conversion produces a value greater than the target range, an error message is output.
If mixed types occur in an expression, type conversion is automatic. Type conversions are
also possible in synchronous actions, see Chapter "Motion-synchronous actions, implicit type
conversion".
Job Planning
Programming Manual, 03/2013, 6FC5398-2BP40-3BA1
to REAL
INT
yes
yes*
yes
yes
yes
yes
yes
yes
At type conversion from REAL to INT, fractional values that are >=0.5 are rounded up,
others are rounded down (cf. ROUND function).
Value <> 0 is equivalent to TRUE; value == 0 is equivalent to FALSE
If the value is in the permissible range
If only 1 character
String length 0 = >FALSE, otherwise TRUE
BOOL
CHAR
Yes
)
yes*
1
Yes
)
Yes
1
2)
yes
yes
Yes
yes
1)
Yes
Yes
4)
3)
Flexible NC programming
1.8 Possible type conversions
STRING
AXIS
yes
yes
yes
yes
FRAME
yes
77

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 828dSinumerik 840de sl

Table of Contents