amcl_sensor.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00021
00022
00023
00024
00025
00026
00028
00029 #ifndef AMCL_SENSOR_H
00030 #define AMCL_SENSOR_H
00031
00032 #include "amcl.h"
00033
00034 #include <libplayercore/playercore.h>
00035 #include "pf/pf.h"
00036
00037
00038
00039 class AMCLSensorData;
00040
00041
00042
00043 class AMCLSensor
00044 {
00045
00046 public: AMCLSensor(AdaptiveMCL & aAMCL);
00047
00048
00049 public: virtual ~AMCLSensor();
00050
00051
00052 public: virtual int Load(ConfigFile* cf, int section);
00053
00054
00055 public: virtual int Unload(void);
00056
00057
00058 public: virtual int Setup(void);
00059
00060
00061 public: virtual int Shutdown(void);
00062
00063
00064 public: virtual int ProcessMessage(QueuePointer &resp_queue,
00065 player_msghdr * hdr,
00066 void * data) = 0;
00067
00068
00069
00070
00071 public: virtual bool UpdateAction(pf_t *pf, AMCLSensorData *data);
00072
00073
00074
00075 public: virtual bool InitSensor(pf_t *pf, AMCLSensorData *data);
00076
00077
00078
00079 public: virtual bool UpdateSensor(pf_t *pf, AMCLSensorData *data);
00080
00081
00082 public: bool is_action;
00083
00084
00085 public: pf_vector_t pose;
00086
00087
00088 protected: AdaptiveMCL & AMCL;
00089
00090 #ifdef INCLUDE_RTKGUI
00091
00092 public: virtual void SetupGUI(rtk_canvas_t *canvas, rtk_fig_t *robot_fig);
00093
00094
00095 public: virtual void ShutdownGUI(rtk_canvas_t *canvas, rtk_fig_t *robot_fig);
00096
00097
00098 public: virtual void UpdateGUI(rtk_canvas_t *canvas, rtk_fig_t *robot_fig, AMCLSensorData *data);
00099 #endif
00100 };
00101
00102
00103
00104
00105 class AMCLSensorData
00106 {
00107
00108 public: AMCLSensor *sensor;
00109 virtual ~AMCLSensorData() {}
00110
00111
00112 public: double time;
00113 };
00114
00115
00116
00117 #endif
Last updated 12 September 2005 21:38:45
|