✏️ fix planning scene monitor topics

This commit is contained in:
Ilya Uraev 2021-11-08 23:36:22 +04:00
parent 77739576fc
commit b1ae818aa0
3 changed files with 10 additions and 5 deletions

View file

@ -48,12 +48,17 @@ int main(int argc, char** argv)
RCLCPP_INFO(LOGGER, "Starting MoveIt Tutorials...");
auto moveit_cpp_ptr = std::make_shared<moveit_cpp::MoveItCpp>(node);
// get error in thes line
moveit_cpp_ptr->getPlanningSceneMonitor()->providePlanningSceneService();
RCLCPP_INFO(LOGGER, "Success getPlanningSceneMonitor()");
auto planning_components = std::make_shared<moveit_cpp::PlanningComponent>(PLANNING_GROUP, moveit_cpp_ptr);
auto robot_model_ptr = moveit_cpp_ptr->getRobotModel();
RCLCPP_INFO(LOGGER, "Success getRobotModel()");
auto robot_start_state = planning_components->getStartState();
RCLCPP_INFO(LOGGER, "Success getStartState()");
auto joint_model_group_ptr = robot_model_ptr->getJointModelGroup(PLANNING_GROUP);
RCLCPP_INFO(LOGGER, "Success getJointModelGroup()");
// Visualization
// ^^^^^^^^^^^^^