Author Topic: floating point issue again..  (Read 8367 times)

Offline neil

  • Sr. Member
  • ****
  • Posts: 438
    • View Profile
floating point issue again..
« on: May 01, 2009, 07:33:47 PM »
Hi Mark,
  Since I applied the patch to CW so I can use 52259, I have lost the ability to use atof(..) etc..

Can this be because the 52259 is not a small memory device, like he 5223x?

I previously used done:

change file ansi_prefix.CF.size.h as follows:
Code:
#define _MSL_FLOATING_POINT     1
#undef _MSL_NO_MATH_LIB
#endif

#define _MSL_FLOATING_POINT_IO    1

and worked fine, now I notice that the file 'ansi_prefix.CF.size.h' doesnt get included during compiling.

I noticed within the ansi_prefix.CF.h file, that the above doesnt get included , here is the bit of code:
The #define _MSL_C_TINY_IO                0    part gets called. Has something changed?


#if (__COLDFIRE__ == __MCF51QE__ || __COLDFIRE__ == __MCF51AC__ || __COLDFIRE__ == __MCF51JM__)
#include "ansi_prefix.CF.v1.h"
#elif (defined(__CF_USE_SMALL_LIBS__) || __CF_SMALL_MEMORY_PART__) && !defined(__CF_USE_FULL_LIBS__)
#include "ansi_prefix.CF.size.h"
#else
  #define _MSL_C_TINY_IO                0   
  #define _MSL_C99_PRINTF_SCANF         1     
  #define _MSL_FLOATING_POINT_IO      1
#endif


Regards
Neil
« Last Edit: May 01, 2009, 08:51:00 PM by neil »

Offline mark

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3236
    • View Profile
    • uTasker
Re: floating point issue again..
« Reply #1 on: May 01, 2009, 10:18:00 PM »
Hi Neil

Unfortunately I haven't worked much with the libraries and so don't have much experience.

However, moving to the M5225X involves an upgrade to CW V7.1 and there are possibly differences there. I don't think that the memory model will need to be changed in any way since the chips are all much the same, but it may be that the headers in the V7.1 are slightly different by default. This may require the libraries to be recompiled. Is it perhaps possible to take the libraries from the original environment and place then in the newer one - they should be fully compatible and may get things working again?

Have you also asked at the CW developers forum? http://forums.freescale.com/freescale/board?board.id=CWCOMM

Regards

Mark