3 roslib.load_manifest(
'pr2_position_scripts')
11 torso_pub= rospy.Publisher(
'torso_controller/command', JointTrajectory)
12 rospy.init_node(
'torso_up')
14 while not rospy.is_shutdown():
15 traj = JointTrajectory()
16 traj.header.stamp = rospy.get_rostime()
17 traj.joint_names.append(
"torso_lift_joint");
18 traj.points.append(JointTrajectoryPoint())
19 traj.points[0].positions.append(0.0)
20 traj.points[0].velocities.append(0.1)
21 traj.points[0].time_from_start = rospy.Duration(0.25)
22 torso_pub.publish(traj)
23 rospy.sleep(rospy.Duration.from_sec(0.2))