Class UbetterBatteryModel
Defined in File ubetter_battery_model.hpp
Inheritance Relationships
Base Type
public ffw_robot_manager::BatteryModel(Class BatteryModel)
Class Documentation
-
class UbetterBatteryModel : public ffw_robot_manager::BatteryModel
Ubetter battery model implementation.
This class implements the voltage-to-SOC conversion for Ubetter batteries using the provided lookup table with linear interpolation.
Public Functions
-
UbetterBatteryModel()
-
~UbetterBatteryModel() override = default
-
virtual double voltage_to_soc(double voltage_v) const override
Convert voltage in Volts to SOC fraction.
- Parameters:
voltage_v – Voltage in Volts
- Returns:
SOC fraction (0.0 to 1.0)
-
virtual std::string get_model_name() const override
Get the battery model name.
- Returns:
Model name string
-
virtual std::pair<double, double> get_voltage_range() const override
Get the voltage range for this battery model.
- Returns:
Pair of (min_voltage_v, max_voltage_v)
-
virtual bool is_voltage_valid(double voltage_v) const override
Check if a voltage is within the valid range for this model.
- Parameters:
voltage_v – Voltage in Volts
- Returns:
True if voltage is within valid range
-
virtual uint8_t get_power_supply_technology() const override
Get the power supply technology for this battery model.
- Returns:
Power supply technology constant (e.g., POWER_SUPPLY_TECHNOLOGY_LIPO)
-
UbetterBatteryModel()