70 Test that the jacobian is correct
73 robot_state = RobotState(robot_model)
75 jacobian = robot_state.get_jacobian(
76 joint_model_group_name=
"panda_arm",
77 reference_point_position=np.array([0.0, 0.0, 0.0]),
80 self.assertIsInstance(jacobian, np.ndarray)
85 Test that the jacobian is correct
88 robot_state = RobotState(robot_model)
90 jacobian = robot_state.get_jacobian(
91 joint_model_group_name=
"panda_arm",
92 link_name=
"panda_link6",
93 reference_point_position=np.array([0.0, 0.0, 0.0]),
96 self.assertIsInstance(jacobian, np.ndarray)
101 Test that the joint group positions can be set
104 robot_state = RobotState(robot_model)
106 joint_group_positions = np.array([1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0])
107 robot_state.set_joint_group_positions(
108 joint_model_group_name=
"panda_arm", position_values=joint_group_positions
112 joint_group_positions.tolist(),
113 robot_state.get_joint_group_positions(
"panda_arm").tolist(),
118 Test that the joint group velocities can be set
121 robot_state = RobotState(robot_model)
123 joint_group_velocities = np.array([1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0])
124 robot_state.set_joint_group_velocities(
125 joint_model_group_name=
"panda_arm", velocity_values=joint_group_velocities
129 joint_group_velocities.tolist(),
130 robot_state.get_joint_group_velocities(
"panda_arm").tolist(),
135 Test that the joint group accelerations can be set
138 robot_state = RobotState(robot_model)
140 joint_group_accelerations = np.array([1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0])
141 robot_state.set_joint_group_accelerations(
142 joint_model_group_name=
"panda_arm",
143 acceleration_values=joint_group_accelerations,
147 joint_group_accelerations.tolist(),
148 robot_state.get_joint_group_accelerations(
"panda_arm").tolist(),