Time Override

The global time override of a robot arm is a scaling factor used to adjust the overall speed of the robot’s movements. It ranges from a factor of 0.01 to 1.0 (or from 1 % to 100 %), while a factor of 1.0 indicates the robot operates at its maximum speed, whereas lower values slow down the robot arm’s movements proportionally. The time override should be used to scale the velocity of a whole application for example to minimize hazards during testing.

Note

If possible, refrain from using the time override for scaling the velocity during operation. Instead, use the speed option of the motion instructions.

Reading the Current Time Override

Reading the current time override can be done using either the method get_time_override_factor() or get_time_override_percent(). The first method returns a custom Factor type that ranges from 0.01 to 1.0, the latter option a custom Percent type that ranges from 1.0 % to 100 %.

An example using get_time_override_factor() can be seen here:

_logger.info(
    "The current time override factor is %s",
    robot.get_time_override_factor(),
)

Setting the Current Time Override

The time override of the robot can be manipulated via the set_time_override() method. The desired time override can be provided either as Factor or as Percent.

robot.set_time_override(Factor(0.25), timeout_s=2.0)

As soon as this method returns, it is guaranteed that the desired time override is actually set on the robot control. If the time override could not be set for any reason, the method will raise an error. The maximum time to wait for the new time override to be set can also be provided.

Here is a complete example of how to set a new time override:

If you run this script, the time override will be set to 100 % but if the environment variable TEST_MODE is set to True, the time override will be decreased to 25 %.

Setting the Time Override with a Transition Time

The time override of a robot from the Victor behavior group can also be set dynamically over a defined transition time using the set_time_override_v() method. The desired time override can be provided either as Factor or as Percent. The transition time has to be provided in seconds.

robot.set_time_override_v(
    time_override_value=Factor(0.25), transition_time_s=5
)

If this method is called during a robot standstill, the time override is set immediately. If this method is called during a robot motion, the time override has a soft transition and reaches its value after the set transition time. If the robot motion stops before the transition time has ended, the time override transition continues until the target value is reached. A short transition time can lead to high accelerations and torques.

move_instruction = robot.move_ptp(VERTICAL)
_wait_for_robot_to_move(robot)
robot.set_time_override_v(
    time_override_value=Factor(0.25), transition_time_s=5
)
while not move_instruction.is_done():
    _logger.info(
        "The current time override factor is %0.2f",
        robot.get_time_override_factor(),
    )
    time.sleep(1)
[INFO ]  The current time override factor is 0.10
[INFO ]  The current time override factor is 0.11
[INFO ]  The current time override factor is 0.14
[INFO ]  The current time override factor is 0.20
[INFO ]  The current time override factor is 0.23
[INFO ]  The current time override factor is 0.25

This method does return as soon as the time override value starts to change and does not block until the desired value is reached. It will not raise an error if the desired value is never reached. Another call of this method while a transition is active, will overwrite the previous command.

Here is a complete example of how to set a time override with transition time:

Definition of the Time Override Methods

The time override methods are defined in the TimeOverrideTrait:

The time override methods for robots with Victor behavior are defined in the TimeOverrideVictorTrait: