hasauino / rrt_exploration_tutorials

This package provides launch files for Gazebo simulation needed to test the rrt_exploration package
http://wiki.ros.org/rrt_exploration/Tutorials
101 stars 39 forks source link

Message class rrt_exploration/PointArray not loaded #17

Closed ikvibhav closed 3 years ago

ikvibhav commented 3 years ago

Hello

I am running the simple.launch code on a custom robot (Not the Kobuki robot). The spawning and then gmapping for 1 robot works well. When I launch the command "roslaunch rrt_exploration simple.launch" the rrt for 1 robot, the assigner and fliter are launched as shown in the below rqt graph,

pointarray_issue

The Issues I am facing are:- 1) When I try to mark the boundary on rviz, then I am facing the similiar problem as mentioned here (https://github.com/hasauino/rrt_exploration_tutorials/issues/1). But I checked and found that the filter and assigner is working. 2) I then echoed the topics /clicked_point , /detected_points and /filtered_points. The topics /clicked_point and /detected_points were able to display data but when doing an echo of /filtered_points, I get an error saying,

ERROR: Cannot load message class for [rrt_exploration/PointArray]. Are your messages built?

I have checked the package.xml and CMakeList.txt files and they appear to follow the convention given here (http://wiki.ros.org/ROS/Tutorials/CreatingMsgAndSrv#Creating_a_msg).

So, I wanted to know how can I solve this error and enable RRT functionality?

hasauino commented 3 years ago

So when you publish the 5 points, the RRT does not start? but the five points you published are shown by RViz?

ikvibhav commented 3 years ago

No, 5 points do not appear on RVIz. Only the point that is most recently clicked appears on rviz and the other points do not sustain on the screen.

Also, /detected_points immediately starts to give out values only after I make the 5 required point clicks.

hasauino commented 3 years ago

It's ok if the points do not show on RViz, looks like you open RViz with a configuration different than what is included in this package ( rrt_exploration/../rviz_config/simple.rviz). So the topic (/global_detector_shapes) that shows these points is not added to Rviz. Regardless of that, since you see the points being published on /detected_points, then the RRT detectors should be running normally I assume.

You are saying that the filter is not publishing on the /filtered_points, I don't really know why you are getting the error you mentioned (ERROR: Cannot load message class for [rrt_exploration/PointArray..). I think this is not related to the rrt_exploration package in particular... I tested this package many times on my PC, ROS kinetic, I never had that error..

At start, the filter node waits for the map, the global cost map, and for the transformation between the robot frame (default to /base_link, and the map frame). So can you show your TF tree? because your map topic and global cost map topic seem to be Ok from your screenshot above..

ikvibhav commented 3 years ago

Okay, I loaded the rviz file as given in the rrt_exploration_tutorials package. Previously I was using my own rviz file ( navigation_cfg.zip ). On doing this:- 1) The RRT paths are visible 2) The 5 points are coming 3) /filtered_points is getting published

Basically, the path planning appears to be working. Thank you. However, the robot does not move (Possibly due to a mismatch in topic, I need to check) and continues to remain in the same position.

I am running this package on ROS melodic. Would there be any issues?

The TF link is as follows:- frames.pdf

In summary, the planning and rrt path generation works but I think the only issue now is the movement of the robot.

hasauino commented 3 years ago

I'm not sure if the navigation stack has significant changes between ROS melodic and ROS kinetic, but I never had tested it on melodic. You are saying you can send the robot a point manually and it will move, but the assigner node in the rrt_exploration package does not move the robot... so I think I need to make changes on the assigner node to work with melodic release of the navigation stack... If you really want to make it work, the only file that is responsible for maoving the robot and interfacing with the navigation stack is: https://github.com/hasauino/rrt_exploration/blob/master/scripts/functions.py In line 40 it defines an action client to the move base node to send the goals... sorry I don't have ROS melodic to try out and see what's wrong ...

ikvibhav commented 3 years ago

Yes, by manually setting up a point, the robot is able to move.

I also checked and tried editing the line from self.client = actionlib.SimpleActionClient(self.name+'/move_base', MoveBaseAction) to self.client = actionlib.SimpleActionClient('/move_base', MoveBaseAction) However it did not work. My next attempt is to assign a namespace (like robot1) to the robot and then try it out by using simple.launch or single.launch .

No worries! But yes, I think a melodic release would possibly remove any unseen errors.

hasauino commented 3 years ago

I don't think changing the name space will make it work. I will close this issue for now, thanks