rmf_battery

A package for managing batteries in OpenRMF.

rmf_battery API

Class Hierarchy

File Hierarchy

Full API

Namespaces

Classes and Structs

Class BatterySystem
Class Documentation
class rmf_battery::agv::BatterySystem

Public Functions

double nominal_voltage() const

Get the nominal voltage of this battery system.

double capacity() const

Get the capacity of this battery system.

double charging_current() const

Get the charging current of this battery system.

Public Static Functions

static std::optional<BatterySystem> make(double nominal_voltage, double capacity, double charging_current)

Returns a BatterySystem object if valid values were supplied for the various fields else returns std::nullopt. Here valid implies that the values are greater than zero.

Parameters
  • [in] nominal_voltage: The nominal voltage of the battery in Volts

  • [in] capacity: The nominal capacity of the battery in Ampere-hours

  • [in] charging_current: The rated current in Amperes for charging the battery

Class MechanicalSystem
Class Documentation
class rmf_battery::agv::MechanicalSystem

Public Functions

double mass() const

Get the mass of this mechanical system.

double moment_of_inertia() const

Get the moment of inertia of this mechanical system.

double friction_coefficient() const

Get the friction coefficient of this mechanical system.

Public Static Functions

static std::optional<MechanicalSystem> make(double mass, double moment_of_inertia, double friction_coefficient)

Returns a MechanicalSystem object if valid values were supplied for the various fields else returns std::nullopt. Here valid implies that the values are greater than zero.

Parameters
  • [in] mass: The mass of the robot in Kilograms(kg)

  • [in] moment_of_inertia: The moment of inertia of the robot along its yaw axis in kg.m^2

  • [in] friction_coefficient: The coefficient of kinetic friction or rolling resistance coefficient measured at the wheels of the robot. This value is used to compute the energy loss due to rotation of the vehicle’s wheels during locomotion. This value is the dimensionless constant Crr as described in the reference below. Ref: https://en.wikipedia.org/wiki/Rolling_resistance#Rolling_resistance_coefficient

Class PowerSystem
Class Documentation
class rmf_battery::agv::PowerSystem

Public Functions

double nominal_power() const

Get the nominal power of this power system.

Public Static Functions

static std::optional<PowerSystem> make(double nominal_power)

Returns a PowerSystem object if valid values were supplied for the various fields else returns std::nullopt. Here valid implies that the values are greater than zero.

Parameters
  • [in] nominal_power: The rated nominal power consumption in Watts for this power system

Class SimpleDevicePowerSink
Inheritance Relationships
Base Type
Class Documentation
class rmf_battery::agv::SimpleDevicePowerSink : public rmf_battery::DevicePowerSink

Public Functions

SimpleDevicePowerSink(const BatterySystem &battery_system, const PowerSystem &power_system)

Constructor

Parameters

const BatterySystem &battery_system() const

Get a constant reference to the battery system.

const PowerSystem &power_system() const

Get a constant reference to the power system.

virtual double compute_change_in_charge(const double run_time) const final

Compute change in state-of-charge of the battery due to an onboard device over a time period.

Return

The charge depleted as a fraction of the total battery capacity

Parameters
  • [in] run_time: The duration in seconds over which the power system drains charge from the battery

Class SimpleMotionPowerSink
Inheritance Relationships
Base Type
Class Documentation
class rmf_battery::agv::SimpleMotionPowerSink : public rmf_battery::MotionPowerSink

Public Functions

SimpleMotionPowerSink(const BatterySystem &battery_system, const MechanicalSystem &mechanical_system)

Constructor

Parameters

const BatterySystem &battery_system() const

Get a constant reference to the battery system.

const MechanicalSystem &mechanical_system() const

Get a constant reference to the mechanical system.

virtual double compute_change_in_charge(const rmf_traffic::Trajectory &trajectory) const final

Compute change in state-of-charge estimate of battery due to locomotion of the robot along a trajectory.

Return

The charge depleted as a fraction of the total battery capacity

Parameters
  • [in] trajectory: A valid rmf_traffic:::Trajectory over which the change in charge has to to be computed

Class DevicePowerSink
Inheritance Relationships
Derived Type
Class Documentation
class rmf_battery::DevicePowerSink

Subclassed by rmf_battery::agv::SimpleDevicePowerSink

Public Functions

virtual double compute_change_in_charge(const double run_time) const = 0

Compute change in state-of-charge of the battery due to an onboard device over a time period.

Return

The charge depleted as a fraction of the total battery capacity

Parameters
  • [in] run_time: The duration in seconds over which the power system drains charge from the battery

virtual ~DevicePowerSink() = default
Class MotionPowerSink
Inheritance Relationships
Derived Type
Class Documentation
class rmf_battery::MotionPowerSink

Subclassed by rmf_battery::agv::SimpleMotionPowerSink

Public Functions

virtual double compute_change_in_charge(const rmf_traffic::Trajectory &trajectory) const = 0

Compute change in state-of-charge of the battery due to locomotion of the robot along a trajectory.

Return

The charge depleted as a fraction of the total battery capacity

Parameters
  • [in] trajectory: A valid rmf_traffic:::Trajectory over which the change in charge has to to be computed

virtual ~MotionPowerSink() = default

Typedefs

Typedef rmf_battery::agv::BatterySystemPtr
Typedef Documentation
using rmf_battery::agv::BatterySystemPtr = std::shared_ptr<BatterySystem>
Typedef rmf_battery::agv::ConstBatterySystemPtr
Typedef Documentation
using rmf_battery::agv::ConstBatterySystemPtr = std::shared_ptr<const BatterySystem>
Typedef rmf_battery::agv::ConstMechanicalSystemPtr
Typedef Documentation
using rmf_battery::agv::ConstMechanicalSystemPtr = std::shared_ptr<const MechanicalSystem>
Typedef rmf_battery::agv::ConstPowerSystemPtr
Typedef Documentation
using rmf_battery::agv::ConstPowerSystemPtr = std::shared_ptr<const PowerSystem>
Typedef rmf_battery::agv::MechanicalSystemPtr
Typedef Documentation
using rmf_battery::agv::MechanicalSystemPtr = std::shared_ptr<MechanicalSystem>
Typedef rmf_battery::agv::PowerSystemPtr
Typedef Documentation
using rmf_battery::agv::PowerSystemPtr = std::shared_ptr<PowerSystem>
Typedef rmf_battery::ConstDevicePowerSinkPtr
Typedef Documentation
using rmf_battery::ConstDevicePowerSinkPtr = std::shared_ptr<const DevicePowerSink>
Typedef rmf_battery::ConstMotionPowerSinkPtr
Typedef Documentation
using rmf_battery::ConstMotionPowerSinkPtr = std::shared_ptr<const MotionPowerSink>
Typedef rmf_battery::DevicePowerSinkPtr
Typedef Documentation
using rmf_battery::DevicePowerSinkPtr = std::shared_ptr<DevicePowerSink>
Typedef rmf_battery::MotionPowerSinkPtr
Typedef Documentation
using rmf_battery::MotionPowerSinkPtr = std::shared_ptr<MotionPowerSink>