RBE1001Lib
Public Member Functions
LeftMotor Class Reference

#include <RBE1001Lib.h>

Inheritance diagram for LeftMotor:
Inheritance graph
[legend]
Collaboration diagram for LeftMotor:
Collaboration graph
[legend]

Public Member Functions

 LeftMotor ()
 
- Public Member Functions inherited from Motor
float getInterpolationUnitIncrement ()
 
 Motor (int pwmPin, int dirPin, int encAPin, int encBPin)
 A PID Motor class using FreeRTOS threads, ESP32Encoder and ESP32PWM. More...
 
virtual ~Motor ()
 
void attach ()
 Attach the motors hardware. More...
 
void setEffort (float effort)
 
void setEffortPercent (float percent)
 
float getEffort ()
 
float getEffortPercent ()
 
float getDegreesPerSecond ()
 
float getCurrentDegrees ()
 
void loop ()
 
void setSetpointWithTime (float newTargetInDegrees, long miliseconds, interpolateMode mode)
 
void setSpeed (float newDegreesPerSecond)
 
void setSpeed (float newDegreesPerSecond, long miliseconds)
 
void moveTo (float newTargetInDegrees, float speedDegPerSec)
 
void moveFor (float deltaTargetInDegrees, float speedDegPerSec)
 
void blockUntilMoveIsDone ()
 wait for the motor to arrive at a setpoint More...
 
float startMoveFor (float deltaTargetInDegrees, float speedDegPerSec)
 
void setSetpoint (float newTargetInDegrees)
 
void setSetpointWithLinearInterpolation (float newTargetInDegrees, long miliseconds)
 
void setSetpointWithSinusoidalInterpolation (float newTargetInDegrees, long miliseconds)
 
void setSetpointWithBezierInterpolation (float newTargetInDegrees, long miliseconds, float Control_0=0.5, float Control_1=1.0)
 
void setSetpointWithTrapezoidalInterpolation (float newTargetInDegrees, long miliseconds, float trapazoidalTime)
 
void setGains (float p, float i, float d)
 
void setGainsP (float p)
 
void setGainsI (float i)
 
void setGainsD (float d)
 
float getGainsP ()
 
float getGainsI ()
 
float getGainsD ()
 
bool isMotorDoneWithMove ()
 Check to see if the motor is done with a move. More...
 

Additional Inherited Members

- Data Fields inherited from Motor
int MotorPWMPin = -1
 
int directionFlag = -1
 
int MotorEncAPin = -1
 
int MotorEncBPin = -1
 
int64_t nowEncoder = 0
 
- Static Public Attributes inherited from Motor
static bool timersAllocated = false
 
static Motorlist [MAX_POSSIBLE_MOTORS]
 

Detailed Description

Definition at line 67 of file RBE1001Lib.h.

Constructor & Destructor Documentation

◆ LeftMotor()

LeftMotor::LeftMotor ( )
inline

Definition at line 70 of file RBE1001Lib.h.

References MOTOR_LEFT_DIR, MOTOR_LEFT_ENCA, MOTOR_LEFT_ENCB, and MOTOR_LEFT_PWM.


The documentation for this class was generated from the following file: