Allen-Bradley MicroLogix 1400 Instruction Manual page 206

Programmable controllers
Hide thumbs Also See for MicroLogix 1400:
Table of Contents

Advertisement

efesotomasyon.com - Allen Bradley,Rockwell,plc,servo,drive
204
Math Instructions
Publication 1766-RM001A-EN-P - October 2008
Considerations When Using Floating Point Data
When at least one of the operands is a Floating Data Point value:
• If either Source is NAN, then the result is NAN.
• All overflows result in infinity with the correct sign.
• All underflows result in plus zero.
• All denormalized Source values are treated as plus zero.
• Results are always rounded using the Round to Even rule.
• If Destination is an integer and the result is NAN or infinity, a saturated result (-32768 or
+32767 for word or -2,147,836,648 or +2,147,836,647 for long word) is stored in
Destination and the Math Overflow Selection Bit is ignored.
• If Destination is an integer, the rounded result is stored. If an overflow occurs after rounding, a
saturated result is stored in Destination and the Math Overflow Selection Bit is ignored.
The saturated results are:
– If Destination is an integer and the result is positive, overflow Destination is +32767
(word) or +2,147,483, 648 (long word).
– If Destination is an integer and the result is negative, overflow Destination is -32767
(word) or -2,147,483, 648 (long word).
Updates to Math Status Bits:
• Carry - is reset
• Overflow - Is set if the result is infinity, NAN, or if a conversion to integer overflows;
otherwise it is reset.
• Zero - Is set if the lower 31 bits of the Floating Point Data result is all zero's, otherwise it is
reset.
• Sign - Is set if the most significant bit of the Destination is set (bit 15 for word, bit 31 for long
word or floating point data); otherwise it is reset.
• Overflow Trap - The Math Overflow Trap Bit is only set if the Overflow bit is set. Otherwise, it
remains in its last state.

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents