Hello,
Iam trying to build a simple SLAM system consisted of:
- RPLiDAR A2 M8
- Razor IMU 9DOF M0
**used packages:**
- octomap_mapping,
- razor_imu_9dof (razor-pub.launch)
- rplidar_ros (rplidar.launch)
**own packages**
- mctr-132_ros (sends transform of
world 0,0,0 and transform of laser
which has location 0,0,0 and
orientation is quaternion from imu)
- mctr-132_laser (only converting
LaserScan to PointCloud)
**System: Ubuntu 16.04, ROS Kinetic**
Iam in the phase that I put those points into map and I can visualize it in Rviz, but I only take IMU rotation into account. The position is being published into the /tf topic as 0, 0, 0. I can therefore build map of the surrounding environment. But I'd like to move my device around. So I need a proper /tf with position transform.
I was thinking about robot_pose_ekf, but it needs odometry and I have no idea how to create fake odometry from 9dof imu.
**Q1: Is it possible to create fake odometry from IMU and if so how?**
Many thanks
ps.: I would upload also a photo but 5 points are required...
ps.: I tried google cartographer, hector_localization, rf2o_laser_odometry but I failed to build/run them...
↧
Creating /tf (position) from IMU, 2D/3D SLAM (LiDAR+IMU+Octomap) (no need for high accuracy))
↧
"Waiting for the map" when using map_server and rosbag
Hello, I'm currently doing the tutorial [teb_local_planner](http://wiki.ros.org/teb_local_planner/Tutorials) and now I'm trying to build a map with this [tutorial](http://wiki.ros.org/slam_gmapping/Tutorials/MappingFromLoggedData). I execute all commands and at the end of this, I have problem with this command :
~/Documents/pts-info2-master/mybot_ws-base_sensors/src$ rosrun map_server map_saver -f my_map
[ INFO] [1553269724.865617557]: Waiting for the map
I never get the map and I must kill the process.
I use Velodyne, Ubuntu 16.04 with ROS Kinetic distribution.
Thanks.
↧
↧
How to load a urdf xml robot description on the Parameter Server?
I'm learning how to use robot_state_publisher using the tutorial on http://wiki.ros.org/robot_state_publisher/Tutorials/Using%20the%20robot%20state%20publisher%20on%20your%20own%20robot.
I need to output tf and tf_static from the robot_state_publisher to run SLAM. My project is somewhat similar to Chefbot, and I'm using amcl_demo launch file, along with my files which outputs odometry and tf, and runs the robot's wheels.
To be frank, I don't even konw whether doing so through is robot_state_publisher is necessary, because my bot looks similar to turtlebot and it doesn't have any moving links. Hence the tf should be same throughout. But for camera nodes to work, I require to publish tf and tf_static.
I don't know how to make a urdf xml file and how to load it on the param server. And is there a way to edit turtlebot's urdf xml to match my bot's dimensions and design?
↧
Problem with tf tutorial
I followed the tutorial http://wiki.ros.org/tf/Tutorials/Writing%20a%20tf%20broadcaster%20%28C%2B%2B%29
I encountered this error while doing catkin_make
CMakeFiles/turtle_tf_broadcaster.dir/src/turtle_tf_broadcaster.cpp.o: In function `poseCallback(boost::shared_ptr> const> const&)':
turtle_tf_broadcaster.cpp:(.text+0x57): undefined reference to `tf::TransformBroadcaster::TransformBroadcaster()'
turtle_tf_broadcaster.cpp:(.text+0x211): undefined reference to `tf::TransformBroadcaster::sendTransform(tf::StampedTransform const&)'
collect2: error: ld returned 1 exit status
learning_tf/CMakeFiles/turtle_tf_broadcaster.dir/build.make:113: recipe for target '/home/calvin/catkin_ws/devel/lib/learning_tf/turtle_tf_broadcaster' failed
make[2]: *** [/home/calvin/catkin_ws/devel/lib/learning_tf/turtle_tf_broadcaster] Error 1
CMakeFiles/Makefile2:1482: recipe for target 'learning_tf/CMakeFiles/turtle_tf_broadcaster.dir/all' failed
make[1]: *** [learning_tf/CMakeFiles/turtle_tf_broadcaster.dir/all] Error 2
Makefile:140: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make -j4 -l4" failed
I don't think I have problem with the CMakeLists but to just make sure
I put
find_package(catkin REQUIRED COMPONENTS
roscpp
rospy
tf
turtlesim
)
and
add_executable(turtle_tf_broadcaster src/turtle_tf_broadcaster.cpp)
target_link_libraries(turtle_tf_broadcaster ${catkin_LIBRARIES})
and my package.xml looks has this inside
catkin roscpp rospy tf turtlesim roscpp rospy tf turtlesim roscpp rospy tf turtlesim
Please tell me what is the error with this?
↧
Why cartographer's odom from TF contains much noise
I want to fuse cartographer's odom and imu, gps using robot_localization package(using ekf). I implemented tf listener, because I tried to get cartographer's odom from tf, but it contains much noise.
Our cartographer config files does work, we can get good result in rviz and final result of cartographer_odom is almost correct.
I used KITTI dataset(transformed rosbag file)
data link: https://www.dropbox.com/s/ub9zx2pna02z2u6/kitti_2011_09_26_drive_0117_synced.bag?dl=0 (it contain noisy cartographer_odom)
cartographer's publish rate and listener's publish rate are 200 hz.
Why does it contain much noise?
#include
#include
#include
#include
#include
#include
#include
int main(int argc, char** argv)
{
ros::init(argc, argv, "odom_listener");
ros::NodeHandle n;
tf2_ros::Buffer tfBuffer;
tf2_ros::TransformListener odomListener(tfBuffer);
ros::Publisher odom_pub = n.advertise("cartographer_odom",1000);
ros::Rate r(5);
while(ros::ok()){
geometry_msgs::TransformStamped transform;
try{
transform = tfBuffer.lookupTransform("map", "base_link", ros::Time(0));
}
catch (tf2::TransformException &ex){
ROS_ERROR("%s", ex.what());
ros::Duration(1.0).sleep();
continue;
}
tf2::Vector3 translation;
translation.setValue(transform.transform.translation.x,
transform.transform.translation.y,
transform.transform.translation.z);
tf2::Quaternion rotation;
rotation.setValue(transform.transform.rotation.x,
transform.transform.rotation.y,
transform.transform.rotation.z,
transform.transform.rotation.w);
tf2::Matrix3x3 m(rotation);
double roll, pitch, yaw;
m.getRPY(roll, pitch, yaw);
ROS_INFO("\n=== Got Transform ===\n"
" Translation\n"
" x : %f\n y : %f\n z : %f\n"
" Quaternion\n"
" x : %f\n y : %f\n z : %f\n w : %f\n"
" RPY\n"
" R : %f\n P : %f\n Y : %f",
translation.x(), translation.y(), translation.z(),
rotation.x(), rotation.y(), rotation.z(), rotation.w(),
roll, pitch, yaw);
nav_msgs::Odometry odom;
odom.header.stamp = ros::Time::now();
odom.header.frame_id = "odom";
odom.pose.pose.position.x = translation.x();
odom.pose.pose.position.y = translation.y();
odom.pose.pose.position.z = translation.z();
odom.pose.pose.orientation.x = rotation.x();
odom.pose.pose.orientation.y = rotation.y();
odom.pose.pose.orientation.z = rotation.z();
odom.pose.pose.orientation.w = rotation.w();
odom.child_frame_id = "base_link";
odom.twist.twist.linear.x = 0;
odom.twist.twist.linear.y = 0;
odom.twist.twist.linear.z = 0;
odom_pub.publish(odom);
r.sleep();
}
return 0;
}
↧
↧
AMCL TF Issues
I am currently running ros kinetic on ubiquity robotics ubuntu on a raspberry pi B+. I am wanting to localize myself using a X4 ydlidar, a pre-made map using map_server, and amcl. I also have an IMU but I havent tried integrating that yet because I cannot seem to get the lidar working as it is. For amcl to localize, what transforms need to happen to what?
If I launch the lidar script and the map and amcl the output is the following
base_footprint -> laser_frame which is broadcasted by /lidarTransform.
If I rostopic echo /scan data floods the screen as expected, however amcl states that there is no laser scan received. Also, amcl does not transform the map that it loaded in to the odom frame.
If I add a transform from base_footprint to /odom the /scan message goes away and amcl does the transform from map to odom. however the tree goes map ->odom->base_footprint-> laser_frame and the laser_frame cannot be projected on the map fixed frame in rviz because of a loop. If I then kill the odom to base_footprint it can then work. Moving the 2D pose estimate then shifts the entire scan about the point I make it face. Moving the robot also moves the scan data around, so I guess I need something that links laser data to the map
So I just need some guidance on what transforms need to happen so that amcl can be happy and output a pose. Any help will be appreciated.
↧
tf2 patterns for high update rates
I'm looking for a good pattern for using `tf2` to provide two things:
1. A set of static transforms for the robot that define things like the wheel positions and sensor locations. These are fixed but they need to be used in a variety of nodes. The transforms come from URDF mainly but there may be some calculated from parameter input when a node starts or from a launch file.
1. A high-update-rate transform from the world frame to the robot's frame, produced and used only in a small number of nodes.
The problem we have is that we want to be able to get the static transforms in a lot of nodes, but we don't want the overhead of distributing the high rate transform to every node, just the small number that need it. I hope someone has a nice solution within `tf2` for this, but I'm happy to hear any other suggestions.
↧
unable to build geometry package in ROS kinetic
Im trying to install geometry package but im getting this error:
[ 93%] Built target check_for_chessboard
Scanning dependencies of target marker_broadcaster
[ 93%] Building CXX object ardrone_autonomy/CMakeFiles/ardrone_driver.dir/src/video.cpp.o
[ 93%] Building CXX object external_camera_tf/CMakeFiles/calib_gui.dir/src/calib_gui.cpp.o
[ 93%] Building CXX object external_camera_tf/CMakeFiles/marker_broadcaster.dir/src/marker_broadcaster.cpp.o
In file included from /home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/Soft/Lib/ardrone_tool/Video/video_stage_ffmpeg_decoder.h:14:0,
from /home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/Soft/Lib/ardrone_tool/Video/video_stage_decoder.h:27,
from /home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/Soft/Lib/ardrone_tool/Video/video_stage.h:27,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/ardrone_sdk.h:63,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/video.h:28,
from /home/pramod/catkin_ws/src/ardrone_autonomy/src/video.cpp:25:
/home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/FFMPEG/Includes/libavcodec/avcodec.h:525:27: warning: attribute ignored in declaration of ‘enum AVLPCType’ [-Wattributes]
attribute_deprecated enum AVLPCType {
^
/home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/FFMPEG/Includes/libavcodec/avcodec.h:525:27: note: attribute for ‘enum AVLPCType’ must follow the ‘enum’ keyword
[ 93%] Linking CXX executable /home/pramod/catkin_ws/devel/lib/external_camera_tf/calib_gui
In file included from /home/pramod/catkin_ws/src/geometry/tf/include/tf/transform_broadcaster.h:36:0,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/ardrone_driver.h:33,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/ardrone_sdk.h:70,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/video.h:28,
from /home/pramod/catkin_ws/src/ardrone_autonomy/src/video.cpp:25:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:354:8: error: ‘shared_ptr’ in namespace ‘std’ does not name a template type
std::shared_ptr getTF2BufferPtr() { return tf2_buffer_ptr_;};
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:403:8: error: ‘shared_ptr’ in namespace ‘std’ does not name a template type
std::shared_ptr tf2_buffer_ptr_;
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h: In member function ‘ros::Duration tf::Transformer::getCacheLength()’:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:331:43: error: ‘tf2_buffer_ptr_’ was not declared in this scope
ros::Duration getCacheLength() { return tf2_buffer_ptr_->getCacheLength();}
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h: In member function ‘void tf::Transformer::setUsingDedicatedThread(bool)’:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:349:46: error: ‘tf2_buffer_ptr_’ was not declared in this scope
void setUsingDedicatedThread(bool value) { tf2_buffer_ptr_->setUsingDedicatedThread(value);};
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h: In member function ‘bool tf::Transformer::isUsingDedicatedThread()’:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:351:42: error: ‘tf2_buffer_ptr_’ was not declared in this scope
bool isUsingDedicatedThread() { return tf2_buffer_ptr_->isUsingDedicatedThread();};
^
In file included from /home/pramod/catkin_ws/src/geometry/tf/include/tf/transform_broadcaster.h:36:0,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/ardrone_driver.h:33,
from /home/pramod/catkin_ws/src/ardrone_autonomy/src/ardrone_driver.cpp:30:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:354:8: error: ‘shared_ptr’ in namespace ‘std’ does not name a template type
std::shared_ptr getTF2BufferPtr() { return tf2_buffer_ptr_;};
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:403:8: error: ‘shared_ptr’ in namespace ‘std’ does not name a template type
std::shared_ptr tf2_buffer_ptr_;
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h: In member function ‘ros::Duration tf::Transformer::getCacheLength()’:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:331:43: error: ‘tf2_buffer_ptr_’ was not declared in this scope
ros::Duration getCacheLength() { return tf2_buffer_ptr_->getCacheLength();}
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h: In member function ‘void tf::Transformer::setUsingDedicatedThread(bool)’:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:349:46: error: ‘tf2_buffer_ptr_’ was not declared in this scope
void setUsingDedicatedThread(bool value) { tf2_buffer_ptr_->setUsingDedicatedThread(value);};
^
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h: In member function ‘bool tf::Transformer::isUsingDedicatedThread()’:
/home/pramod/catkin_ws/src/geometry/tf/include/tf/tf.h:351:42: error: ‘tf2_buffer_ptr_’ was not declared in this scope
bool isUsingDedicatedThread() { return tf2_buffer_ptr_->isUsingDedicatedThread();};
^
ardrone_autonomy/CMakeFiles/ardrone_driver.dir/build.make:86: recipe for target 'ardrone_autonomy/CMakeFiles/ardrone_driver.dir/src/video.cpp.o' failed
make[2]: *** [ardrone_autonomy/CMakeFiles/ardrone_driver.dir/src/video.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/Soft/Lib/ardrone_tool/Video/video_stage_ffmpeg_decoder.h:14:0,
from /home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/Soft/Lib/ardrone_tool/Video/video_stage_decoder.h:27,
from /home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/Soft/Lib/ardrone_tool/Video/video_stage.h:27,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/ardrone_sdk.h:63,
from /home/pramod/catkin_ws/src/ardrone_autonomy/include/ardrone_autonomy/ardrone_driver.h:41,
from /home/pramod/catkin_ws/src/ardrone_autonomy/src/ardrone_driver.cpp:30:
/home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/FFMPEG/Includes/libavcodec/avcodec.h: At global scope:
/home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/FFMPEG/Includes/libavcodec/avcodec.h:525:27: warning: attribute ignored in declaration of ‘enum AVLPCType’ [-Wattributes]
attribute_deprecated enum AVLPCType {
^
/home/pramod/catkin_ws/devel/src/ardronelib/ARDroneLib/FFMPEG/Includes/libavcodec/avcodec.h:525:27: note: attribute for ‘enum AVLPCType’ must follow the ‘enum’ keyword
Scanning dependencies of target external_camera_tf_broadcaster
[ 93%] Building CXX object external_camera_tf/CMakeFiles/external_camera_tf_broadcaster.dir/src/external_camera_tf_broadcaster.cpp.o
[ 93%] Linking CXX executable /home/pramod/catkin_ws/devel/lib/external_camera_tf/marker_broadcaster
[ 93%] Built target calib_gui
Scanning dependencies of target test_trajectory
ardrone_autonomy/CMakeFiles/ardrone_driver.dir/build.make:62: recipe for target 'ardrone_autonomy/CMakeFiles/ardrone_driver.dir/src/ardrone_driver.cpp.o' failed
make[2]: *** [ardrone_autonomy/CMakeFiles/ardrone_driver.dir/src/ardrone_driver.cpp.o] Error 1
CMakeFiles/Makefile2:19256: recipe for target 'ardrone_autonomy/CMakeFiles/ardrone_driver.dir/all' failed
make[1]: *** [ardrone_autonomy/CMakeFiles/ardrone_driver.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 93%] Building CXX object tum_simulator/cvg_sim_gazebo_plugins/CMakeFiles/test_trajectory.dir/src/test_trajectory.cpp.o
[ 93%] Built target marker_broadcaster
[ 93%] Linking CXX executable /home/pramod/catkin_ws/devel/lib/external_camera_tf/external_camera_tf_broadcaster
[ 93%] Built target external_camera_tf_broadcaster
[ 93%] Linking CXX executable /home/pramod/catkin_ws/devel/lib/cvg_sim_gazebo_plugins/test_trajectory
[ 93%] Built target test_trajectory
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make -j4 -l4" failed
↧
The model placed on gazebo is not moving with my control topics.
Hello.
I am following the guide descripted on [link](https://github.com/RobotnikAutomation/summit_xl_sim).
I clone three repository on my catkin_ws directroy.
I did two step to run 'summit_xl_sim' like this.
```bash
$ cd PATH
$ rosdep install --from-paths src --ignore-src -r -y
$ roslaunch summit_xl_sim_bringup summit_xl_complete.launch
```
And I could see the model on Rviz and Gazebo.
Here is the log and screenshots.
```bash
$ roslaunch summit_xl_sim_bringup summit_xl_complete.launch
... logging to /home/msi-h310/.ros/log/859bd69e-6046-11e9-9ef6-309c23b89cf6/roslaunch-msih310-H310-Gaming-Trident3-MS-B920-18298.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://msih310-H310-Gaming-Trident3-MS-B920:34371/
SUMMARY
========
PARAMETERS
* /rosdistro: kinetic
* /rosversion: 1.12.14
* /summit_xl_a/joint_pan_position_controller/joint: summit_xl_a_front...
* /summit_xl_a/joint_pan_position_controller/pid/d: 10.0
* /summit_xl_a/joint_pan_position_controller/pid/i: 0.01
* /summit_xl_a/joint_pan_position_controller/pid/p: 100.0
* /summit_xl_a/joint_pan_position_controller/type: velocity_controll...
* /summit_xl_a/joint_read_state_controller/publish_rate: 100.0
* /summit_xl_a/joint_read_state_controller/type: joint_state_contr...
* /summit_xl_a/joint_tilt_position_controller/joint: summit_xl_a_front...
* /summit_xl_a/joint_tilt_position_controller/pid/d: 10.0
* /summit_xl_a/joint_tilt_position_controller/pid/i: 0.01
* /summit_xl_a/joint_tilt_position_controller/pid/p: 100.0
* /summit_xl_a/joint_tilt_position_controller/type: velocity_controll...
* /summit_xl_a/robot_description: , set to "/summit_xl_a"
[libprotobuf ERROR google/protobuf/message_lite.cc:123] Can't parse message of type "gazebo.msgs.Packet" because it is missing required fields: stamp, type, serialized_data
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
[ INFO] [1555419165.592017736, 0.064000000]: Camera Plugin: Using the 'robotNamespace' param: '/summit_xl_a/'
Master Unknown message type[] From[34818]
[libprotobuf ERROR google/protobuf/message_lite.cc:123] Can't parse message of type "gazebo.msgs.Packet" because it is missing required fields: stamp, type, serialized_data
Master Unknown message type[] From[34818]
[libprotobuf ERROR google/protobuf/message_lite.cc:123] Can't parse message of type "gazebo.msgs.Packet" because it is missing required fields: stamp, type, serialized_data
Master Unknown message type[] From[34818]
[ INFO] [1555419165.595342079, 0.064000000]: Camera Plugin (ns = /summit_xl_a/) , set to "/summit_xl_a"
[INFO] [1555419165.597384, 0.064000]: Spawn status: SpawnModel: Successfully spawned entity
[ INFO] [1555419165.598077336, 0.064000000]: Camera Plugin: Using the 'robotNamespace' param: '/summit_xl_a/'
[ INFO] [1555419165.602217472, 0.064000000]: Camera Plugin (ns = /summit_xl_a/) , set to "/summit_xl_a"
[libprotobuf ERROR google/protobuf/message_lite.cc:123] Can't parse message of type "gazebo.msgs.Packet" because it is missing required fields: stamp, type, serialized_data
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
Master Unknown message type[] From[34818]
[libprotobuf ERROR google/protobuf/message_lite.cc:123] Can't parse message of type "gazebo.msgs.Packet" because it is missing required fields: stamp, type, serialized_data
Master Unknown message type[] From[34818]
[ INFO] [1555419165.610421232, 0.064000000]: Physics dynamic reconfigure ready.
[libprotobuf ERROR google/protobuf/message_lite.cc:123] Can't parse message of type "gazebo.msgs.Packet" because it is missing required fields: stamp, type, serialized_data
Master Unknown message type[] From[34818]
[ INFO] [1555419165.742501315, 0.086000000]: waitForService: Service [/gazebo/set_physics_properties] is now available.
[ INFO] [1555419165.764930564, 0.105000000]: Physics dynamic reconfigure ready.
[summit_xl_a/urdf_spawner_summit_model-3] process has finished cleanly
log file: /home/msi-h310/.ros/log/859bd69e-6046-11e9-9ef6-309c23b89cf6/summit_xl_a-urdf_spawner_summit_model-3*.log
[WARN] [1555419193.114739, 25.727000]: Controller Spawner couldn't find the expected controller_manager ROS interface.
[summit_xl_a/controller_spawner-4] process has finished cleanly
log file: /home/msi-h310/.ros/log/859bd69e-6046-11e9-9ef6-309c23b89cf6/summit_xl_a-controller_spawner-4*.log
```


After this steps, I pub topics on other terminal.
But there is no any changes.
```bash
$ rostopic pub /summit_xl_a/robotnik_base_control/cmd_vel geometry_msgs/Twist "linear:
x: 0.0
y: 0.0
z: 0.0
angular:
x: 0.0
y: 50.0
z: 0.0"
```
1. What is the meaning of the error on Rviz?
2. Did I miss something to do it?
↧
↧
Understanding registerCallback() from TF MessageFilter tutorial
I'm going through the TF [MessageFilter tutorial](http://wiki.ros.org/tf/Tutorials/Using%20Stamped%20datatypes%20with%20tf%3A%3AMessageFilter) and I understand the code except for line 13:
tf_filter_->registerCallback( boost::bind(&PoseDrawer::msgCallback, this, _1) );
I'm more of a novice when it comes to using the `boost` libraries, but after reading some documentation, it seems that this line is creating a function object that equates to something of this form: `msgCallback(this, _1)` where `this` is the PoseDrawer object and `_1` is a placeholder that will be substituted with the first argument provided to the function object (which I'm assuming is done by the TF library under the hood).
What I'm confused about is how you know to provide the `this` object and that the callback function needs an `_1` placeholder. Is the `_1` simply because the callback function (shown below) only takes one argument? If my callback function had no parameters, would I just remove the `_1` argument when calling the function? Why is the `this` object necessary?
void msgCallback(const boost::shared_ptr& point_ptr)
↧
Rviz tf 'world' does not exist
Hello everyone,
Basic info:
env | grep ROS:
ROS_ROOT=/opt/ros/kinetic/share/ros
ROS_PACKAGE_PATH=/home/mifa/ws_moveit/src/moveit_tutorials:/home/mifa/ws_moveit/src/panda_custom_moveit_config:/home/mifa/ws_moveit/src/panda_moveit_config:/home/mifa/ws_moveit/src/universal_robot/universal_robot:/home/mifa/ws_moveit/src/universal_robot/universal_robots:/home/mifa/ws_moveit/src/universal_robot/ur_bringup:/home/mifa/ws_moveit/src/universal_robot/ur_description:/home/mifa/ws_moveit/src/universal_robot/ur10_e_moveit_config:/home/mifa/ws_moveit/src/universal_robot/ur10_moveit_config:/home/mifa/ws_moveit/src/universal_robot/ur3_e_moveit_config:/home/mifa/ws_moveit/src/universal_robot/ur3_moveit_config:/home/mifa/ws_moveit/src/universal_robot/ur5_e_moveit_config:/home/mifa/ws_moveit/src/universal_robot/ur5_moveit_config:/home/mifa/ws_moveit/src/universal_robot/ur_driver:/home/mifa/ws_moveit/src/universal_robot/ur_gazebo:/home/mifa/ws_moveit/src/universal_robot/ur_kinematics:/home/mifa/ws_moveit/src/universal_robot/ur_msgs:/home/mifa/ws_moveit/src/ur_modern_driver:/opt/ros/kinetic/share
ROS_MASTER_URI=http://pickit-097:11311/
ROS_VERSION=1
ROSLISP_PACKAGE_DIRECTORIES=/home/mifa/ws_moveit/devel/share/common-lisp
ROS_DISTRO=kinetic
ROS_IP=192.168.203.151
ROS_ETC_DIR=/opt/ros/kinetic/etc/ros
OS: ubuntu 16.04
I've been trying to get a UR10 moving in Rviz using moveit. This worked.
Now i want to add my end effector to the URDF so that this will also be included in the plath planning.
For some reason i am unable to get this to work in Rviz. My problem:
I use the standard files i downloaded from the 'universal_robot' package, but in Rviz is get the following error:
My fixed frame is set to 'world'. The tf world is made in the ur10_robot.urdf.xacro, provided by the ur_description.
Then at global options an error appears saying "Fixed Frame [world] does not exist"
At my RobotModel status is Error, saying:
URDF parsed OK
tranform (world to world) OK
No transform from [base] to [world]
No transform from [base_link] to [world]
No transform from [ee_link] to [world]
No transform from [forearm_link] to [world]
No transform from [tool0] to [world]
and this for all links in the URDF
Am i missing something and is this even the right way to link multiple URDF's to eachother?
Kind regards,
Jan Tromp
↧
Add tf to existing bag file
I have created a ros node that does a tf transformation. I want to merge this new frame to an already existing bag file. I did this with rosbag record -a. (Played the existing bag and my ros node doing the transformation). But now I get the warning: ""detected jump back clearing tf Buffer" when I play the new bag. Is there anything I have to consider when merging a frame?
Done:
-> Set use_sim_time true before recording
-> playbag exisiting bag file with Argument --Clock
↧
`tf static_transform_publisher` removes link instead of linking two tf trees
When using `static_transform_publisher`, attempting to link to coordinate systems via a common frame the publisher removes the link from one tree and places it in the other. This happens both with `tf` and `tf2_ros`, and when execucted from the command line as well as from a launch file.
See the following example where `ar_marker_master` and `ar_marker_0` refer to the same point in world space. Without linking the two using `tf`, the `tf_tree` looks like this:

Then, we can attempt to link the two frames using:
```
rosrun tf static_transform_publisher 0 0 0 0 0 0 /ar_marker_master /ar_marker_0 1000
```
Where the resulting tree looks like this:

This successfully links `ar_marker_master` with `ar_marker_0`, but notice that the link `ar_marker_0` has been removed from the tree with `camera_link`. Shouldn't this join the two trees?
For more context, if I run `rosrun tf tf_echo /camera_color_optical_frame /ar_marker_0` to view the transformation between `camera_color_optical_frame` and `ar_marker_0` before the adding the link, I can see:
```
At time 1556317303.088
- Translation: [-0.380, 0.338, 1.264]
- Rotation: in Quaternion [0.966, 0.072, -0.068, 0.237]
in RPY (radian) [2.669, 0.166, 0.109]
in RPY (degree) [152.939, 9.504, 6.273]
```
But after running `static_transform_publisher`:
```
Exception thrown:Could not find a connection between 'camera_color_optical_frame' and 'ar_marker_0'
```
Where did the link go? And, if this is not the proper way to join two trees, how should I perform the transform to join the two coordinate systems?
↧
↧
Help with setting up navigation stack for two kuka youbots
Hello,
I am currently doing a project with two kuka youbots running ros hydro and ubuntu 12.04. I plan on controlling them with an external computer running a master node. I was able to setup the navigation stack in Gazebo and RVIZ, and it works fine. However, I am having issues when trying to implement the navigation stack on the real platforms.
My issue is when I launch both of the real drivers (i.e. youbot_driver.launch) they both publish the same "odom" topic that is connected to the "base_footprint" frame. Since both youbots have the same topic and frame names, I get "TF_OLD_DATA" warnings for "odom" and "base_footprint". In simulation, I was able to fix this by remapping the topic and frame to include the robots name(i.e youbot1 or youbot2) before each topic and everything worked fine. This was done using "group_ns" and remapping args.
Now, when I tried to use remapping args on the real platforms, the robots name would get published before every topic except for odom and frame "base_footprint". Even when I set the "odom_frame", "odom_topic" and "robot_base_frame" parameters to "robot_name/odom" or "robot_name/base_footprint" in youbot_driver.launch, the tf_tree output still shows only odom and base_footprint without the robot name prefix.
How can remap odom and basefootprint in "youbot_driver.launch" to match what I am seeing in simulation? I feel like I have exhausted the forums on remapping topics and using tf_prefix, so any information would help,
Thanks.
↧
URDF transform to world fails
Hey everyone,
I am working on a project where i connect a robotiq 85 2f gripper to a ur10.
I did this by making an urdf (xacro) file that describes my toplevel system.
In the urdf I include the UR10 and gripper urdf.
Then i link them together as follows:
When i launch the launch file which uploads this urdf to param server and launches rviz it gets weird.
My "robotiq_85_base_link" gets visualized like it should, but the links following: "robotiq_85_left_finger_link" "...left_finger_tip_link" "...right_finger_link" and "...right_finger_tip_link" are not displayed in rviz but instead appear in white at the center of the "world".
If i click my robot model it says:
"No transform from [robotiq_85_left_finger_link] to [world]" for all the links.
How can i fix this?
I noticed that if i make a static_transform_publish node where i connect the link tf's to the parents tf's it would work, but this is not the right way to do it is it?
Some general info:
ubuntu 16.04
ros kinetic
RViz version 1.12.17 (kinetic). Compiled against Qt version 5.5.1. Compiled against OGRE version 1.9.0 (Ghadamon)
[UR10_urdf link](https://github.com/ros-industrial/universal_robot/tree/kinetic-devel/ur_description/urdf)
[gripper_urdf link](https://github.com/crigroup/robotiq/tree/master/robotiq_description/urdf)
Kind regards
Jan Tromp.
↧
Combine two parent-child transformations for common link
I am trying to connect two tf trees via a known link by following the advice from @tfoote [here](https://answers.ros.org/question/322015/tf-static_transform_publisher-removes-link-instead-of-linking-two-tf-trees/?answer=322017#post-id-322017). One link belongs to the robot tf tree and the other belongs to a camera tf tree that is not part of the robot urdf. `ar_tracker_alvar` is providing the known link from the camera to a link defined in the robot urdf. I have looked up the transformations using `tf2_ros`, where `robot_link_1` and `alvar_link_1` share the same point in space:
tf_buffer =tf.Buffer()
known_transform_1 = tf_bufffer.lookup_transform('robot_link_1' , 'base_link', rospy.Time.now(), rospy.Duration(1.0))
known_transform_2 = tf_bufffer.lookup_transform('alvar_link_1' , 'camera_link', rospy.Time.now(), rospy.Duration(1.0))
I have added the position information to get a new combined xyz transformation:
t = TransformStamped()
t1 = known_transform_1.transform.translation
t2 = known_transform_2.transform.translation
t.x = t1.x + t2.x
t.y = t1.x + t2.x
t.z = t1.x + t2.x
The resulting vector appears to be the correct length from the camera to the robot base. Next, my understanding of how to combine the rotation information is as follows:
q_robot = known_transform_1.transform.rotation
q_camera = known_transform_2.transform.rotation
rotation = tf.transformations.quaternion_multiply(q_robot, q_camera)
I am using this information to send to a broadcaster to provide a link between the two trees:
tf_broadcaster = tf.TransformBroadcaster()
t_broadcaster.sendTransform(t)
Combining the quaternions, however, does not work as expected.

As you can see, the rotation is off.
I have tried changing the placement of ar tags as well as other analytical solutions, but I appear to be missing a critical piece of information for how to combine the rotation components.
How do I perform the translation to link the two trees?
You can see in the visualization that the robot and camera appear to be aligned as expected.
For more context, below is the outcome of a tag placed in a different location:


EDIT:
Trying the suggestion by @janindu to directly link `robot_link_1` and `camera_link` results in a similar situation where the tf_tree is completed but the translation is still incorrect at a different pose. See the following:

[https://answers.ros.org/question/322015/tf-static_transform_publisher-removes-link-instead-of-linking-two-tf-trees/](https://answers.ros.org/question/322015/tf-static_transform_publisher-removes-link-instead-of-linking-two-tf-trees/)
↧
Extract tf::Transform from tf::StampedTransform & tf::Stamped
I'm trying to find a cascaded transform but I'm running into the following errors :
tf::TransformListener listener;
tf::StampedTransform transform_cd;
try
{
for(unsigned int i=0; i tag_transform, transform_td, transform_tc;
tf::poseStampedMsgToTF(pose, tag_transform);
listener.lookupTransform("camera", "drone", tag_transform.stamp_, transform_cd);
transform_tc = tag_transform.inverse();
transform_td = transform_tc*transform_cd;
tf::Matrix3x3(transform_td.getRotation()).getRPY(uavRollENU, uavPitchENU, uavYawENU);
if(pose.pose.position.z>0.1 && fabs(uavPitchENU) < 30/57.2958 && fabs(uavRollENU) < 30/57.2958)
{
tf_pub_.sendTransform(tf::StampedTransform(tag_transform,
tag_transform.stamp_,
camera_tf_frame_,
detection_names[i]));
tf::poseStampedTFToMsg(transform_td, pose);
error: no match for ‘operator=’ (operand types are ‘tf::Stamped’ and ‘tf::Transform’)
transform_tc = tag_transform.inverse();
error: no match for ‘operator=’ (operand types are ‘tf::Stamped’ and ‘tf::Transform’)
transform_td = transform_tc*transform_cd;
↧
↧
Problem with tf on multiple machines
I'm running ROS on two machines, a raspberry pi connected to sensors and a local machine for visualization.
Sending messages back and forth seems to all work fine, but something is going wrong with the tf data.
running 'rosrun tf view_frames' gives the same view_frames results and with 'rostopic echo /tf' it will show all the messages. However when running tf_monitor my local machine is not able to see any tf data:
RESULTS: for all Frames
Frames:
All Broadcasters:
On the raspberry pi:
RESULTS: for all Frames
Frames:
Frame: /base_footprint published by unknown_publisher Average Delay: -0.0991144 Max Delay: 0
Frame: /laser_frame published by unknown_publisher Average Delay: -0.0391848 Max Delay: 0
Frame: /map published by unknown_publisher Average Delay: -0.0992479 Max Delay: 0
Frame: odom published by unknown_publisher Average Delay: 0.00852357 Max Delay: 0.150682
Frame: scanmatcher_frame published by unknown_publisher Average Delay: 0.141719 Max Delay: 0.150837
All Broadcasters:
Node: unknown_publisher 71.8076 Hz, Average Delay: -0.0238966 Max Delay: 0.150837
env | grep ROS # on my raspberry pi
ROS_ROOT=/opt/ros/kinetic/share/ros
ROS_PACKAGE_PATH=/home/ubuntu/lidar_ws/src:/home/ubuntu/catkin_ws/src:/opt/ros/kinetic/share
ROS_MASTER_URI=http://IP_MAIN:11311
ROS_VERSION=1
ROS_PARALLEL_JOBS=-j2
ROS_HOSTNAME=IP_pi
ROSLISP_PACKAGE_DIRECTORIES=/home/ubuntu/lidar_ws/devel/share/common- lisp:/home/ubuntu/catkin_ws/devel/share/common-lisp
ROS_DISTRO=kinetic
ROS_IP=IP_pi
ROS_ETC_DIR=/opt/ros/kinetic/etc/ros
env | grep ROS # on my main pc
ROS_ROOT=/opt/ros/kinetic/share/ros
ROS_PACKAGE_PATH=/home/ubuntu/lidar_ws/src:/home/ubuntu/catkin_ws/src:/opt/ros/kinetic/share
ROS_MASTER_URI=http://IP_MAIN:11311
ROS_VERSION=1
ROS_PARALLEL_JOBS=-j2
ROS_HOSTNAME=IP_MAIN
ROSLISP_PACKAGE_DIRECTORIES=/home/ubuntu/lidar_ws/devel/share/common-lisp:/home/ubuntu/catkin_ws/devel/share/common-lisp
ROS_DISTRO=kinetic
ROS_IP= IP_MAIN
ROS_ETC_DIR=/opt/ros/kinetic/etc/ros
↧
Replace transform between odom and base
Using the [ardrone_autonomy](https://ardrone-autonomy.readthedocs.io/en/latest/) package, the [ardrone_driver](http://wiki.ros.org/ardrone_driver) makes some transformations, as seen in the following picture:

but I need to replace the transform between odom and ardrone_base_link frame by the transform provided by the [robot_localization](http://docs.ros.org/kinetic/api/robot_localization/html/index.html) package (if possible, I would like to maintain the [ardrone/odometry](https://ardrone-autonomy.readthedocs.io/en/latest/reading.html#odometry-data) topic). How can I do that?
The ardrone_driver is an executable:

↧
tf2 sendTransform() not actually sending anything
I'm trying to send a transformation from "world" to "base_link" based on coordinates I get from a different node. The node is actually running, and it is reaching the ROS_INFO() right before the `broadcaster.sendTransform(transformStamped);` (so the other node is working, and the tf2 broadcaster node gets the data and the callback is called repeatedly), but when I run `rosrun tf tf_monitor` to see what I get, it's empty:
RESULTS: for all Frames
Frames:
All Broadcasters:
I've been trying to find the mistake for 2 days now and I don't see what I'm doing wrong. Any advise?
#include
#include
#include
#include
#include "geometry_msgs/PoseStamped.h"
void posCallback(const geometry_msgs::PoseStamped& msg){
tf2_ros::TransformBroadcaster broadcaster;
geometry_msgs::TransformStamped transformStamped;
transformStamped.header.stamp = ros::Time::now();
transformStamped.header.frame_id = "world";
transformStamped.child_frame_id = "base_link";
transformStamped.transform.translation.x = msg.pose.position.x;
transformStamped.transform.translation.y = msg.pose.position.y;
transformStamped.transform.translation.z = msg.pose.position.z;
transformStamped.transform.rotation.x = msg.pose.orientation.x;
transformStamped.transform.rotation.y = msg.pose.orientation.y;
transformStamped.transform.rotation.z = msg.pose.orientation.z;
transformStamped.transform.rotation.w = msg.pose.orientation.w;
ROS_INFO("broadcast");
broadcaster.sendTransform(transformStamped);
}
int main(int argc, char **argv)
{
ros::init(argc, argv, "base_link_broadcaster");
ros::NodeHandle node;
ros::Subscriber sub = node.subscribe("positioning", 1000, posCallback);
ros::spin();
return 0;
}
↧