Skip to content

Get Controller Frequency

SUMMARY

Get Controller Frequency measures and returns the controller update rate in Hz by sampling the RTDE timestamp field over a short window. On Universal Robots UR3/UR5/UR10 series the typical value is 500 Hz.

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
frequency = robot.get_controller_frequency()

The Code

Example: Measure and Log Controller Frequency

Read the controller update frequency and log the result.

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)

frequency = robot.get_controller_frequency()
logger.success(f"Controller frequency: {frequency:.1f} Hz")

# Disconnect
robot.disconnect()

The Explanation of the Code

get_controller_frequency measures the controller update rate by sampling successive RTDE timestamps over a short window (approximately 0.2 seconds) and computing the average inter-sample rate. The result is in Hz. Use this value to set sampling intervals, validate that the controller is running at its rated frequency, or compute the number of control steps per unit time.

How to Tune the Parameters

This skill takes no input parameters.

Return Value

Return TypeDescription
floatController update frequency in Hz.

Where to Use the Skill

  • Validate controller health before starting a time-critical task.
  • Compute sampling intervals for state-logging loops.
  • Confirm the controller is not operating in a degraded or reduced-rate mode.

When Not to Use the Skill

Use a direct RTDE step period instead:

  • Use Get Step Time to retrieve the pre-configured step period directly from the RTDE stream without measurement.