GAMS  1.2.2
SnakeAreaCoverage.h
Go to the documentation of this file.
1 
54 #ifndef _GAMS_ALGORITHMS_AREA_COVERAGE_SNAKE_AREA_COVERAGE_H_
55 #define _GAMS_ALGORITHMS_AREA_COVERAGE_SNAKE_AREA_COVERAGE_H_
56 
59 
60 #include <string>
61 #include <vector>
62 
63 #include "gams/variables/Sensor.h"
66 #include "gams/variables/Self.h"
67 
68 namespace gams
69 {
70  namespace algorithms
71  {
72  namespace area_coverage
73  {
79  {
80  public:
92  const std::string& region_id,
93  double e_time,
94  madara::knowledge::KnowledgeBase * knowledge = 0,
95  platforms::BasePlatform * platform = 0,
96  variables::Sensors * sensors = 0,
97  variables::Self * self = 0,
98  variables::Agents * agents = 0);
99 
103  ~SnakeAreaCoverage ();
104 
109  void operator= (const SnakeAreaCoverage & rhs);
110 
111  protected:
115  void generate_new_position (void);
116 
120  void compute_waypoints (const std::string& region_id);
121 
123  std::vector<utility::GPSPosition> waypoints_;
124 
126  unsigned int cur_waypoint_;
127 
129  std::string region_id_;
130  }; // class SnakeAreaCoverage
131 
137  : public AlgorithmFactory
138  {
139  public:
140 
155  virtual BaseAlgorithm * create (
156  const madara::knowledge::KnowledgeMap & args,
157  madara::knowledge::KnowledgeBase * knowledge,
158  platforms::BasePlatform * platform,
159  variables::Sensors * sensors,
160  variables::Self * self,
161  variables::Agents * agents);
162  };
163  } // namespace area_coverage
164  } // namespace algorithms
165 } // namespace gams
166 
167 #endif // _GAMS_ALGORITHMS_AREA_COVERAGE_SNAKE_AREA_COVERAGE_H_
Base class for algorithm factories that classes derived from.
std::string region_id_
the region description
Implements a serpentine pattern-based area coverage that is minimum time but easy to predict (adversa...
std::map< std::string, Sensor * > Sensors
a map of sensor names to the sensor information
Definition: Sensor.h:238
The base platform for all platforms to use.
Definition: BasePlatform.h:190
Copyright (c) 2014 Carnegie Mellon University.
std::vector< Agent > Agents
An array of agent knowledge.
Definition: Agent.h:246
Copyright (c) 2014 Carnegie Mellon University.
Base class for all area coverages.
Contains all GAMS-related tools, classes and code.
A container for self referencing information.
Definition: Self.h:69
#define GAMS_EXPORT
Definition: GamsExport.h:20
std::vector< utility::GPSPosition > waypoints_
waypoints
The base class that algorithms in GAMS use.
Definition: BaseAlgorithm.h:94
Copyright (c) 2014 Carnegie Mellon University.
A factory class for creating snake/lawnmower area coverage algorithms.
Copyright (c) 2014 Carnegie Mellon University.
Copyright (c) 2014 Carnegie Mellon University.