Dear Mohit,
The default resistor bridge on the tiny2/twog is VoltageOfAdc(0.024 * adc) and by adding the VoltageOfAdc lines in your aircraft file you override the defaults with 0.0177 * adc. The difference in scale is precisely 1.4.
Solution: remove the VOLTAGE_ADC_A, VOLTAGE_ADC_B and VoltageOfAdc definitions from your aircraft file (they will now have the default values that are set in tiny_x_x.h
Christophe
---------- Forwarded message ----------
From: Mohit Mundhra <address@hidden>
To: address@hidden
Date: Tue, 9 Jun 2009 18:57:34 +0530
Subject: Re: [Paparazzi-devel] Incorrect Battery Reading - TWOG
When I connected a 3S battery measuring 12.5 V, TWOG was showing 8.9
V; while when a 7.9 V battery was connected it showed 5.7 V. I just
now realized that it could be a problem of some resistor since the
ratio coming out is same in both case (12.5/8.9 = 7.9/5.7 = 1.4
approx). Are there any other reasons that may be there for this
incorrect reading?
--
Mohit Mundhra