« Return to Thread: - Need fast divide by 14 constant routine? ( Random access 8-bit data in PIC16F flash )

Re: - Need fast divide by 14 constant routine? ( Random access 8-bit data in PIC16F flash )

by David VanHorn-2 :: Rate this Message:

Reply to Author | View in Thread

Multiply by 9, then divide by 128?  (close..)

It's not really apparent what you're trying to optimize.
I had a problem once where I was trying to do bearing calculations,
and I did NOT want to do 16 bit math, and I was able to do it in 8
bit, forsaking degrees for "dilberts" where there are 256 dilberts of
angle in a circle
--
http://www.piclist.com PIC/SX FAQ & list archive
View/change your membership options at
http://mailman.mit.edu/mailman/listinfo/piclist

 « Return to Thread: - Need fast divide by 14 constant routine? ( Random access 8-bit data in PIC16F flash )