mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-23 07:53:34 +08:00
battery: pass source in by constructor
This commit is contained in:
@@ -38,7 +38,7 @@ using namespace time_literals;
|
||||
EscBattery::EscBattery() :
|
||||
ModuleParams(nullptr),
|
||||
WorkItem(MODULE_NAME, px4::wq_configurations::lp_default),
|
||||
_battery(1, this, ESC_BATTERY_INTERVAL_US)
|
||||
_battery(1, this, ESC_BATTERY_INTERVAL_US, battery_status_s::BATTERY_SOURCE_ESCS)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -107,7 +107,6 @@ EscBattery::Run()
|
||||
average_voltage_v,
|
||||
total_current_a,
|
||||
connected,
|
||||
battery_status_s::BATTERY_SOURCE_ESCS,
|
||||
priority);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user