本文整理汇总了Python中geometry_msgs.msg.Twist.joint_names方法的典型用法代码示例。如果您正苦于以下问题:Python Twist.joint_names方法的具体用法?Python Twist.joint_names怎么用?Python Twist.joint_names使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类geometry_msgs.msg.Twist
的用法示例。
在下文中一共展示了Twist.joint_names方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: initial_arm
# 需要导入模块: from geometry_msgs.msg import Twist [as 别名]
# 或者: from geometry_msgs.msg.Twist import joint_names [as 别名]
class VisualServoExecutionNode:
def initial_arm(self, cs):
rospy.loginfo('Setting to Initial msg...')
cs.carefree_switch('l', '%s_arm', '$(find visual_servo)/params/rmc_joint_trajectory_params.yaml' )
rospy.sleep(0.5)
pub = rospy.Publisher('l_arm/command', JointTrajectory)
msg = JointTrajectory()
pts = JointTrajectoryPoint()
<<<<<<< HEAD
pts.positions = array('d', [0.323, -0.6460, 0.00,
-1.273, -10.512, 0.0570, 0.163])
pts.time_from_start = rospy.Duration(3.0)
msg.points = [pts]
msg.joint_names = ['l_shoulder_pan_joint', 'l_shoulder_lift_joint', 'l_upper_arm_roll_joint','l_elbow_flex_joint', 'l_forearm_roll_joint','l_wrist_flex_joint','l_wrist_roll_joint']
# msg.joint_names = ['r_shoulder_pan_joint', 'r_shoulder_lift_joint', 'r_upper_arm_roll_joint','r_elbow_flex_joint', 'r_forearm_roll_joint','r_wrist_flex_joint','r_wrist_roll_joint']
=======
pts.positions = array('d', [-1.32734204881265387, -0.64601608409943324, -1.4620635485239604,
-1.2729772622637399, -10.5123303230158518, 0.0570651396529178, 0.163787989862169])
pts.time_from_start = rospy.Duration(3.0)
msg.points = [pts]
msg.joint_names = ['r_shoulder_pan_joint', 'r_shoulder_lift_joint', 'r_upper_arm_roll_joint',
'r_elbow_flex_joint', 'r_forearm_roll_joint','r_wrist_flex_joint','r_wrist_roll_joint']
>>>>>>> 04206a0d0c433a3c0ca22cced7672835d0b6a8a5
# pub.publish(msg)
rospy.sleep(0.5)
# pub.publish(msg)
rospy.sleep(3)
<<<<<<< HEAD