Topic: DMD0489

Help File Version: 2.9.4.37

TESTNUM - Classify Numeric Value Types


The Classify Numeric Value Types (TESTNUM) instruction categorizes the given numeric value into one of 5 different types. This can be useful specifically for classifying IEEE floating point numbers received from 3rd party devices, or for classifying general integer and floating point values. Note: Do-more CPUs will also turn on ST132 ($OutOfRange), ST133 ($Overflow), and ST141 ($DivideByZero) whenever a calculation results in an invalid value.

 


Parameters:

Note: Use the F9 key to open the Default Element Selection Tool (the Element Picker or the Element Browser) or use the Down-Arrow key (Auto-Complete) on any parameter field to see a complete list of the memory locations that are valid for that parameter of the instruction.

 

 

Input Value is the numeric memory location that contains the value to test.

 

Value Type is the numeric memory location where the value type code will be stored.

Input Value

Value Type Code

Value Type Description

Integer

0

 

1

 

2

 

3

 

4

 

n/a

 

Min / Max Integer (INT)

 

Zero

 

n/a

 

Normal

 

 

Real (Floating Point)

0

 

1

 

2

 

3

 

4

 

Not a Number (NaN)

 

Infinity (INF)

 

Zero

 

Subnormal

 

Normal

 


Status Display:

 


See Also:

RANGECHECK - Value In / Out of Range