Interpolate a position using script
This how to describes the use and functionality of the interpolate pose function, used for calculating a point between two waypoints.
Examples are valid for:
CB3 Software version: 3.1.17779
e-Series Software version: All versions
Note that older or newer software versions may behave differently
The interpolate pose function is a script, that returns a position between two waypoints.
It may be used for following a linear trajectory between two points or for (line) palletizing.
The function takes three arguments:
variable_pose = interpolate_pose(<Waypoint_A>,<Waypoint_B>,<alpha>)
If alpha is 0, the result is Waypoint_A, if alpha is 1 the result is Waypoint_B.
If alpha is 0.5, the function will return the point directly in the middle between the two waypoints.
The function can also be used to extrapolate positions, if alpha e.g. is equal to -1.0 or 1.5.
The program illustrated below, will go in 11 steps from WP_A to WP_B, starting at WP_A, where alpha is 1/10.0, and ending in WP_B where alpha is 10//10.0. The robot will wait for 0.1 second, at each position.
The contents of the “If False” statement will never be run.
If the robot were to follow a linear trajectory, the number of loops could be increased and the waypoint “interpoint” should be made with a blend radius. However it should be noted that the blend radius cannot be larger, than the distance between each of the points.