RobotStudio event

Set a correct configuration

Hi to all,

I did a script which reads a file and gets the coordinates of different points where the robot should move. It runs ok but when I was debugging I noticed that if two consecutive points are extremely far away, robot configuration cannot select a good one configuration. Despite I turn off manual conf to auto, looks like robotstudio cannot get a possible configuration.

I checked an old post where someone wrote an example that consists on for cycles to checked every conf possibility and compare the angles, but it was not really clear. My doubt is what could be an algorithm to obtain the best configuration.

Thanks in advance,
Manuel.