Page 1 of 1

Doing calculations involving 'big' numbers on an 8-bit Pic

Posted: Fri Apr 27, 2007 2:46 pm
by muxer107
Hi all

Im currently doing a project involving converting a thermocouple voltage into temperature.

Im doing it in source boost, using a pic16f84a and have hit a problem.

The calculations involved are limiting greatly what I can do with it.

for instance: t = (1237035 + (28015*x))/1000000;

Now this obviously wont work as the output will be too large. Is their any way of doing maths like this in PIC?? The actual full code for linearising the thermocouple is only about 15 lines long, but it all includes large numbers for accuracy.
BTW 'x' can be as large as 9288

Any help appreciated, I really need to get somewhere with this!
Muxer

Posted: Fri Apr 27, 2007 2:48 pm
by Benj
Hello

Here is an example of how to use 32 bit math operations on a PIC micro using Flowcode.

http://www.matrixmultimedia.com/support ... .php?t=505

Posted: Tue May 08, 2007 10:25 am
by muxer107
Thanks! that worked perfectly :)

stephen