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.

ADS1230 interfacing 8052

Dear Bob,

  I need to clarify one doubt regarding the precision in the ADC calculation.my formula looks like:-

weight =  ( updated_counts - no_load_counts) * my_data;     //TARE function not included..

were; "my_data" is the calibrated value ,i.e      my_data = cal_weight /  (adc_counts - no_load_counts);

My problem is, when i put a weight on the pan.suppose 1kg ,the display varies in between 0.999 gms and 1.000 gms. I observed that the noise in the layout is minimum, by observing the internal counts(changes in between 4 - 5 counts only).

From my calculation the result is obtaining like this:

suppose

no_load_counts = 10500;  // For 1 kilogram weight

updated_counts = 28650;

my_data = (1000 / (28650 - 10500)); = 0.0559641873278236914600550964187  //calibrated value with 1 kilogram weight.

 So as per the above formula the weight is calculated for 1 kilogram is given by:

weight =  ( updated_counts - no_load_counts) * my_data;     // TARE function not included..

weight = (28650 - 10500) * 0.0559641873278236914600550964187 = 1000 gms.

So here when the updated_counts are changed 1 or 2 counts due to noise the result will be

weight = (28649 - 10500) * 0.0559641873278236914600550964187 = 999.9449036;

Therefore displayed weight = 0.999 gms

Here i lost around 1 gram for 1 count variation,This small changes in the counts are reflecting on the external counts,Please help me to solve this problem.I used all the variables excluding my_data are of int datatype .my_data is a float datatype.

I m expecting your valuable reply.

Thank you

by

Ajit..

  • Hi Ajit,

    Think about this another way. Your weight calculation is the code span times the grams per code.  Grams per code is the long decimal number and is roughly 55.9mg per code (count) which is your error.  In other words you cannot resolve to the desired level as there can be a +/- 0.0559 gram variation.  The only way to improve this is to reduce the noise.  Averaging your results may help if you have eliminated external noise sources. Averaging will extend the measurement time and the number of averages needed will have to be discovered by experimentation.  I'm guessing at least 4 points will be needed for the averaged result.

    Best regards,

    Bob B