1 #ifndef ROBOT_CONTROL_SENSOR_THREAD_HPP
2 #define ROBOT_CONTROL_SENSOR_THREAD_HPP
4 #include "robot_control/SensorCommunicator.hpp"
5 #include "minotaur_common/Thread.hpp"
13 class SensorThread:
public Thread
16 pthread_mutex_t intervalMutex;
17 int samplingIntervalMsec;
18 SensorCommunicator &sensorCommunicator;
20 volatile bool keepRunning;
22 void publishSensorData();
27 SensorThread(SensorCommunicator &p_sensorCommunicator);
35 void setSamplingInterval(
const int p_samplingIntervalMsec);
36 int getSamplingInterval();