42 roslib.load_manifest(
'fingertip_pressure')
44 from math
import sin, cos
47 from pr2_msgs.msg
import PressureState
59 ps.header.stamp = rospy.get_rostime();
64 ph = .1 * t * (i / 22. + 1)
65 ps.l_finger_tip.append(4000*(1+sin(ph)))
66 ps.r_finger_tip.append(4000*(1+cos(ph)))
70 rospy.init_node(
'sim_sensor', anonymous=
True)
73 self.
pub = rospy.Publisher(dest, PressureState)
76 if __name__ ==
'__main__':
81 while not rospy.is_shutdown():
def callback(self, pressurestate)