From 8def1d257e1c9d60622dd20ade4ba86f4cf75bfc Mon Sep 17 00:00:00 2001 From: Leonard Hall Date: Tue, 23 May 2017 16:14:26 +0900 Subject: [PATCH] Copter: pass battery resistance estimate to motors --- ArduCopter/sensors.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ArduCopter/sensors.cpp b/ArduCopter/sensors.cpp index 1472cc907e..3e802165f7 100644 --- a/ArduCopter/sensors.cpp +++ b/ArduCopter/sensors.cpp @@ -170,6 +170,8 @@ void Copter::read_battery(void) } if (battery.has_current()) { motors->set_current(battery.current_amps()); + motors->set_resistance(battery.get_resistance()); + motors->set_voltage_resting_estimate(battery.voltage_resting_estimate()); } // check for low voltage or current if the low voltage check hasn't already been triggered