Interface for motor controlling devices.
More...
#include <wpi/hardware/motor/MotorController.hpp>
|
| virtual | ~MotorController ()=default |
| virtual void | SetDutyCycle (double dutyCycle)=0 |
| | Sets the duty cycle of the motor controller.
|
| virtual void | SetVoltage (wpi::units::volt_t voltage) |
| | Sets the voltage output of the motor controller.
|
| virtual double | GetDutyCycle () const =0 |
| | Gets the duty cycle of the motor controller.
|
| virtual void | SetInverted (bool isInverted)=0 |
| | Sets the inversion state of the motor controller.
|
| virtual bool | GetInverted () const =0 |
| | Gets the inversion state of the motor controller.
|
| virtual void | Disable ()=0 |
| | Disables the motor controller.
|
Interface for motor controlling devices.
◆ ~MotorController()
| virtual wpi::MotorController::~MotorController |
( |
| ) |
|
|
virtualdefault |
◆ Disable()
| virtual void wpi::MotorController::Disable |
( |
| ) |
|
|
pure virtual |
◆ GetDutyCycle()
| virtual double wpi::MotorController::GetDutyCycle |
( |
| ) |
const |
|
pure virtual |
◆ GetInverted()
| virtual bool wpi::MotorController::GetInverted |
( |
| ) |
const |
|
pure virtual |
◆ SetDutyCycle()
| virtual void wpi::MotorController::SetDutyCycle |
( |
double | dutyCycle | ) |
|
|
pure virtual |
◆ SetInverted()
| virtual void wpi::MotorController::SetInverted |
( |
bool | isInverted | ) |
|
|
pure virtual |
◆ SetVoltage()
| virtual void wpi::MotorController::SetVoltage |
( |
wpi::units::volt_t | voltage | ) |
|
|
virtual |
Sets the voltage output of the motor controller.
Compensates for the current bus voltage to ensure that the desired voltage is output even if the battery voltage is below 12V - highly useful when the voltage outputs are "meaningful" (e.g. they come from a feedforward calculation).
NOTE: This function must be called regularly in order for voltage compensation to work properly - unlike the ordinary set function, it is not "set it and forget it."
- Parameters
-
The documentation for this class was generated from the following file: