Rockwell Automation T7833 ICS Regent+Plus Math Package for Winternet User Manual
Page 12

Math Package for W
INTERPRET
(T7833)
1 2
Industrial Control Services
Table 7. Error Codes.
Error Code
Description
Example
1
Underflow
C = A / B; |A/B| < 1.175494E-38
2
Overflow
C = A * B; A * B > 3.402823E38
C = A/B; B = 0
3
Not a number
C = SQRT A; A < 0
4
Conversion
AO = 3000 + 2000
(where AO is an analog output)
In most floating point equations, the results do not approach
the error limits of floating point math. When equations are
used that can produce floating point errors, the variable on
the left side of the equal sign will not be changed and it will
contain the last valid result. If under error conditions this
last value is not the best answer and a better answer can be
determined by the error code, then the error term should be
examined.
Example:
AO = 300 + AI
where,
AO is analog output (maximum 4095)
AI is analog input (0 - 4095)
if AI > 3795 then an error will occur.
Table 8. Example of Conversion Error, Error Code 4.
Scan
AI
AI+300
AO
Comments
1
3000
3300
3300
No error
2
3200
3500
3500
No error
3
3700
4000
4000
No error
4
3900
4200
4000
Error Code 4, last value used
5
4000
4300
4000
Error Code 4, last value used
6
3780
4080
4080
No error
The most desirable answer for scans 4 and 5 would probably
be AO max = 4095, not the last value of 4000. To alter this
value, you may use the error code to examine the error term
to determine a better value.