Skip to content

Get Step Time

SUMMARY

Get Step Time returns the duration of a single robot controller time step in seconds (typically 0.002 s for a 500 Hz controller).

Use this value to convert between control-step counts and wall-clock durations.

SUPPORTED ROBOTS

This skill is currently supported on Universal Robots only. Calling this method on other robot brands will raise a NotImplementedError.

The Skill

python
step_time = robot.get_step_time()

The Code

Example: Read and Log Controller Step Time

Connect to the robot and read the controller's step time.

python
from loguru import logger
from telekinesis.synapse.robots.manipulators import universal_robots

robot_ip = "192.168.1.2"  # replace with your robot's IP

robot = universal_robots.UniversalRobotsUR10E()
# Connect
robot.connect(ip=robot_ip)

step_time = robot.get_step_time()
logger.success(f"Controller step time: {step_time} s")

# Disconnect
robot.disconnect()

The Explanation of the Code

get_step_time reads the step_time field from the RTDE data stream. On Universal Robots UR3/UR5/UR10 series, the typical value is 0.002 s (500 Hz control loop). Use this to calculate timing windows for history-based operations or synchronize sampling intervals.

How to Tune the Parameters

This skill takes no input parameters.

Return Value

FieldTypeDescription
step_timefloatControl step duration in seconds.

Where to Use the Skill

  • Compute the number of history steps corresponding to a desired time window.
  • Set polling intervals for state-sampling loops.

When Not to Use the Skill

Use a different skill when:

  • You need elapsed controller time rather than step duration — use Get Timestamp instead.