The CalibrationChecker class consumes primary packages ignoring all but KinematicsInfo packages. These are then checked against the used kinematics to see if the correct calibration is used. More...
#include <calibration_checker.h>
Public Member Functions | |
CalibrationChecker (const std::string &expected_hash) | |
Creates a new CalibrationChecker object with an expected hash calculated from the used kinematics. More... | |
virtual bool | consume (std::shared_ptr< primary_interface::PrimaryPackage > product) |
Consumes a package, checking its hash if it is a KinematicsInfo package. If the hash does not match the expected hash, an error is logged. More... | |
bool | isChecked () |
Used to make sure the calibration check is not performed several times. More... | |
virtual void | onTimeout () |
Handles timeouts. More... | |
virtual void | setupConsumer () |
Empty setup function, as no setup is needed. More... | |
virtual void | stopConsumer () |
Stops the consumer. More... | |
virtual void | teardownConsumer () |
Tears down the consumer. More... | |
virtual | ~CalibrationChecker ()=default |
Private Attributes | |
bool | checked_ |
std::string | expected_hash_ |
The CalibrationChecker class consumes primary packages ignoring all but KinematicsInfo packages. These are then checked against the used kinematics to see if the correct calibration is used.
Definition at line 41 of file calibration_checker.h.
urcl::CalibrationChecker::CalibrationChecker | ( | const std::string & | expected_hash | ) |
Creates a new CalibrationChecker object with an expected hash calculated from the used kinematics.
expected_hash | The expected kinematics hash |
Definition at line 32 of file calibration_checker.cpp.
|
virtualdefault |
|
virtual |
Consumes a package, checking its hash if it is a KinematicsInfo package. If the hash does not match the expected hash, an error is logged.
product | The package to consume |
Implements urcl::comm::IConsumer< primary_interface::PrimaryPackage >.
Definition at line 36 of file calibration_checker.cpp.
|
inline |
Used to make sure the calibration check is not performed several times.
Definition at line 93 of file calibration_checker.h.
|
inlinevirtual |
Handles timeouts.
Reimplemented from urcl::comm::IConsumer< primary_interface::PrimaryPackage >.
Definition at line 74 of file calibration_checker.h.
|
inlinevirtual |
Empty setup function, as no setup is needed.
Reimplemented from urcl::comm::IConsumer< primary_interface::PrimaryPackage >.
Definition at line 56 of file calibration_checker.h.
|
inlinevirtual |
Stops the consumer.
Reimplemented from urcl::comm::IConsumer< primary_interface::PrimaryPackage >.
Definition at line 68 of file calibration_checker.h.
|
inlinevirtual |
Tears down the consumer.
Reimplemented from urcl::comm::IConsumer< primary_interface::PrimaryPackage >.
Definition at line 62 of file calibration_checker.h.
|
private |
Definition at line 100 of file calibration_checker.h.
|
private |
Definition at line 99 of file calibration_checker.h.