GAMS  1.4.0
DebugPlatform.h
Go to the documentation of this file.
1 
55 #ifndef _GAMS_PLATFORM_PRINTER_H_
56 #define _GAMS_PLATFORM_PRINTER_H_
57 
58 #include "madara/knowledge/KnowledgeBase.h"
59 #include "madara/knowledge/containers/Integer.h"
60 
61 #include "gams/variables/Self.h"
62 #include "gams/variables/Sensor.h"
67 
68 namespace gams
69 {
70  namespace platforms
71  {
76  {
77  public:
89  madara::knowledge::KnowledgeBase * knowledge,
90  variables::Sensors * sensors,
91  variables::Platforms * platforms,
92  variables::Self * self,
93  const std::string & executions_location = ".executions");
94 
99 
104  void operator=(const DebugPlatform & rhs);
105 
110  virtual int analyze(void) override;
111 
116  virtual double get_accuracy() const override;
117 
123  virtual std::string get_id() const override;
124 
128  virtual double get_move_speed() const override;
129 
133  virtual std::string get_name() const override;
134 
139  virtual int home(void) override;
140 
145  virtual int land(void) override;
146 
153  int move(const pose::Position & position,
154  const pose::PositionBounds &bounds) override;
155 
156  using BasePlatform::move;
157 
162  virtual int sense(void) override;
163 
168  virtual void set_move_speed(const double& speed) override;
169 
174  virtual int takeoff(void) override;
175 
176  protected:
177 
180 
188  madara::knowledge::containers::Integer executions_;
189  };
190 
195  {
196  public:
197 
210  virtual BasePlatform * create(
211  const madara::knowledge::KnowledgeMap & args,
212  madara::knowledge::KnowledgeBase * knowledge,
213  variables::Sensors * sensors,
214  variables::Platforms * platforms,
215  variables::Self * self);
216  };
217  }
218 }
219 
220 #endif // _GAMS_PLATFORM_PRINTER_H_
Copyright(c) 2014 Carnegie Mellon University.
#define GAMS_EXPORT
Definition: GamsExport.h:20
Copyright(c) 2014 Carnegie Mellon University.
Copyright(c) 2014 Carnegie Mellon University.
Copyright(c) 2014 Carnegie Mellon University.
Copyright(c) 2014 Carnegie Mellon University.
The base platform for all platforms to use.
Definition: BasePlatform.h:113
virtual int move(const pose::Position &target)
Moves the platform to a location.
Definition: BasePlatform.h:230
A factory class for creating debug platforms.
virtual BasePlatform * create(const madara::knowledge::KnowledgeMap &args, madara::knowledge::KnowledgeBase *knowledge, variables::Sensors *sensors, variables::Platforms *platforms, variables::Self *self)
Creates a debug platform.
A debug platform that prints detailed status information.
Definition: DebugPlatform.h:76
int move(const pose::Position &position, const pose::PositionBounds &bounds) override
Moves the platform to a position.
madara::knowledge::containers::Integer executions_
Used to keep track of executions.
virtual int land(void) override
Instructs the platform to land.
virtual int analyze(void) override
Analyzes platform information.
void operator=(const DebugPlatform &rhs)
Assignment operator.
virtual int sense(void) override
Polls the sensor environment for useful information.
virtual int home(void) override
Instructs the agent to return home.
pose::Position position_
current position
virtual void set_move_speed(const double &speed) override
Set move speed.
virtual double get_accuracy() const override
Get the location aproximation value of what is considered close enough.
virtual std::string get_name() const override
Gets the name of the platform.
DebugPlatform(madara::knowledge::KnowledgeBase *knowledge, variables::Sensors *sensors, variables::Platforms *platforms, variables::Self *self, const std::string &executions_location=".executions")
Constructor.
virtual int takeoff(void) override
Instructs the platform to take off.
virtual std::string get_id() const override
Gets the unique identifier of the platform.
virtual double get_move_speed() const override
Get move speed.
Base class for platform factories to create BasePlatforms.
Interface for defining a bounds checker for Positions.
Definition: Epsilon.h:68
A container for self referencing information.
Definition: Self.h:70
std::map< std::string, PlatformStatus > Platforms
a map of sensor names to the sensor information
std::map< std::string, Sensor * > Sensors
a map of sensor names to the sensor information
Definition: Sensor.h:238
Contains all GAMS-related tools, classes and code.
Copyright (c) 2015 Carnegie Mellon University.