Reading voltages for lipol 3Cell battery

Hello everyone,

 

I have an ardupilot mega that I'm powering with a 3cell 2500mah battery, through an ESC. the ESC is outputting exactly 5v. I've followed the instructions in the manual to setup the voltage sensor. I soldered 3 of the 3.9k resisters in their place, leaving the 4th one open. I've also got the balancer cable soldered and plugged in.

 

The problem seems to be an accurate reading, I do indeed get a reading but it's nowhere near accurate. 

 

This is what I've added to my APM_Config.h, straight from the manual.

 

//Battery:

#define BATTERY_EVENT 1                 // (boolean) 0 = don't read battery, 1 = read battery voltage (only if you have it wired up!)

#define BATTERY_TYPE 0                  // (boolean) 0 = 3c (11.1v), 1 = 4c (14.8v)

#define INPUT_VOLTAGE 5.2               // (Volts) voltage your power regulator is feeding your ArduPilot to have an accurate pressure and battery level readings. (you need a multimeter to measure and set this of course)

#define VOLT_DIV_RATIO 3.0              //  Voltage divider ratio set with thru-hole resistor (see manual)

#define LOW_VOLTAGE     11.5            // Pack voltage at which to trigger alarm

 

I believe the problem lies in the VOLT_DIV_RATIO. In the "Correct Example" for a 3S battery, it lists the volt_div_ratio as 3.0, however 

 

When set to 3.0, the APM outputs about 10.2volts on a fully charged battery, however if I run a miltimeter over the last pin of the cell balancer plug it reads about 12v.

 

There in another part of the manual that lists the correct div ratio as 2.56, if I set this in the config then the APM outputs about 8.2v as being my voltage, even worse.

 

Can someone shed some light on what I am/have done wrong? Cheers

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • Hello Jon, 

    The other guys were right. You need to tweek the settings to calibrate for imperfect resistors. One obviose thing I see is your< #define INPUT_VOLTAGE 5.2>. You say your esc puts out exactly 5.0 V, then this is the value you must set. Your readings  are 10 % low with this value. Set it value to 5.0 and the VOLT_DIV_RATIO back to 3.0 and start from there.You need to take the time to read the comments (every thing after the //) in the APM_Config.h file. They explain the function of each line. Every detail is not in the manual.

  • Developer
    Nothing is wrong, just increase the ratio value until the measured voltage matches the actual voltage. In your case around. 3.2ish? All resistors have "tolerance" which can be upto 5%, so values need tweaking.
This reply was deleted.

Activity