:x
Floating point operations without FPU is time consuming task in CPUs and FPU presence in this case is recommended.
In case of a uC this is a unusual request but can be done with a lot of processing on 8 bits I guess.
Do a simple search on google with "floating point" and will found some articles about floating point representation and working.
Microchip have floating point application notes, and there is code on the PICList - but generally it's best not to use floating point, it's very slow and inaccurate. By careful scaling of the numbers you can usually use integer maths instead, far faster and giving perfect accuracy.
If you are using a C compiler, doesn't it already provide floating point routines anyway?.
"pow" raises one number to another and returns the result. You're probably right, it might be better to use integers, but the nature of this unfortunately limits me to using floats .
Speed is not TOO Much of a concern, as long as my routine can do two samples a second that's fine
Anyway, accuracy is not a HUGE concern (ie. 1 decimal place is FINE)....
"pow" raises one number to another and returns the result. You're probably right, it might be better to use integers, but the nature of this unfortunately limits me to using floats .
Speed is not TOO Much of a concern, as long as my routine can do two samples a second that's fine
Anyway, accuracy is not a HUGE concern (ie. 1 decimal place is FINE)....