Tracker_Calibration_impl.h
Go to the documentation of this file.
00001 
00018 #ifndef TRACKER_CALIBRATION_H
00019 #define TRACKER_CALIBRATION_H
00020 
00021 /* system includes */
00022 #include <vector>
00023 /* my includes */
00024 #include "qt_calibration.uic.h"
00025 
00026 // KOGMO_RTDB standard includes
00027 #define KOGMO_RTDB_DONT_INCLUDE_ALL_OBJECTS
00028 #include "kogmo_rtdb.h"
00029 #include "kogmo_rtdb_obj_typeids.h"
00030 //KOGMO_RTDB special includes for our project with the id E1
00031 #include "itec/kogmo_rtdb_obj_e1_itec.h"
00032 using namespace KogniMobil;
00033 
00034 
00041 class Tracker_Calibration_impl
00042   : public qt_Tracker_Calibration
00043 {
00044  public:
00045   Tracker_Calibration_impl();
00046   ~Tracker_Calibration_impl();
00047 
00048   virtual void connectSlot();
00049   virtual void saveSlot();
00050   virtual void loadSlot();
00051   virtual void helpSlot();
00052   virtual void GetNAdd_clicked();
00053   virtual void ResetCalib_clicked();
00054   virtual void SendDataToTracker_clicked();
00055   virtual void saveCoord();
00056   virtual void loadCoord();
00057   virtual void clearAllData();
00058 
00059   struct fulcrum{
00060     double sensorVal[3];
00061     double sensorAngle[3];
00062     double worldVal[3];
00063     double worldAngle[3];
00064   };
00065 
00066   typedef std::pair<double, double> fulcrumPair;
00067   typedef std::vector<fulcrumPair> sensorCal;
00068   typedef std::vector<sensorCal> trackerCal;
00069   
00070 private:
00071   int openDevice(std::string &trackLeftId, std::string &trackRightId);
00072   int closeDevice();
00073   void updateCounter();
00074 
00075   void printFulcrum(fulcrum fulc);
00076   bool displayCal(trackerCal cal);
00077 
00078   bool trackLeft;
00079   bool trackRight;
00080   
00081   int fcountLeft;
00082   int fcountRight;
00083   int coordCountLeft;
00084   int coordCountRight;
00085 
00086   fulcrum fulcrumarrayLeft[255];
00087   fulcrum fulcrumarrayRight[255];
00088 
00089    /* variables that handle the database connection */
00090   kogmo_rtdb_handle_t *dbc; /*< the database connection handle */
00091   kogmo_rtdb_connect_info_t dbinfo; /*< information about the database connection */
00092   kogmo_rtdb_obj_info_t dataobj_left_info; /*< information about the type of the dataobject */
00093   kogmo_rtdb_obj_info_t dataobj_right_info; /*< information about the type of the dataobject */
00094   kogmo_rtdb_obj_e1_fobtracker_t *dataobj_left; /*< the dataobject specific to the sensor */
00095   kogmo_rtdb_obj_e1_fobtracker_t *dataobj_right; /*< the dataobject specific to the sensor */
00096   kogmo_rtdb_objid_t oidLeft; /*< id of our object within the database */
00097   kogmo_rtdb_objid_t oidRight; /*< another id */
00098 };
00099 
00100 
00101 #endif /* TRACKER_CALIBRATION_H */


asr_flock_of_birds
Author(s): Bernhardt Andre, Engelmann Stephan, Giesler Björn, Heller Florian, Jäkel Rainer, Nguyen Trung, Pardowitz Michael, Weckesser Peter, Yi Xie, Zöllner Raoul
autogenerated on Sat Jun 8 2019 19:36:21