#include <AP_BattMonitor_SMBus_Solo.h>
|
| AP_BattMonitor_SMBus_Solo (AP_BattMonitor &mon, AP_BattMonitor::BattMonitor_State &mon_state, AP_BattMonitor_Params ¶ms, AP_HAL::OwnPtr< AP_HAL::I2CDevice > dev) |
|
| AP_BattMonitor_SMBus (AP_BattMonitor &mon, AP_BattMonitor::BattMonitor_State &mon_state, AP_BattMonitor_Params ¶ms, AP_HAL::OwnPtr< AP_HAL::I2CDevice > dev) |
| Constructor. More...
|
|
virtual | ~AP_BattMonitor_SMBus () |
|
bool | has_cell_voltages () const override |
|
bool | has_current () const override |
| returns true if battery monitor instance provides current info More...
|
|
void | init (void) override |
|
| AP_BattMonitor_Backend (AP_BattMonitor &mon, AP_BattMonitor::BattMonitor_State &mon_state, AP_BattMonitor_Params ¶ms) |
|
virtual | ~AP_BattMonitor_Backend (void) |
|
virtual bool | has_consumed_energy () const |
| returns true if battery monitor instance provides consumed energy info More...
|
|
uint8_t | capacity_remaining_pct () const |
| capacity_remaining_pct - returns the % battery capacity remaining (0 ~ 100) More...
|
|
void | update_resistance_estimate () |
|
virtual void | handle_bi_msg (float voltage, float current, float temperature) |
|
|
void | timer (void) override |
|
uint8_t | read_block (uint8_t reg, uint8_t *data, uint8_t max_len, bool append_zero) const |
|
|
enum | BATTMONITOR_SMBUS {
BATTMONITOR_SMBUS_TEMP = 0x08,
BATTMONITOR_SMBUS_VOLTAGE = 0x09,
BATTMONITOR_SMBUS_CURRENT = 0x0A,
BATTMONITOR_SMBUS_REMAINING_CAPACITY = 0x0F,
BATTMONITOR_SMBUS_FULL_CHARGE_CAPACITY = 0x10,
BATTMONITOR_SMBUS_SPECIFICATION_INFO = 0x1A,
BATTMONITOR_SMBUS_SERIAL = 0x1C,
BATTMONITOR_SMBUS_MANUFACTURE_NAME = 0x20,
BATTMONITOR_SMBUS_MANUFACTURE_DATA = 0x23
} |
|
void | read (void) override |
| read the battery_voltage and current, should be called at 10hz More...
|
|
bool | read_full_charge_capacity (void) |
|
bool | read_remaining_capacity (void) |
|
bool | read_temp (void) |
|
bool | read_serial_number (void) |
|
bool | read_word (uint8_t reg, uint16_t &data) const |
|
uint8_t | get_PEC (const uint8_t i2c_addr, uint8_t cmd, bool reading, const uint8_t buff[], uint8_t len) const |
| get_PEC - calculate packet error correction code of buffer More...
|
|
AP_HAL::OwnPtr< AP_HAL::I2CDevice > | _dev |
|
bool | _pec_supported |
|
int32_t | _serial_number = -1 |
|
uint16_t | _full_charge_capacity |
|
bool | _has_cell_voltages |
|
AP_BattMonitor & | _mon |
|
AP_BattMonitor::BattMonitor_State & | _state |
|
AP_BattMonitor_Params & | _params |
|
Definition at line 9 of file AP_BattMonitor_SMBus_Solo.h.
◆ AP_BattMonitor_SMBus_Solo()
◆ read_block()
uint8_t AP_BattMonitor_SMBus_Solo::read_block |
( |
uint8_t |
reg, |
|
|
uint8_t * |
data, |
|
|
uint8_t |
max_len, |
|
|
bool |
append_zero |
|
) |
| const |
|
private |
◆ timer()
void AP_BattMonitor_SMBus_Solo::timer |
( |
void |
| ) |
|
|
overrideprivatevirtual |
◆ _button_press_count
uint8_t AP_BattMonitor_SMBus_Solo::_button_press_count |
|
private |
The documentation for this class was generated from the following files: