I have some problems with float numbers ...
problem 1:
how to declare float constant?
now I solve the problem by this way:
var float10[2]; // float variable
flt_ITOF(float10, 10 ); //Convert integer 10 to float
I would like to define a float constant with value 10.0
how to do that ?
Beside the value 10.0 I need to define a constant with a number like -5.7750E-07 and -4.1830E-12
Is it possible to have:
#CONST
floatA[2]
floatB[2] ...
#END
problem 2:
how to move float value from one float variable to other float variable?
simple example:
var floatA[2]; // float variable A
var floatB[2]; // float variable B
flt_ITOF(floatA, 5 ) ; //Convert integer 5 to floatA
how to move or copy now value from floatA to floatB ?
now I solve this problem with subtraction of zero from floatA and store result in floatB...
problem 1:
how to declare float constant?
now I solve the problem by this way:
var float10[2]; // float variable
flt_ITOF(float10, 10 ); //Convert integer 10 to float
I would like to define a float constant with value 10.0
how to do that ?
Beside the value 10.0 I need to define a constant with a number like -5.7750E-07 and -4.1830E-12
Is it possible to have:
#CONST
floatA[2]
floatB[2] ...
#END
problem 2:
how to move float value from one float variable to other float variable?
simple example:
var floatA[2]; // float variable A
var floatB[2]; // float variable B
flt_ITOF(floatA, 5 ) ; //Convert integer 5 to floatA
how to move or copy now value from floatA to floatB ?
now I solve this problem with subtraction of zero from floatA and store result in floatB...
Comment