#define ASSERT_ABOVE_(__A, __B)
double rate() const
Gets current rate (Hz)
A high-performance stopwatch, with typical resolution of nanoseconds.
A class for calling sleep() in a loop, such that the amount of sleep time will be computed to make th...
double m_currentEstimatedRate
double controllerParam_Kp() const
PI controller Kp parameter [default=1.0].
mrpt::system::CTicTac m_tic
double m_lastControlError
void followErrorRatioToRaiseWarning(double v)
#define ASSERT_BELOWEQ_(__A, __B)
A class for calling sleep() in a loop, such that the amount of sleep time will be computed to make th...
mrpt::system::CRateTimer m_ratetimer
the one control acts on
void controllerParam_Ti(double v)
void setRate(const double rate_hz)
Changes the object loop rate (Hz)
bool internalUpdateRateEstimate()
Versatile class for consistent logging and management of output messages.
#define ASSERT_ABOVEEQ_(__A, __B)
virtual ~CControlledRateTimer()=default
Dtor.
double actualControlledRate() const
Gets the actual controller output: the rate (Hz) of the internal CRateTimer object.
bool sleep()
Sleeps for some time, such as the return of this method is 1/rate (seconds) after the return of the p...
CControlledRateTimer(const double rate_hz=1.0)
Ctor: specifies the desired rate (Hz)
void controllerParam_Kp(double v)
double controllerParam_Ti() const
PI controller Ti parameter [default=0.0194].
void lowPassParam_a0(double v)
double lowPassParam_a0() const
Low-pass filter a0 value [default=0.9]: estimation = a0*input + (1-a0)*former_estimation.
double estimatedRateRaw() const
Last actual execution rate measured (Hz), without low-pass filtering.
double m_followErrorRatioForWarning
double followErrorRatioToRaiseWarning() const
Get/set ratio threshold for issuing a warning (via COutputLogger interface) if the achieved rate is n...
double estimatedRate() const
Gets the latest estimated run rate (Hz), which comes from actual period measurement,...
| Page generated by Doxygen 1.8.18 for MRPT 2.0.4 at Thu Sep 24 07:14:18 UTC 2020 | |