Moving backwards with Okapi motion profiling?

Okapi 4.0 patch notes says AsyncMotionProfileController can follow paths backwards without mirroring them. How would you make it follow backwards paths? We tried plugging in negative numbers into the 2nd point in the method, but we got runtime errors.

have you look at the docs here:
https://okapilib.github.io/OkapiLib/classokapi_1_1OdomChassisController.html#abea9bd3860ad9f1acb1cdc1e36869fbf
and here
https://okapilib.github.io/OkapiLib/md_docs_tutorials_walkthrough_odometry.html

notice ibackward

void okapi::OdomChassisController::driveToPoint(const Point& ipoint, bool ibackwards = false, const QLength& ioffset = 0_mm) pure virtual

1 Like

That’s the odometry, not the 2d motion profiling.

nevermind i found this https://okapilib.github.io/OkapiLib/classokapi_1_1AsyncMotionProfileController.html#a2846d2e36b86b39aa2e761e4e34cd225

1 Like

There is a mention of this in the tutorial as well: https://okapilib.github.io/OkapiLib/md_docs_tutorials_concepts_twodmotionprofiling.html

2 Likes