... | ... | @@ -39,9 +39,17 @@ We have to work the array where the trajectory was saved as numpy array `traj_ar |
|
|
To save the trajectories we recorded we make use of the module numpy `np.savetxt('name_document', array, fmt='f')`
|
|
|
.
|
|
|
and recall the file using `np.loadtxt('name_document', dtype=float)`.
|
|
|
|
|
|
|
|
|
|
|
|
Use his arm has indication
|
|
|
==========================
|
|
|
|
|
|
For reachy to understand the relative position of its arm, we set a Cartesian plane with origin in its chest. The command forard_kinematics takes an important role in this process, because it turns the position of the joints into a set of coordinates, then, with help of NumPy arrays, the coordinates XYZ can be obtained.
|
|
|
|
|
|
Once we have the coordinates of the arm, we can fix some boundaries to trigger certain action according to the arm positioning.
|
|
|
|
|
|
Then, it's just a comparison loop that samples the position and take the decision.
|
|
|
|
|
|
|
|
|
|
|
|
Robot 2019
|
... | ... | |