config_routine.cpp
Go to the documentation of this file.
4 #include <gb_grasp/GraspPipelineDemo.h>
5 
6 
7 
8 int main(int argc, char *argv[]) {
9 
10  ros::init(argc, argv, "config_routine");
11  std::shared_ptr<ros::NodeHandle> n(new ros::NodeHandle);
12 
13  // Allow the action server to recieve and send ros messages
14  ros::AsyncSpinner spinner(2);
15  spinner.start();
16 
17  std::shared_ptr<GraspMediator> mediator = std::make_shared<GraspMediator>(n);
18 
19  auto rd = mediator->robotReader()->robotData();
20  for (int i = 0; i < rd.size() ;i++){
21  std::unique_ptr<AbstractRobot> ceti = std::make_unique<CetiRobot>(rd[i].name_, rd[i].pose_, rd[i].size_);
22  std::unique_ptr<PandaDecorator> ceti_panda = std::make_unique<PandaDecorator>(std::move(ceti));
23  mediator->connectRobots(std::move(ceti_panda));
24  }
25 
26  mediator->mediate();
27 
28  while (ros::ok()){
29  ros::spinOnce();
30  }
31  return 0;
32 }
abstract_mediator.h
main
int main(int argc, char *argv[])
Definition: config_routine.cpp:8
grasp_mediator.h
panda_decorator.h


multi_cell_builder
Author(s): Matteo Anedda
autogenerated on Sun Apr 9 2023 23:59:51