This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

A question about arithmetic library functions like sin, log, etc

Hello to the Keil Software Discussion Forum:

My name is Randy Norris and I am with NORgate Engineering & Associates.
We are considering using the 8051 for an online signal processing application and our question is this:

Does the Keil 8051 C compiler have the capability to use arithmetic functions such as sin, cos, log, sqrt, etc?

Our guess is that the answer is yes, and a statement at the beginning of the code like

#include <math.h>

would be required.

However,this is only an educated guess.

We have an evaluation version of Keil software from 2 years ago, and the User's Guide 11.97, but this documentation does not address our question.

Thanks for your help.
Randy Norris

Parents
  • "We are considering using the 8051 for an online signal processing application and our question is this"

    Hmmm...

    The 8051 is a microcontroller - not a signal processor!

    Perhaps you could elaborate on exactly what sort of "signal processing" you envisage, and what you mean by "online" - particularly what sort of performance you require.

    "Does the Keil 8051 C compiler have the capability to use arithmetic functions such as sin, cos, log, sqrt, etc?"

    It's an ANSI 'C' compiler - so yes, it does.

    However, again, the 8051 is just a little 8-bit controller - floating-point maths is not its forte

    "this documentation does not address our question."

    All the library functions are described in the chapter headed, surprisingly, "Library Reference"

Reply
  • "We are considering using the 8051 for an online signal processing application and our question is this"

    Hmmm...

    The 8051 is a microcontroller - not a signal processor!

    Perhaps you could elaborate on exactly what sort of "signal processing" you envisage, and what you mean by "online" - particularly what sort of performance you require.

    "Does the Keil 8051 C compiler have the capability to use arithmetic functions such as sin, cos, log, sqrt, etc?"

    It's an ANSI 'C' compiler - so yes, it does.

    However, again, the 8051 is just a little 8-bit controller - floating-point maths is not its forte

    "this documentation does not address our question."

    All the library functions are described in the chapter headed, surprisingly, "Library Reference"

Children
No data