debug_dwb_local_planner.h
Go to the documentation of this file.
1 /*
2  * Software License Agreement (BSD License)
3  *
4  * Copyright (c) 2017, Locus Robotics
5  * All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions
9  * are met:
10  *
11  * * Redistributions of source code must retain the above copyright
12  * notice, this list of conditions and the following disclaimer.
13  * * Redistributions in binary form must reproduce the above
14  * copyright notice, this list of conditions and the following
15  * disclaimer in the documentation and/or other materials provided
16  * with the distribution.
17  * * Neither the name of the copyright holder nor the names of its
18  * contributors may be used to endorse or promote products derived
19  * from this software without specific prior written permission.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
24  * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
25  * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
26  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
27  * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
28  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
29  * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
31  * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
32  * POSSIBILITY OF SUCH DAMAGE.
33  */
34 
35 #ifndef DWB_LOCAL_PLANNER_DEBUG_DWB_LOCAL_PLANNER_H
36 #define DWB_LOCAL_PLANNER_DEBUG_DWB_LOCAL_PLANNER_H
37 
39 #include <dwb_msgs/DebugLocalPlan.h>
40 #include <dwb_msgs/GenerateTwists.h>
41 #include <dwb_msgs/GenerateTrajectory.h>
42 #include <dwb_msgs/ScoreTrajectory.h>
43 #include <dwb_msgs/GetCriticScore.h>
44 #include <string>
45 
46 namespace dwb_local_planner
47 {
48 
55 {
56 public:
60  void initialize(const ros::NodeHandle& parent, const std::string& name,
61  TFListenerPtr tf, nav_core2::Costmap::Ptr costmap) override;
62 protected:
63  bool generateTwistsService(dwb_msgs::GenerateTwists::Request &req,
64  dwb_msgs::GenerateTwists::Response &res);
65  bool generateTrajectoryService(dwb_msgs::GenerateTrajectory::Request &req,
66  dwb_msgs::GenerateTrajectory::Response &res);
67  bool scoreTrajectoryService(dwb_msgs::ScoreTrajectory::Request &req,
68  dwb_msgs::ScoreTrajectory::Response &res);
69  bool getCriticScoreService(dwb_msgs::GetCriticScore::Request &req,
70  dwb_msgs::GetCriticScore::Response &res);
71  bool debugLocalPlanService(dwb_msgs::DebugLocalPlan::Request &req,
72  dwb_msgs::DebugLocalPlan::Response &res);
73 
74  TrajectoryCritic::Ptr getCritic(std::string name);
75 
77 };
78 
79 } // namespace dwb_local_planner
80 
81 #endif // DWB_LOCAL_PLANNER_DEBUG_DWB_LOCAL_PLANNER_H
dwb_local_planner::TrajectoryCritic::Ptr
std::shared_ptr< dwb_local_planner::TrajectoryCritic > Ptr
Definition: trajectory_critic.h:79
dwb_local_planner::DWBLocalPlanner
Plugin-based flexible local_planner.
Definition: dwb_local_planner.h:55
dwb_local_planner.h
dwb_local_planner::DebugDWBLocalPlanner::generateTwistsService
bool generateTwistsService(dwb_msgs::GenerateTwists::Request &req, dwb_msgs::GenerateTwists::Response &res)
Definition: debug_dwb_local_planner.cpp:62
dwb_local_planner::DebugDWBLocalPlanner::debugLocalPlanService
bool debugLocalPlanService(dwb_msgs::DebugLocalPlan::Request &req, dwb_msgs::DebugLocalPlan::Response &res)
Definition: debug_dwb_local_planner.cpp:125
dwb_local_planner::DebugDWBLocalPlanner::scoreTrajectoryService
bool scoreTrajectoryService(dwb_msgs::ScoreTrajectory::Request &req, dwb_msgs::ScoreTrajectory::Response &res)
Definition: debug_dwb_local_planner.cpp:76
dwb_local_planner
Definition: backwards_compatibility.h:40
ros::ServiceServer
dwb_local_planner::DebugDWBLocalPlanner::generate_traj_service_
ros::ServiceServer generate_traj_service_
Definition: debug_dwb_local_planner.h:76
dwb_local_planner::DebugDWBLocalPlanner::getCriticScoreService
bool getCriticScoreService(dwb_msgs::GetCriticScore::Request &req, dwb_msgs::GetCriticScore::Response &res)
Definition: debug_dwb_local_planner.cpp:99
dwb_local_planner::DebugDWBLocalPlanner::getCritic
TrajectoryCritic::Ptr getCritic(std::string name)
Definition: debug_dwb_local_planner.cpp:89
dwb_local_planner::DebugDWBLocalPlanner
A version of DWBLocalPlanner with ROS services for the major components.
Definition: debug_dwb_local_planner.h:54
dwb_local_planner::DebugDWBLocalPlanner::generateTrajectoryService
bool generateTrajectoryService(dwb_msgs::GenerateTrajectory::Request &req, dwb_msgs::GenerateTrajectory::Response &res)
Definition: debug_dwb_local_planner.cpp:69
nav_core2::Costmap::Ptr
std::shared_ptr< Costmap > Ptr
TFListenerPtr
std::shared_ptr< tf2_ros::Buffer > TFListenerPtr
dwb_local_planner::DebugDWBLocalPlanner::initialize
void initialize(const ros::NodeHandle &parent, const std::string &name, TFListenerPtr tf, nav_core2::Costmap::Ptr costmap) override
Override the DWB constructor to also advertise the services.
Definition: debug_dwb_local_planner.cpp:45
tf
dwb_local_planner::DebugDWBLocalPlanner::critic_service_
ros::ServiceServer critic_service_
Definition: debug_dwb_local_planner.h:76
dwb_local_planner::DebugDWBLocalPlanner::debug_service_
ros::ServiceServer debug_service_
Definition: debug_dwb_local_planner.h:76
dwb_local_planner::DebugDWBLocalPlanner::score_service_
ros::ServiceServer score_service_
Definition: debug_dwb_local_planner.h:76
dwb_local_planner::DebugDWBLocalPlanner::twist_gen_service_
ros::ServiceServer twist_gen_service_
Definition: debug_dwb_local_planner.h:76
ros::NodeHandle


dwb_local_planner
Author(s): David V. Lu!!
autogenerated on Sun May 18 2025 02:47:25