Remainder (Mod) - HEIDENHAIN iTNC 530 HSCI Technical Manual

Hide thumbs Also See for iTNC 530 HSCI:
Table of Contents

Advertisement

9.8.28 REMAINDER (MOD)

July 2013
MOD (MODULO)
Syntax:
B, W, D, K
Operands:
Action:
The iTNC extends the operand to the width of the accumulator (32 bits) and
then calculates the REMAINDER resulting from the division of the content of
the word accumulator by the content of the operand. The REMAINDER is
stored in the word accumulator where you can process it. If the iTNC cannot
execute the MOD command correctly, it sets marker M4202, otherwise it
resets it.
Example:
Divide the number saved in word W6 by the constant, then calculate the
REMAINDER and assign the result to double word D8.
Initial state:
Word
W6
Constant
Double word D8
Function
Load W6 into the word
accumulator.
Divide the content of the
word accumulator by a
constant, then save the
integral REMAINDER in
the word accumulator.
Assign the REMAINDER
to double word D8.
M4202
Incorrectly executed modulo
9.8 Command Set
= 50 (dec)
= 15 (dec)
= ?
STL
Accumulator
content
L W6
50
MOD
11
K15
= D8
11
Operand content
50
15
11
Set
Reset
NC
PLC
1791

Advertisement

Table of Contents
loading

Table of Contents