This class defines a common interface for converting from speed to driver input. It should compensate for factors like motor response and supply voltage.
More...
#include <JMotorCompensator.h>
|
void | setDriverRange (float _driverRange) |
| set what value makes the driver output 100% of supply voltage
|
|
void | setMaxDriverRangeAmount (float _driverRangeAmount) |
| set what fraction of driverRange can be used
|
|
virtual float | compensate (float val) |
| calculate
|
|
virtual float | getMaxVel () |
| How fast of a motor speed setting would get adjusted to full motor power.
|
|
virtual float | getMinVel () |
| Slowest speed motor can go.
|
|
float | getDriverRange () |
| get what value makes the driver output 100% of supply voltage
|
|
float | getMaxDriverRangeAmount () |
| get what fraction of driverRange can be used
|
|
This class defines a common interface for converting from speed to driver input. It should compensate for factors like motor response and supply voltage.
◆ compensate()
virtual float JMotorCompensator::compensate |
( |
float |
val | ) |
|
|
virtual |
◆ getDriverRange()
float JMotorCompensator::getDriverRange |
( |
| ) |
|
|
inline |
get what value makes the driver output 100% of supply voltage
- Return values
-
◆ getMaxDriverRangeAmount()
float JMotorCompensator::getMaxDriverRangeAmount |
( |
| ) |
|
|
inline |
get what fraction of driverRange can be used
- Return values
-
◆ getMaxVel()
virtual float JMotorCompensator::getMaxVel |
( |
| ) |
|
|
virtual |
◆ getMinVel()
virtual float JMotorCompensator::getMinVel |
( |
| ) |
|
|
virtual |
◆ setDriverRange()
void JMotorCompensator::setDriverRange |
( |
float |
_driverRange | ) |
|
|
inline |
set what value makes the driver output 100% of supply voltage
- Parameters
-
_driverRange | (float) max range of driver |
◆ setMaxDriverRangeAmount()
void JMotorCompensator::setMaxDriverRangeAmount |
( |
float |
_driverRangeAmount | ) |
|
|
inline |
set what fraction of driverRange can be used
- Parameters
-
_driverRangeAmount | (float) |
◆ driverRange
float JMotorCompensator::driverRange = 1.0 |
|
protected |
◆ maxDriverRange
float JMotorCompensator::maxDriverRange = 1.0 |
|
protected |
The documentation for this class was generated from the following file: