1-8 Reference
Data Formats and Floating-Point Operations
Trio Motion Technology
Data Formats and Floating-Point Operations
The TMS320C3x processor used by the Motion Coordinator features several dif-
ferent data types. In the Motion Coordinator we use two main formats. The fol-
lowing descriptions are taken directly from the TI documentation.
Single-Precision Floating Point Format
In the single precision format, the floating-point number is represented by an 8-
bit exponent field (e) and a twos complement 24-bit mantissa field (man) with
and implied significant non-sign bit.
Operations are performed with an implied binary point between bits 23 and 22.
When the implied most significant non-sign bit is made explicit, it is located to
the immediate left of the binary point.
The floating point number 'x' is given by:
x= 01.f x 2
e
if s=0
10.f x 2
e
if s=1
0 if e=-128
The following examples illustrate the range and precision if the single-precision
floating-point format:
Single-Precision Integer Format
In the single precision integer format, the integer is represented in twos comple-
ment notation.
The range of an integer x, represented in the single-precision integer format, is:
-2
31
<= x <=2
31
-1
31 24
23 22 0
e
s f
Most Positive: x = (2 - 2
-23
) x 2
127
= 3.4028234 x 10
38
Least Positive: x = 1 x 2
-127
= 5.8774717 x 10
-39
Least Negative: x = (-1 - 2
-23
) x 2
-127
= -5.8774724 x 10
-39
Most Negative: x = -2 x 2
127
= -3.4028236 x 10
38
31
0
s