I'm having problems getting the sqrt (or sqrtf) function to work properly.
My targer processor is MCF52211. CodeWarrior version 5.7.0.
I've included the following libraries in the project: C_4i_CF_MSL.a and fp_coldfire.a
Also, <math.h> is included in the source.
When I build with the Require Function Prototypes box un-checked under Language Settings -> C/C++ Language the project builds and runs with the following results:
When I build with the Require Function Prototypes box un-checked under Language Settings -> C/C++ Language the project fails to build with the error (referencing the sqrt function):When I run using sqrt, the result is always 20.0 and and the exception handler is entered, resulting in the error: "Access Error: Error on operand write".
When I run using sqrtf, the result is a very large, incorrect number.
Error : function has no prototypeIs there a specific library I should be using or a setting somewhere that I am missing?