MRXT: The Multi-Robot eXploration Tool
Multi-Robot autonomous exploration and mapping simulator.
|
00001 /* 00002 * 00003 * Author: Miguel Julia <mjulia@umh.es> 00004 * 00005 * Date: 2009 00006 * 00007 * Class worldModelInterface 00008 * 00009 * 00010 */ 00011 00012 #pragma once 00013 #ifndef __WORLD__MODEL__INTERFACE__ 00014 #define __WORLD__MODEL__INTERFACE__ 00015 00016 #include "rangeSensorData.h" 00017 #include "landmarksData.h" 00018 00019 #include "ClThread.h" 00020 #include "ConfigFile.h" 00021 #include "stepEvent.h" 00022 #include "robotBase.h" 00023 #include <QObject> 00024 00025 00026 typedef std::vector< std::vector<line> > rlines; 00027 typedef std::vector< pose > rposes; 00028 00029 /** 00030 * @brief Defines the world model interface 00031 00032 * 00033 */ 00034 class worldModelInterface: public QObject, public ClThread, public production 00035 { 00036 00037 /////////////////////////////////////////////////////////////////////// 00038 //------------------------- Methods -------------------------------- 00039 /////////////////////////////////////////////////////////////////////// 00040 public: 00041 00042 virtual ~worldModelInterface(){}; 00043 00044 worldModelInterface():production(1){}; 00045 00046 /// initializer 00047 virtual void initialize(int nBots, ConfigFile& configfile, float sampletime)=0; 00048 00049 /// returns the range sensor current data 00050 virtual rangeSensorData* getRangeSensorData(int robot)=0; 00051 /// returns the landmarks data 00052 virtual landmarksData* getLandmarksData(int robot)=0; 00053 /// returns the robot odometry 00054 virtual pose* getOdometry(int robot)=0; 00055 00056 /// sets the linear and angular speed for a robot 00057 virtual void setSpeed(int r, float v, float w)=0; 00058 /// sets the name of the log file 00059 virtual void setLogName(const char*)=0; 00060 00061 virtual robotBase* createNewPlatform()=0; 00062 virtual void disablePlatform(const robotBase& r)=0; 00063 00064 virtual int fire(int robot)=0; 00065 00066 virtual int getNumRobots()=0; 00067 virtual void setNumRobots(int num)=0; 00068 00069 00070 virtual const char* getOMapFileName() const=0; 00071 00072 virtual float getTime() const=0; 00073 virtual float getSampleTime() const=0; 00074 virtual void randomPoses(bool group, double maxInitialPoseDist, double minInitialPoseDist)=0; 00075 00076 virtual rposes getPoses() const=0; 00077 00078 00079 //--------------------------------------------------------------------- 00080 /////////////////////////////////////////////////////////////////////// 00081 }; 00082 00083 #endif 00084