cancel
Showing results for 
Search instead for 
Did you mean: 

Forcing float on a matlab generated code

igal
Associate II
Posted on January 22, 2014 at 16:25

Hi all,

I use matlab to generate c code and have this code compile in IAR for STM32F4 as a library. So I have no ST libraries added just the c code and h files from matlab.

Matlab uses sqrt, sin functions etc. declared at math.h, these functions use double and I'm looking for a way to force the compiler to use float (so the FPU will be used), I can't go through the entire code and switc every function used for the float equivalent. is there a simple way to do so?

Thank you

#math.h
10 REPLIES 10
frankmeyer9
Associate II
Posted on January 23, 2014 at 15:54

 ... freaking forum software ...