Other Parts Discussed in Thread: C2000WARE
Hello,
I am developing an application on the Cortex core (Connectivity Manager) and I have some problems when using single precision floating point variables and values.
Example 1
If I assign a double precision floating-point value to a float variable (single-precision), I have an Hard Fault.
float a;
a = 1.0;
Example 2
If I divide a int32 variable with a single precision floating-point variable, I have an Hard Fault.
uint32_t b;
uint32_t c;
b = 1600;
c = b / 1.0F;
Example 3
The same of example 2, but in this case I eliminate the F suffix from the floatig-point value (double-precision).
In this case I have no problems.
b = 1600;
c = b / 1.0;
Why I have these exceptions when working with single precision floating-point values?
Thank you,
Carlo
