JMotor
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
JControlLoop Class Referenceabstract

interface for control loop used by JMotorControllerClosed More...

#include <JControlLoop.h>

Inheritance diagram for JControlLoop:
Inheritance graph
[legend]

Public Member Functions

virtual float calc (JMotorControllerClosed *controller)=0
 
virtual void resetTime ()=0
 
float getError ()
 setpoint-position
 
float getCtrlLoopOut ()
 most recent value calculated by control loop in response to error (but not including feedforward) For example, if the control loop is a proportional loop, this function returns P * error
 
float getResult ()
 most recent value returned by calc() overall output to motor
 

Protected Attributes

float error
 
float ctrlLoopOut
 
float result
 

Detailed Description

interface for control loop used by JMotorControllerClosed

Member Function Documentation

◆ calc()

virtual float JControlLoop::calc ( JMotorControllerClosed controller)
pure virtual

Implemented in JControlLoopBasic.

◆ getCtrlLoopOut()

float JControlLoop::getCtrlLoopOut ( )
inline

most recent value calculated by control loop in response to error (but not including feedforward) For example, if the control loop is a proportional loop, this function returns P * error

Return values
(float)

◆ getError()

float JControlLoop::getError ( )
inline

setpoint-position

Return values
(float)

◆ getResult()

float JControlLoop::getResult ( )
inline

most recent value returned by calc() overall output to motor

Return values
(float)

◆ resetTime()

virtual void JControlLoop::resetTime ( )
pure virtual

Implemented in JControlLoopBasic.

Member Data Documentation

◆ ctrlLoopOut

float JControlLoop::ctrlLoopOut
protected

◆ error

float JControlLoop::error
protected

◆ result

float JControlLoop::result
protected

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