MAGIKS
1.1
Manipulator General Inverse Kinematic Solver
|
Variables | |
larm_reached = True | |
A boolean global variable indicating if the left arm joints have reached their target. More... | |
rarm_reached = True | |
A boolean global variable indicating if the right arm joints have reached their target. More... | |
body_reached = False | |
A boolean global variable indicating if the body joints (non-arm joints) have reached their target. More... | |
larm_failed = False | |
A boolean global variable indicating if the left arm joints failed to reach their target. More... | |
rarm_failed = False | |
body_failed = False | |
int | counter = 0 |
int | bl_cnt = 0 |
Counter for the base laser scan. More... | |
int | rt_cnt = 0 |
Counter for the raw trajectory function calls. More... | |
bl_dist = None | |
bl_active = False | |
int | tl_cnt = 0 |
tl_dist = None | |
tl_active = False | |
rt_orientation = None | |
tuple | rt_position = numpy.zeros(3) |
tuple | rt_velocity = numpy.zeros(3) |
tuple | rt_acceleration = numpy.zeros(3) |
rt_active = False | |
def magiks.specific_geometries.pr2.pyride_interpreter.activate_base_laser | ( | ) |
Definition at line 521 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.activate_tilt_laser | ( | ) |
Definition at line 526 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.activate_trajectory_input | ( | ) |
To start receiving raw trajectory input, you should send a ROS service request call: rosservice call /rhyth_dmp/recall_dmp_traj <figure name> <amplitude> <frequency> <sampling frequency> <number of cycles> For example: rosservice call /rhyth_dmp/recall_dmp_traj fig8 0.05 0.2 20 3 generates 3 cycles of figure eight with frequency 1.0
Definition at line 497 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.bl_midpoint | ( | ) |
Returns the univrsal coordinates of the base laser middle point
Definition at line 481 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.body_angle | ( | in_degrees = True | ) |
Definition at line 470 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.body_position | ( | ) |
Definition at line 467 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.deactivate_base_laser | ( | ) |
Definition at line 531 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.deactivate_tilt_laser | ( | ) |
Definition at line 536 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.deactivate_trajectory_input | ( | ) |
Definition at line 511 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.finished | ( | limb_list = ['body' , |
|
rarm, | |||
larm | |||
) |
returns True if the motion of all the items in the limb_list is reached or failed.
Definition at line 662 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_larm_joint_dict | ( | q, | |
time_to_reach = 5.0 |
|||
) |
Use this function to convert a vector of left arm joint values, into a joint dictionary known by pyride.
q | A numpy vector of 7 elements containing the desired left arm joint values A float specifying the amount of time (in seconds) needed to reach the target |
Definition at line 165 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_larm_joint_posvel_dict | ( | q, | |
q_dot, | |||
time_to_reach | |||
) |
Definition at line 177 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_larm_joint_vector_from_dic | ( | g | ) |
Definition at line 200 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_larm_joint_vel_dict | ( | q | ) |
Definition at line 181 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_rarm_joint_dict | ( | q, | |
time_to_reach = 5.0 |
|||
) |
Definition at line 169 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_rarm_joint_posvel_dict | ( | q, | |
q_dot, | |||
time_to_reach | |||
) |
Definition at line 173 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_rarm_joint_vector_from_dic | ( | g | ) |
Definition at line 189 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.gen_rarm_joint_vel_dict | ( | q | ) |
Definition at line 185 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_elbow_flex_joint | ( | in_degrees = True | ) |
returns the current angle of the shoulder pan joint of the left arm
Definition at line 257 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_elbow_position | ( | ) |
returns the elbow position of the right arm comparable to function wrist_position() in the arm object
Definition at line 361 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_joints | ( | in_degrees = True | ) |
Definition at line 287 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_shoulder_lift_joint | ( | in_degrees = True | ) |
returns the current angle of the shoulder lift joint of the left arm
Definition at line 246 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_shoulder_pan_joint | ( | in_degrees = True | ) |
returns the current angle of the shoulder pan joint of the left arm
Definition at line 213 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_wrist_orientation | ( | ) |
returns the wrist orientation of the left arm (the same orientation returned by function wrist_orientation() in the arm object but in quaternions)
Definition at line 307 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.larm_wrist_position | ( | ) |
returns the wrist position of the left arm comparable to function wrist_position() in the arm object
Definition at line 295 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.look_lg | ( | ) |
Definition at line 583 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.look_rg | ( | ) |
Definition at line 588 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.move_robot_to | ( | x, | |
y, | |||
tau, | |||
time_to_reach = 5.0 , |
|||
in_degrees = True |
|||
) |
Definition at line 638 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_base_laser | ( | range, | |
intensity | |||
) |
Definition at line 121 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_move_arm_failed | ( | is_left_arm | ) |
Callback function for arm reach failure: This function is called when the arm joints fail to reach their target values Global variable larm_failed or rarm_failed will be switched to True depending on which arm is specified by argument is_left_arm.
is_left_arm | A boolean parameter specifying which arm is considered: True for the left arm and False for the right arm. |
Definition at line 100 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_move_arm_finished | ( | is_left_arm | ) |
Callback function for arm reach: This function is called when the arm joints reach their target values Global variable larm_reached or rarm_reached will be switched to True depending on which arm is specified by argument is_left_arm.
is_left_arm | A boolean parameter specifying which arm is considered: True for the left arm and False for the right arm. |
Definition at line 84 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_move_body_failed | ( | ) |
Definition at line 116 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_move_body_finished | ( | ) |
Definition at line 111 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_tilt_laser | ( | range, | |
intensity | |||
) |
Definition at line 127 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.on_trajectory_received | ( | data | ) |
Definition at line 139 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.pos_larm_grip | ( | ) |
Returns the global position of the left arm gripper finger tip
Definition at line 443 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.pos_larm_grip_wrt_tor | ( | ) |
Returns the left arm gripper position vector(endeffector position) with respect to the (torso) at the origin. The torso origin is at the floor footprint (projection) of the middle point between the two shoulder pan joint centers. The torso origin is about 51 mm below the base_link origin and 50 mm shifted towards the back. The orientations of torso and base are identical.
Definition at line 387 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.pos_larm_grip_wrt_tor_shpan | ( | ) |
Returns the left arm gripper position vector(endeffector position) with respect to the torso shoulder pan joint center
Definition at line 409 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.pos_rarm_grip | ( | ) |
Returns the global position of the right arm gripper finger tip
Definition at line 423 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.pos_rarm_grip_wrt_tor | ( | ) |
Returns the right arm gripper position vector(endeffector position) with respect to the (torso) at the origin. (Refer to pos_larm_grip_wrt_tor())
Definition at line 399 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.pos_rarm_grip_wrt_tor_shpan | ( | ) |
Returns the right arm gripper position vector(endeffector position) with respect to the torso shoulder pan joint center
Definition at line 373 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_elbow_flex_joint | ( | in_degrees = True | ) |
returns the current angle of the shoulder pan joint of the right arm
Definition at line 268 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_elbow_position | ( | ) |
returns the elbow position of the right arm comparable to function wrist_position() in the arm object
Definition at line 349 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_joints | ( | in_degrees = True | ) |
Definition at line 279 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_shoulder_lift_joint | ( | in_degrees = True | ) |
returns the current angle of the shoulder lift joint of the right arm
Definition at line 235 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_shoulder_pan_joint | ( | in_degrees = True | ) |
returns the current angle of the shoulder pan joint of the right arm
Definition at line 224 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_wrist_orientation | ( | ) |
returns the wrist orientation of the right arm (the same orientation returned by function wrist_orientation() in the arm object but in quaternions)
Definition at line 314 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rarm_wrist_position | ( | ) |
returns the wrist position of the right arm comparable to function wrist_position() in the arm object
Definition at line 337 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.rotate_robot_to | ( | desired_angle, | |
time_to_reach = None , |
|||
in_degrees = True |
|||
) |
Definition at line 622 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.run_config_trajectory | ( | j_traj, | |
duration = 10.0 , |
|||
dt = None , |
|||
phi_dot = None , |
|||
is_left_arm = False |
|||
) |
Runs a given arm joint trajectory on the robot.
j_traj | An instance of class packages.nima.robotics.kinematics.task_space.trajectory.Trajectory() |
Definition at line 751 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.run_navigation_trajectory | ( | duration, | |
pos_traj, | |||
ori_traj, | |||
phi_dot = 1.0 , |
|||
k = 1.0 |
|||
) |
Definition at line 692 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.send_arm_joint_speed | ( | q_dot, | |
is_left_arm = False |
|||
) |
Definition at line 788 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.set_callback_functions | ( | ) |
Definition at line 133 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.set_lg | ( | x = 1 | ) |
sets the position of left gripper from 0 to 8
Definition at line 541 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.set_rg | ( | x = 1 | ) |
sets the position of right gripper from 0 to 8
Definition at line 552 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.take_larm_to | ( | qd, | |
time_to_reach = 5.0 |
|||
) |
Definition at line 599 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.take_rarm_to | ( | qd, | |
time_to_reach = 5.0 |
|||
) |
Definition at line 592 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.take_robot_to | ( | X, | |
Y, | |||
time_to_reach = 5.0 |
|||
) |
Definition at line 606 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.twist_forearm | ( | angle = 180.0 , |
|
is_left_arm = True |
|||
) |
Definition at line 563 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.twist_lg | ( | angle = 180.0 | ) |
Definition at line 573 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.twist_rg | ( | angle = 180.0 | ) |
Definition at line 578 of file pyride_interpreter.py.
def magiks.specific_geometries.pr2.pyride_interpreter.wait_until_finished | ( | limb_list = ['body' , |
|
rarm, | |||
larm, | |||
max_time = 20.0 |
|||
) |
waits until the motion of the items in the limb_list is reached or failed. the function will return False if the motion of items is not finished by the max_time
Definition at line 676 of file pyride_interpreter.py.
bl_active = False |
Definition at line 66 of file pyride_interpreter.py.
int bl_cnt = 0 |
Counter for the base laser scan.
This counter starts increasing as soon as the base laser scan is activated by function activate_base_laser()
Definition at line 60 of file pyride_interpreter.py.
bl_dist = None |
Definition at line 65 of file pyride_interpreter.py.
body_failed = False |
Definition at line 55 of file pyride_interpreter.py.
body_reached = False |
A boolean global variable indicating if the body joints (non-arm joints) have reached their target.
Set as True by default, this variable switches to False immidiately after any move function is called for the body navigation joints or the prismatic lifter joint and is set back to True when the body joints reach their target, so it always shows the status of the lastest task.
Definition at line 45 of file pyride_interpreter.py.
int counter = 0 |
Definition at line 56 of file pyride_interpreter.py.
larm_failed = False |
A boolean global variable indicating if the left arm joints failed to reach their target.
Set as False by default, this variable switches to True only if any move arm task function is called and the left arm can not reach its target within a certain time. It is set back to False immidiately after a move arm task function is called for left arm, so it always shows the status of the lastest task.
Definition at line 51 of file pyride_interpreter.py.
larm_reached = True |
A boolean global variable indicating if the left arm joints have reached their target.
Set as True by default, this variable switches to False immidiately after any move arm task function is called for the left arm and is set back to True when the left arm reaches its target
Definition at line 34 of file pyride_interpreter.py.
rarm_failed = False |
Definition at line 54 of file pyride_interpreter.py.
rarm_reached = True |
A boolean global variable indicating if the right arm joints have reached their target.
Set as True by default, this variable switches to False immidiately after any move arm task function is called for the right arm and is set back to True when the right arm reaches its target
Definition at line 39 of file pyride_interpreter.py.
tuple rt_acceleration = numpy.zeros(3) |
Definition at line 74 of file pyride_interpreter.py.
rt_active = False |
Definition at line 75 of file pyride_interpreter.py.
int rt_cnt = 0 |
Counter for the raw trajectory function calls.
This counter starts increasing as soon as the raw trajectory input is activated by function activate_raw_trajectory_input()
Definition at line 63 of file pyride_interpreter.py.
rt_orientation = None |
Definition at line 71 of file pyride_interpreter.py.
tuple rt_position = numpy.zeros(3) |
Definition at line 72 of file pyride_interpreter.py.
tuple rt_velocity = numpy.zeros(3) |
Definition at line 73 of file pyride_interpreter.py.
tl_active = False |
Definition at line 69 of file pyride_interpreter.py.
int tl_cnt = 0 |
Definition at line 67 of file pyride_interpreter.py.
tl_dist = None |
Definition at line 68 of file pyride_interpreter.py.