B.4: Floating Point Values - Electro Industries Shark 200 Installation & Operation Manual

Low-cost high performance multifunction electricity meter
Hide thumbs Also See for Shark 200:
Table of Contents

Advertisement

B.4: Floating Point Values

Floating Point Values are represented in the following format:
Register
Byte
0
Bit
7
6 5
4 3
Meaning
s
e e
e e
sign
The formula to interpret a Floating Point Value is: -1
sign
137-127
-1
x 2
x 1· 1000010001110110111001
10
-1 x 2
x 1.75871956
-1800.929
Register
Byte
0x0C4
Bit
7
6
5
4
1
1
0
0
Meaning
s
e e
e
sign
1
0x089 + 137
Formula Explanation:
C4E11DB9 (hex)
The sign of the mantissa (and therefore the number) is 1, which represents a negative value.
The Exponent is 10001001 (binary) or 137 decimal.
The Exponent is a value in excess 127. So, the Exponent value is 10.
The Mantissa is 11000010001110110111001 binary.
With the implied leading 1, the Mantissa is (1).611DB9 (hex).
The Floating Point Representation is therefore -1.75871956 times 2 to the 10.
Decimal equivalent: -1800.929
NOTES:
• Exponent = the whole number before the decimal point.
• Mantissa = the positive fraction after the decimal point.
E
Electro Industries/Gauge Tech
0
2 1
0 7
6 5
e e
e e
m m m m m m m m m m m m m m m m m m m m m m m
exponent
0x0C4E1
3
2
1 0
7 6
5 4
0
1
0 0
1 1
1 0
e
e
e e
e m m m m m m m
exponent
11000100 11100001 00011101 10111001 (binary)
1
4
3
2 1
0 7
6
sign
exponent-127
x 2
0x0E1
3 2
1 0
7
6 5 4
0 0
0 1
0
0 0 1
m m m m m m m m m m m m m m m m
0b011000010001110110111001
Doc# E149701
1
0
5
4 3
2
1 0 7 6
mantissa
x1.mantissa =
0x0C4E11DB9
0x01DB9
0x01D
3 2
1 0
7 6 5 4
1 1
0 1
1 0 1 1
mantissa
1
5 4 3 2 1 0
0x0B9
3 2
1
0
1 0
0
1
B-2

Advertisement

Table of Contents
loading

This manual is also suitable for:

Shark 200t

Table of Contents