122-32000 Parallax Inc, 122-32000 Datasheet - Page 196

MANUAL PROPELLER

122-32000

Manufacturer Part Number
122-32000
Description
MANUAL PROPELLER
Manufacturer
Parallax Inc
Datasheets

Specifications of 122-32000

Accessory Type
Manual
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
For Use With/related Products
Propeller Education (PE) Kit
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
The following are examples of valid constants:
Here is an example declaring an integer constant and two floating-point constants.
CON
The above code sets
the last expression required
treats it as a floating-point value.
The Propeller compiler handles floating-point constants as a single-precision real number as
described by the IEEE-754 standard. Single-precision real numbers are stored in 32 bits, with
a 1-bit sign, an 8-bit exponent, and a 23-bit mantissa (the fractional part). This provides
approximately 7.2 significant decimal digits.
For run-time floating-point operations, the FloatMath and FloatString objects provide math
functions compatible with single-precision numbers.
See
FloatString objects for more information.
Page 196 · Propeller Manual v1.0
Num1 = 20
Num2 = 127.38
Num3 = 32.05 * 18.1 - Num2 / float(Num1)
FLOAT
– Spin Language Reference
0.5
1.0
3.14
1e16
51.025e5
3 + 4
3.0 + 4.0
3.0 + 4
3.0 + FLOAT(4)
on page 216,
Num1
,
ROUND
Num2
Num1
floating-point value
floating-point value
floating-point value
floating-point value
floating-point value
integer expression
floating-point expression
invalid expression; causes compile error
floating-point expression
and
on page 303,
to be enclosed in the
Num3
to 20, 127.38 and 573.736, respectively. Notice that
TRUNC
on page 314, and the FloatMath and
FLOAT
declaration so that the compiler

Related parts for 122-32000