robokudo.io.tf_listener_proxy

Transform listener proxy for RoboKudo.

This module provides a singleton proxy for ROS transform listeners. It ensures that only one transform listener instance is created per node, which is important because:

  • The tf_static topic is latched and requires a single listener

  • Multiple listeners in one node can cause buffer synchronization issues

  • Transform lookups are more efficient with a shared listener

The module maintains a single global instance that can be accessed by all components needing transform information.

Attributes

Functions

instance(node)

A singleton-like TransformListener instance.

Module Contents

robokudo.io.tf_listener_proxy.this
robokudo.io.tf_listener_proxy.instance(node)

A singleton-like TransformListener instance.

In ROS 2, a single TransformListener is recommended per node to ensure proper handling of the tf_static topic. Use this instance to access the tf_buffer.

Parameters:

node (rclpy.node.Node) – The ROS 2 node that will own the TransformListener.

Returns:

The tf_buffer associated with the TransformListener.

Return type:

tf2_ros.Buffer