Robotics StackExchange | Archived questions

when i want to see the topic of /vehicle_info/pose, there is no data of the result

I download the gazebo of vehiclesim from github who is yukkysaito https://github.com/yukkysaito/vehiclesim

I use gazebo9 version, melodic, cpp

this is my question ---------------vehicleinfopublisher.cpp----------------

VehicleInfoPublisher::VehicleInfoPublisher() : nh(""), pnh("~") { client_ = nh.serviceClient<gazebomsgs::GetLinkState>("/gazebo/getlinkstate"); vehicleposepub_ = nh.advertise<geometrymsgs::PoseStamped>("/vehicleinfo/pose", 1, true); vehiclevelpub = nh.advertise<stdmsgs::Float64>("/vehicleinfo/velocity", 1, true); steeringanglepub = nh.advertise<stdmsgs::Float64>("/vehicleinfo/steeringangle", 1, true); double publishposerate; pnh.param("publishposerate", publishposerate, double(10.0)); pnh.param("wheelradius", wheelradius, 0.341); pnh.param("ns", ns, std::string("autowaregazebo")); publishtimer = nh.createTimer(ros::Duration(1.0 / publishposerate), &VehicleInfoPublisher::publishTimerCallback, this); odomsub_ = nh.subscribe("jointstates", 1, &VehicleInfoPublisher::jointStateCallback, this); }

} there are 3 topic of vehicleinfo(pose, velocity, angle) but I can get data of velocity, angle except for pose data ^Cheader: seq: 27445 stamp: secs: 6863 nsecs: 773000000 frameid: "base_link" pose: position: x: 0.0 y: 0.0 z: 0.0 orientation: x: 0.0 y: 0.0 z: 0.0 w: 0.0

  1. how can I get dat of pose?
  2. can i get gazebo topic? in detail, there is many topic in gazebo simulation and also i can see the data of vehicle pose by graph in gazebo how can i publish the topic of gazebo simulation?

Asked by hyunjune on 2021-09-30 21:09:49 UTC

Comments

Answers