I am forced to agree.. I used the apnotes math package , it worked great. You will want to change all the EQUs to cblocks before you use it. Terry At 12:38 PM 2/1/2000 +0200, Roland Andrag wrote: >Get hold of the microchip Embedded control handbook - it contains a couple >of application notes (like AN526 - PIC16C5X / PIC16Cxxx Math utility >routines and AN544 - Math utility routines PIC17Cxx) with code for >multiply/divide, numerical integration/differentiation and square root. > >The application notes can also be found as .pdf files on the microchip >website. > >Cheers > Roland > >----- Original Message ----- >From: Phu T. Van >To: >Sent: Tuesday, February 01, 2000 8:03 AM >Subject: Math, part II > > >> Thanks for all your help. I think part (most/all?) of my dilema lies in >> the fact that I'm using the PIC, small-ish in both memory and raw >> processing power. But I'm also lacking a very fundamental thing : the >> knowledge of how to do elementary math with the PIC's very limited >> insruction set, specifically its bit-wise operations. >> How do you, for example : >> --Multiple/divide ? >> --Calculate exponents ? >> --Anything taught in Elementary Algebra ? >> >> Is it futile to hope that previous PIC gurus had written concise, >> dummy-oriented tutorials on how to do these operations ? Obviously >> someone has had to multiply and divide with a PIC once in their life. It >> frustrates me slightly that I can't do these basic things, even though >> it appears to me that PIC programs follow the formula : >> code,code,code,miracle,code. >> >> Thanks again. >> --Phu T. Van >> P.S. : I've dug up some information on the CORDIC algorithm. Is there >> any way to implement it (painlessly, if possible) on the 16F84 ? The >> page claimed it was successfully used on the Basic Stamp II, which is I >> think more powerful than the PIC. >> > > ----------------------------------------------------------------- Sent from the desk of: Terry Allen Steen, EE engineering@marinapower.com 332 McLaws Circle, Ste 111 757-258-8800 (Voice) Williamsburg, Va 23185 757-258-8805 (FAX) ----------------------------------------------------------------- !I AM A WHALE MAIL USER! If you have a large file to send, goto http://www.whalemail.com send them to: mplengineer Give me your account and I will use it also ----------------------------------------------------------------- Visit our web-site: www.marinapower.com -----------------------------------------------------------------