cancel
Showing results for 
Search instead for 
Did you mean: 

How to look at floating-point number calculation result with EWARM

Ken Inoue
Associate III
Posted on November 09, 2017 at 10:11

Thank you for your patronage. I'm using STM32F3348-Discoverywhich has FPU and EWARM.

I made calculations like the picture below.

0690X00000608KAQAY.png

I'd like to check if floating point arithmetic is calculated correctly. So,I added z to EWARM live watch. Butz indicated an error.In case of integer operation, it is correctly displayed.How can I do it?

0690X0000060PC8QAM.png

Best Regards,

Ken Inoue

1 ACCEPTED SOLUTION

Accepted Solutions
Andrew Neil
Evangelist III
Posted on November 09, 2017 at 10:39

Having paid the considerable licence fee for EWARM, don't you think you should be asking them about difficulties with their product ... ?!

https://www.iar.com/support/technical-support/

  

But, anyhow, what is the text following 'Error(...' in your screenshot?

General points - not specific to IAR:

  • Is z in-scope at the point you are trying to observe it?

     
  • Is the value of z ever used for anything non-trivial?

    If not, the compiler may well have optimised it away...

View solution in original post

4 REPLIES 4
Andrew Neil
Evangelist III
Posted on November 09, 2017 at 10:39

Having paid the considerable licence fee for EWARM, don't you think you should be asking them about difficulties with their product ... ?!

https://www.iar.com/support/technical-support/

  

But, anyhow, what is the text following 'Error(...' in your screenshot?

General points - not specific to IAR:

  • Is z in-scope at the point you are trying to observe it?

     
  • Is the value of z ever used for anything non-trivial?

    If not, the compiler may well have optimised it away...
174712CGIL2
Posted on November 09, 2017 at 12:10

Do you understand the concept of scope in the 'C' programming language?

A variable is not visible outside its scope - not even to a debugger ...

Posted on November 09, 2017 at 12:37

I will study that. 

Thanks.

Best Regards,

Ken Inoue