Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

edit goal subscriber topic, add goal_pub node termination, improve readme.txt #5

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ $ catkin_make
**running the examples scenarios**

some examples scenarios (using stage) are provided in worlds/
run goal node setting eg. x = 1, y = 10 with
$ rosrun riskrrt goal_pub 1 10
run the scenario with
$ roslaunch riskrrt scenario_name.launch
change the planner behavior by modifying the parameters in params/riskrrt_params.yaml
Expand Down
2 changes: 1 addition & 1 deletion riskrrt/src/goal_pub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ int main(int argc, char **argv)
ros::Rate loop_rate(100);


while(goal_pub.getNumSubscribers() == 0){
while(goal_pub.getNumSubscribers() == 0 && ros::ok()){
loop_rate.sleep();
}

Expand Down
2 changes: 1 addition & 1 deletion riskrrt/src/riskrrt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -644,6 +644,6 @@ void RRT::goalCallback(const geometry_msgs::PoseStamped::ConstPtr& msg){
}

void RRT::initGoalSub(){
goalSubscriber = nodeHandle.subscribe("/goal", 1, &RRT::goalCallback, this);
goalSubscriber = nodeHandle.subscribe("goal", 1, &RRT::goalCallback, this);
}
//end of subscribers initializations and callbacks