-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
33 lines (32 loc) · 867 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*
* main.cpp
*
* Created on: Jan 7, 2016
* Author: user
*/
#include "Plans/PlnObstacleAvoid.h"
#include "robot.h"
#include "Manager.h"
#include "Map/Map.h"
#include "STCAlg/STC.h"
#include "InitEnvironment.h"
const char* PARAMETERS = "parameters.txt";
int main()
{
Robot* robot = new Robot("localhost", 6665);
cout<<"start main"<<endl;
InitEnvironment init = InitEnvironment(PARAMETERS);
robot->updatePosition(init.getStartLocation().location.second,init.getStartLocation().location.first,init.getStartLocation().yaw);
cout<<"start wp"<<endl;
wayPoint wp = init.getStartLocationAsStartWaypoint();
wayPoint* wpn =wp.getNext();
cout<<"start wp"<<endl;
robot->setDestWayPoint(wpn);
cout<<"start wp"<<endl;
PlnObstacleAvoid pln(robot);
cout<<"start manager"<<endl;
Manager manager(robot, &pln);
cout<<"run"<<endl;
manager.run();
return 0;
}