APM:Libraries
AP_BattMonitor_Params.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <AP_Param/AP_Param.h>
4 
6 public:
7  static const struct AP_Param::GroupInfo var_info[];
8 
10 
11  /* Do not allow copies */
12  AP_BattMonitor_Params(const AP_BattMonitor_Params &other) = delete;
14 
15  // Battery monitor driver types
24  };
25 
26  // low voltage sources (used for BATT_LOW_TYPE parameter)
30  };
31 
32  BattMonitor_Type type(void) const { return (enum BattMonitor_Type)_type.get(); }
34 
35  AP_Int8 _type;
36  AP_Int8 _volt_pin;
37  AP_Int8 _curr_pin;
38  AP_Float _volt_multiplier;
39  AP_Float _curr_amp_per_volt;
40  AP_Float _curr_amp_offset;
41  AP_Int32 _pack_capacity;
42  AP_Int16 _watt_max;
43  AP_Int32 _serial_number;
46  AP_Float _low_voltage;
47  AP_Float _low_capacity;
48  AP_Float _critical_voltage;
49  AP_Float _critical_capacity;
52 
53 };
AP_Float _low_voltage
voltage type used for detection of low voltage event
AP_Int8 _volt_pin
0=disabled, 3=voltage only, 4=voltage and current
AP_Float _critical_capacity
voltage level used to trigger a critical battery failsafe
AP_BattMonitor_Params & operator=(const AP_BattMonitor_Params &)=delete
static const struct AP_Param::GroupInfo var_info[]
AP_Float _critical_voltage
capacity level used to trigger a low battery failsafe
AP_Float _volt_multiplier
board pin used to measure battery current
BattMonitor_Type type(void) const
A system for managing and storing variables that are of general interest to the system.
AP_Int32 _pack_capacity
offset voltage that is subtracted from current pin before conversion to amps
AP_Int16 _watt_max
battery pack capacity less reserve in mAh
AP_Float _low_capacity
voltage level used to trigger a low battery failsafe
AP_Float _curr_amp_per_volt
voltage on volt pin multiplied by this to calculate battery voltage
AP_Int8 _low_voltage_timeout
battery serial number, automatically filled in on SMBus batteries
AP_Float _curr_amp_offset
voltage on current pin multiplied by this to calculate current in amps
BattMonitor_LowVoltage_Source failsafe_voltage_source(void)
AP_Int8 _failsafe_low_action
capacity level used to trigger a critical battery failsafe
AP_Int8 _failsafe_voltage_source
timeout in seconds before a low voltage event will be triggered
AP_Int32 _serial_number
max battery power allowed. Reduce max throttle to reduce current to satisfy t his limit ...
AP_Int8 _failsafe_critical_action
action to preform on a low battery failsafe
AP_Int8 _curr_pin
board pin used to measure battery voltage