I want to create sin cos LUT and include it in my code.
Pls let me know how to go about doing it, where to store etc.
Thanks a lot
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.
Is it ok to place my entire sine table in the code like:
float sin_tab[200]={0, ......}
Will it be better if I create the table in a notepad and include it along with my other source files.
Is it important to force it to some exact locations in RAM.
Can we do similar thing for inverse trig functions as well?
Thanks a lot
shyam nair said:Is it ok to place my entire sine table in the code like:
float sin_tab[200]={0, ......}
Many coders opt for the above declaration.
shyam nair said:Will it be better if I create the table in a notepad and include it along with my other source files.
This will be more structured
shyam nair said:Is it important to force it to some exact locations in RAM.
Not required but few coders like to know where exactly they get placed.
shyam nair said:Can we do similar thing for inverse trig functions as well?
I didn't get this question. You mean to say inverse trig table? Why not!
Regards,
Gautam
shyam nair said:I dont know much about RAM/ROM/Flash. Could u indicate which is the best location to place it and probably why.
This depends on your application requirement & memory management. Also, I hope you already know that IQmath library based sine table is already available in ROM.
Refer this if you were unaware:
Regards,
Gautam
Before putting a LUT, I would like to try fpu32 fast supplement lib....I have included the lib.
But when i declare float32 atan (float32) ....I am getting an error ....not compatible with double atan(double) .....in math.h