iSpike
2.1
Spike conversion library for robotics
|
00001 #ifndef YARPANGLEREADER_HPP_ 00002 #define YARPANGLEREADER_HPP_ 00003 00004 #include <iSpike/Reader/AngleReader.hpp> 00005 #include <iSpike/YarpConnection.hpp> 00006 00007 #include <vector> 00008 #include <map> 00009 using namespace std; 00010 00011 namespace ispike { 00012 00014 class YarpAngleReader : public AngleReader { 00015 public: 00016 YarpAngleReader(string nameserverIP, unsigned nameserverPort); 00017 ~YarpAngleReader(); 00018 void initialize(map<string, Property>& properties); 00019 void setProperties(map<string, Property>& properties); 00020 void start(); 00021 00022 private: 00023 //========================= VARIABLES =========================== 00025 YarpConnection* yarpConnection; 00026 00028 string portName; 00029 00031 int sleepDuration_ms; 00032 00033 00034 //============================ METHODS =========================== 00035 void updateProperties(map<string, Property>& properties); 00036 void workerFunction(); 00037 00038 }; 00039 00040 } 00041 #endif /* YARPANGLEREADER_HPP_ */