Skip to content

Commit b173e63

Browse files
[py] Add config variable to specify whether end-effector task should be formulated in local frame or world frame.
1 parent 96c6728 commit b173e63

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

exercizes/tsid_manipulator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ def __init__(self, conf, viewer=True):
4545
self.eeTask.setKp(self.conf.kp_ee * np.ones(6))
4646
self.eeTask.setKd(2.0 * np.sqrt(self.conf.kp_ee) * np.ones(6))
4747
self.eeTask.setMask(conf.ee_task_mask)
48-
self.eeTask.useLocalFrame(False)
48+
self.eeTask.useLocalFrame(conf.ee_task_local_frame)
4949
self.EE = model.getFrameId(conf.ee_frame_name)
5050
H_ee_ref = self.robot.framePosition(formulation.data(), self.EE)
5151
self.trajEE = tsid.TrajectorySE3Constant("traj-ee", H_ee_ref)

exercizes/ur5_conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434

3535
ee_frame_name = "ee_fixed_joint" # end-effector frame name
3636
ee_task_mask = np.array([1., 1, 1, 0, 0, 0])
37+
ee_task_local_frame = False # specifies whether task is formulated in local frame
3738

3839
PRINT_N = 500 # print every PRINT_N time steps
3940
DISPLAY_N = 20 # update robot configuration in viwewer every DISPLAY_N time steps

exercizes/ur5_reaching_conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434

3535
ee_frame_name = "ee_fixed_joint" # end-effector frame name
3636
ee_task_mask = np.array([1., 1, 1, 0, 0, 0])
37+
ee_task_local_frame = False # specifies whether task is formulated in local frame
3738

3839
PRINT_N = 500 # print every PRINT_N time steps
3940
DISPLAY_N = 20 # update robot configuration in viwewer every DISPLAY_N time steps

0 commit comments

Comments
 (0)