robotology / unicycle-footstep-planner

Repository for the Unicycle-based FootStep Planner.
BSD 3-Clause "New" or "Revised" License
20 stars 11 forks source link

Implement a DCM trajectory generator #2

Closed GiulioRomualdi closed 6 years ago

GiulioRomualdi commented 6 years ago

In order to implement a DCM based controller a trajectory generator for the Divergent Component Of Motion is needed.

GiulioRomualdi commented 6 years ago

The code of the first version of the DCM trajectory generator can be found here. (if you want I can create a new branch in this repository and open a pull request)

Results

The results are collected using the interpolationTest. In the figure below the DCM trajectory (both x and y coordinates) is shown. The trajectory generator takes into account both Single and Double Support using an heuristic technique. dcm_coordinate

TODO

GiulioRomualdi commented 6 years ago

With the new release two DCM trajectories can be are merged in the middle of the Double Support phase (mergePoint).
It is important to notice that the new trajectory is evaluated imposing, at the mergePoint, the same velocity and position of the old trajectory.
More formally codecogseqn 4 where codecogseqn 8 is the time at the merge point and codecogseqn 6 is the DCM position.
It is important to underline that the mergePoint approach allows the real-time evaluation of the trajectory (for example using a joystick).
In the following some result plots (obtained using the new DcmInterpolationTest) are shown. In the first one the old (blue) and the new merged (orange) DCM trajectories are shown while in the other figures the x and y coordinate of the DCM trajectories are shown dcm_traj

GiulioRomualdi commented 6 years ago

Here you can find further information about the theory behind the DCM trajectory generator.

dosh1234 commented 6 years ago

@GiulioRomualdi A simple question.How can I run DcmInterpolationTest? My steps are as follows: cd /unicycle-footstep-planner/build/tests/ ./DcmInterpolationTest But it reminds me that I have no footprint name.

[DCM TRAJECTORY GENERATOR] The name of the footprint is neither left nor right. Does iCub have more legs?!
[DCM TRAJECTORY GENERATOR] Unable to get the ZMP Delta.
[FEETINTERPOLATOR] Failed while computing the DCM trajectories.
:-1 : assertTrue failure

so I try
./DcmInterpolationTest left It doesn't work either.