One way is to wait until the vehicle reaches the final point, and then rotate the vehicle to get the desired orientation. That is usually what I do in simple cases.
Another way is to wait until the final destination is reached, and then modify the component’s position matrix. This is used often, and you might see examples of that approach in the deprecated agv scripts.
You could also try passing an orientation point immediately after assigning the control points to the vehicle, but not sure if that is implemented in 4.x.
Things to consider when orientation is inconsistent:
Check the control points. If possible, use frames or matrics and then pass their position vectors. If not then make sure the vectors are valid AND add more if needed to influence the vehicle, for example when executing a curvlinear path that requires an interpolation of 0.0
Check the vehicle’s origin. It is the component’s origin, so offset it as needed using the vehicle API. If not working then consider moving the component origin.
To get things started, try adding a few more points at the end of your path and see if that fixes things.
You need to login in order to like this post: click here