ardupilot/Tools/AP_Periph/batt_balance.h
Andrew Tridgell bc825fb4c1 AP_Periph: added battery balance plug node
this supports a periph node attached to a LiPo battery balance plug,
reporting via BatteryInfoAux
2023-08-26 21:12:42 +10:00

25 lines
426 B
C++

#pragma once
#ifdef HAL_PERIPH_ENABLE_BATTERY_BALANCE
class BattBalance {
public:
friend class AP_Periph_FW;
BattBalance(void);
static const struct AP_Param::GroupInfo var_info[];
private:
AP_Int8 num_cells;
AP_Int8 id;
AP_Int8 cell1_pin;
AP_Float rate;
uint32_t last_send_ms;
AP_HAL::AnalogSource **cells;
uint8_t cells_allocated;
};
#endif // HAL_PERIPH_ENABLE_BATTERY_BALANCE