This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28388D: Floating point addition

Part Number: TMS320F28388D

Hi TI,

I am using TMS320F28388D controller in my application.

i have tried to perform addition operation on float32 variables.

The equation is var3 = var1 + var2; var1, var2, var3 all are float32 numbers.

var2 is the number in e-05, e-06, e-07. Var1 is normal number.

After certain number of var1 in the addition operation, the value after point is zero. 

Is it a constraint with float32 variables or FPU of processor? Let me know is there any alternate way of performing floating operations.

   

Thanks,

Saikumar.

  • Hello Saikumar,

    After certain number of var1 in the addition operation, the value after point is zero. 

    Can you please clarify what you mean by this? The images you included look like they all round Var1 to 0 after the decimal place, what do you mean by a certain number of Var1? Have you tried making Var2 for the addition operation be something larger like 0.1 or 1.0?

    If the issue is that your value is not updating, please double-check in the Expressions window whether Var1 can be altered in any sort of floating-point operation, if it's correct, and that there are no integers in the operation. Also make sure that optimizations are disabled when running the debug session.

    Best regards,

    Omer Amir