Download manual

Transcript
CHAPTER 8: ADVANCED
FLOATING POINT STORAGE FORMAT
The STORE@ and LOAD@ statements can be used in a BASIC program to save and retrieve floating
point numbers in absolute memory locations. Each floating point number requires six bytes of memory
for storage. All non-dimensioned variables are stored as floating point numbers in a normalized packed
BCD format as shown in the following example.
Example
>PUSH 1.2345678
>STORE@ 30000
Location
30000
Value
81H
Description
Exponent
-7FH = 10**-1
80H = 10**0
81H = 10**1
82H = 10**2
Number zero = zero exponent
29999
00H
Sign bit - 00H = Positive, 01H = Negative
29998
78H
Least Significant Two BCD digits
29997
56H
Next Least Significant Two BCD digits
29996
34H
Next Most Significant Two BCD digits
29995
12H
Most Significant Two BCD digits
8.1