sr_virtual_tactile_sensor.hpp
Go to the documentation of this file.
1 /*
2 * Copyright 2011 Shadow Robot Company Ltd.
3 *
4 * This program is free software: you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the Free
6 * Software Foundation version 2 of the License.
7 *
8 * This program is distributed in the hope that it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
11 * more details.
12 *
13 * You should have received a copy of the GNU General Public License along
14 * with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16 
29 #ifndef _SR_VIRTUAL_TACTILE_SENSOR_HPP_
30 #define _SR_VIRTUAL_TACTILE_SENSOR_HPP_
31 
32 #include <ros/ros.h>
33 
34 #include <boost/thread/mutex.hpp>
35 #include <string>
36 #include <vector>
37 
39 
40 #include <sr_robot_msgs/joints_data.h>
41 #include <sr_robot_msgs/joint.h>
42 
43 namespace shadowrobot
44 {
47 {
48 public:
60  SrVirtualTactileSensor(std::string name, std::string touch_name);
61 
63 
69  virtual double get_touch_data();
70 
71 private:
73  boost::mutex touch_mutex;
74  double touch_value;
75 
79  std::vector<std::string> names_joints_linked;
85 
94  void callback(const sr_robot_msgs::joints_dataConstPtr &msg);
95 };
96 
99 {
100 public:
102 
104 };
105 } // namespace shadowrobot
106 
107 /* For the emacs weenies in the crowd.
108 Local Variables:
109  c-basic-offset: 2
110 End:
111 */
112 
113 #endif
This is a generic parent class for the tactile sensors used in the Shadow Robot Dextrous Hand...
void callback(const sr_robot_msgs::joints_dataConstPtr &msg)
SrVirtualTactileSensor(std::string name, std::string touch_name)


sr_tactile_sensors
Author(s): Ugo Cupcic
autogenerated on Mon Feb 28 2022 23:52:14