Buscar este blog

Mostrando entradas con la etiqueta transformPoint. Mostrar todas las entradas
Mostrando entradas con la etiqueta transformPoint. Mostrar todas las entradas

jueves, 12 de agosto de 2010

Comments on sscrovers_tf_conf

Based on the tf robot setup tutorials I am commenting the codes of the broadcaster and listener of this package in order to find out a solution to the recently presented problem.

tf_broadcaster.cpp

The only comment I have is related to the timestamp of ros::Time::now(). Perhaps this is the reason why tf is ignoring the desired transform

tf_listener.cpp

  • When creating the point for the base_scan frame (the one in the laser) it is used the following message type:

             geometry_msgs::PointStamped                             


The stamped at the end of the message name means that it includes headers:
1. The frame_id header is assigned to the frame (base_scan) itself: laser_point.header.frame_id = "base_scan"; 2. The timestamp header is assigned to ros::Time which asks for the latest available transform. I think this might be a key concept for debugging the program: laser_point.header.stamp = ros::Time();
  • The next step is to declare an object (base_point) that is going to store the same information that the 
  • laser_point (on the base_scan frame) owns but now in the base_link frame.
             try{geometry_msgs::PointStamped base_point;                

listener.transformPoint("base_link", laser_point, base_point);