- Timestamp:
- Jan 9, 2013, 1:40:39 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/Pacpus/DbitePlayer/DbtPlyEngine.h
r31 r61 71 71 void reset(); 72 72 73 /// @todo Documentation 73 74 void speedUp(); 75 /// @todo Documentation 74 76 void speedDown(); 77 /// @todo Documentation 75 78 void setLastTNow(road_time_t newTNow) 76 79 { … … 79 82 80 83 protected: 81 // The 3 virtual methods relative to the ComponentBase inheritance84 /// @todo Documentation 82 85 virtual void startActivity(); 86 /// @todo Documentation 83 87 virtual void stopActivity(); 88 /// @todo Documentation 84 89 virtual COMPONENT_CONFIGURATION configureComponent(XmlComponentConfig config); 85 90 … … 122 127 123 128 Q_SIGNALS: 129 /// @todo Documentation 124 130 void play(road_time_t timeToPlay, road_time_t actualTime, bool direction); 131 /// @todo Documentation 125 132 void stopfile(); 133 /// @todo Documentation 126 134 void displayStateSig(DbtPlyEngineState * state, float speed); 135 /// @todo Documentation 127 136 void timeMinMax(road_time_t tMin, road_time_t tMax); 137 /// @todo Documentation 128 138 void curReplayTime(road_time_t time); 129 139 130 140 public Q_SLOTS: 141 /// @todo Documentation 131 142 void engReceiver(); 143 /// @todo Documentation 132 144 void changeDirection(bool reverse); 145 /// @todo Documentation 133 146 void tMinMax(road_time_t tMin, road_time_t tMax); 134 147 148 /// @todo Documentation 135 149 void playEvent(); 150 /// @todo Documentation 136 151 void pauseEvent(); 152 /// @todo Documentation 137 153 void stopEvent(); 154 /// @todo Documentation 138 155 void speedUpEvent(); 156 /// @todo Documentation 139 157 void speedDownEvent(); 140 158 }; -
trunk/include/Pacpus/DbitePlayer/DbtPlyFileManager.h
r31 r61 41 41 42 42 public: 43 // constructor43 /// constructor 44 44 DbtPlyFileManager(QString name); 45 // destructor45 /// destructor 46 46 virtual ~DbtPlyFileManager(); 47 47 48 // the player replays only the last data that has not been yet replayed 48 /// the player replays only the last data that has not been yet replayed 49 /// @todo Rename 49 50 void playMode1 (road_time_t tDbt, bool reverse); 50 // the player replays all the data that have not been yet replayed 51 /// the player replays all the data that have not been yet replayed 52 /// @todo Rename 51 53 void playMode2 (road_time_t tDbt, bool reverse); 52 54 53 // virtual method: call when new DBT data are replayed55 /// virtual method: call when new DBT data are replayed 54 56 virtual void processData(road_time_t time, road_timerange_t timeRange, void * data) = 0; 55 57 virtual void displayUI(); 56 58 57 // 3 Virtual methods relative to the ComponentBase inheritance59 /// 3 Virtual methods relative to the ComponentBase inheritance 58 60 virtual COMPONENT_CONFIGURATION configureComponent(XmlComponentConfig config); 61 /// @todo Documentation 59 62 virtual void startActivity(); 63 /// @todo Documentation 60 64 virtual void stopActivity(); 61 65 62 // The loop of the thread66 /// The loop of the thread 63 67 virtual void run(); 64 68 65 69 public Q_SLOTS: 66 // slot activated by the engine when it computes new DBT time70 /// slot activated by the engine when it computes new DBT time 67 71 void playData(road_time_t tDbt,road_time_t tNow, bool reverse); 68 72 69 // put the file descriptor to the beginning of the file73 /// put the file descriptor to the beginning of the file 70 74 void beginfile(); 71 75 72 76 Q_SIGNALS: 73 // signal sent to the engine to provide to it the tmin and tmax of the file77 /// signal sent to the engine to provide to it the tmin and tmax of the file 74 78 void tMinMaxIs(road_time_t tmin, road_time_t tmax); 75 79 … … 78 82 int mVerbose; 79 83 80 // a pointer on the player engine84 /// a pointer on the player engine 81 85 DbtPlyEngine * mEngine; 82 86 83 // the absolute path of the DBT file87 /// the absolute path of the DBT file 84 88 QString dbtProperty_; 85 89 QStringList mDbtFilenameList; 86 90 87 // The directory where the DBT file is located91 /// The directory where the DBT file is located 88 92 QString mDbtDataPath; 89 93 90 // Display or not the graphical interface94 /// Display or not the graphical interface 91 95 bool mShowGui; 92 96 97 /// @todo Documentation 93 98 struct dbtStruct 94 99 { … … 98 103 }; 99 104 105 /// @todo Documentation 100 106 struct dbtStructFile 101 107 { … … 112 118 113 119 private: 120 /// @todo Documentation 114 121 bool processDbtFileHdfile(dbtStructFile & dbtFile, pacpus::DbiteFile::ReadDirection direction); 115 122 … … 118 125 bool reverse_; 119 126 120 // the estimated DBT time sent by the engine and computed relatively to the state of the player127 /// the estimated DBT time sent by the engine and computed relatively to the state of the player 121 128 road_time_t timeToRead_; 122 129 123 // The mode of replay124 // see playModeN method130 /// The mode of replay 131 /// @see playMode1, playMode2 methods 125 132 int mode_; 126 133 127 // The minimum and maximum time of the data contained in the file134 /// The minimum and maximum time of the data contained in the file 128 135 road_time_t tMin_, tMax_; 129 136 130 // the synchronization semaphore with the engine137 /// the synchronization semaphore with the engine 131 138 QSemaphore * sync_; 132 139 133 // For statistics purpose - delta time between the instant when the tDbt is computed and the instant when it is134 // taken into account by the file manager140 /// For statistics purpose - delta time between the instant when the tDbt is computed and the instant when it is 141 /// taken into account by the file manager 135 142 int deltaTDbtTab_[1000]; 136 143 int deltaTDbtTabLoop_; -
trunk/include/Pacpus/DbitePlayer/DbtPlyTrigger.h
r31 r61 35 35 36 36 public: 37 /// @todo Documentation 37 38 DbtPlyTrigger(QString name); 39 /// @todo Documentation 38 40 virtual ~DbtPlyTrigger(); 39 41 42 /// @todo Documentation 40 43 virtual ComponentBase::COMPONENT_CONFIGURATION configureComponent(XmlComponentConfig config); 41 44 45 /// @todo Documentation 42 46 virtual void run(); 43 47 44 48 Q_SIGNALS: 49 /// @todo Documentation 45 50 void triggerSig(); 46 51 47 52 protected: 53 /// @todo Documentation 48 54 virtual void startActivity(); 55 /// @todo Documentation 49 56 virtual void stopActivity(); 50 57 -
trunk/include/Pacpus/kernel/ComponentBase.h
r42 r61 90 90 */ 91 91 virtual COMPONENT_CONFIGURATION configureComponent(XmlComponentConfig config) = 0; 92 93 // The XML node that is got in the configureComponent method 92 93 protected: 94 /// The XML node that is got in the configureComponent method 94 95 XmlComponentConfig param; 95 96 96 // the name of the component. It is this one in the XML config file97 /// the name of the component. It is this one in the XML config file 97 98 QString componentName; 98 99 99 // is the component is recording data?100 /// is the component is recording data? 100 101 bool recording; 101 102 102 // provided for compatibility with old DBITE framework103 /// provided for compatibility with old DBITE framework 103 104 bool THREAD_ALIVE; 104 105 105 // is the component active?106 /// is the component active? 106 107 bool mIsActive; 107 108 108 // a pointer to the manager of components109 /// a pointer to the manager of components 109 110 ComponentManager * mgr; 110 111 111 112 private: 112 // called by the ComponentManager to start the component113 /// called by the ComponentManager to start the component 113 114 int startComponent(); 114 115 115 // called by the ComponentManager to stop the component116 /// called by the ComponentManager to stop the component 116 117 int stopComponent(); 117 118 118 // store the state of the component119 /// store the state of the component 119 120 COMPONENT_STATE componentState_; 120 121 121 // is the component configured (ie configureComponent method was called)122 /// is the component configured (ie configureComponent method was called) 122 123 COMPONENT_CONFIGURATION configuration_; 123 124 }; -
trunk/include/Pacpus/kernel/DbiteFile.h
r59 r61 23 23 namespace pacpus { 24 24 25 /// @todo Documentation 25 26 struct FILELIB_API VariableDataSizeTag {}; 26 27 FILELIB_API extern VariableDataSizeTag VariableDataSize; 27 28 29 /// @todo Documentation 28 30 struct FILELIB_API ReadModeTag {}; 29 31 FILELIB_API extern ReadModeTag ReadMode; 30 32 33 /// @todo Documentation 31 34 struct FILELIB_API WriteModeTag {}; 32 35 FILELIB_API extern WriteModeTag WriteMode; 33 36 37 /// @todo Documentation 34 38 struct FILELIB_API DiagnoseModeTag {}; 35 39 FILELIB_API extern DiagnoseModeTag DiagnoseMode; 36 40 41 /// @todo Documentation 37 42 class FILELIB_API DbiteFile 38 43 { -
trunk/include/Pacpus/kernel/hdfile_header_t.h
r32 r61 19 19 20 20 #pragma pack(push,4) 21 /// @todo Documentation 21 22 struct hdfile_header_t 22 23 { 24 /// @todo Documentation 23 25 typedef int8_t SignatureT; 26 /// @todo Documentation 24 27 typedef int32_t DataTypeT; 28 /// @todo Documentation 25 29 typedef int32_t VersionT; 30 /// @todo Documentation 26 31 typedef int32_t DataSizeT; 32 /// @todo Documentation 27 33 typedef int32_t DataOffsetT; 28 // FIXME: file size should be 64-bit long to support large (>2GB) files 34 /// @todo Documentation 35 /// @todo FIXME: file size should be 64-bit long to support large (>2GB) files 29 36 typedef int32_t FileSizeT; 37 /// @todo Documentation 30 38 typedef int32_t RecordCountT; 31 39 40 /// @todo Documentation 32 41 static const DataSizeT kVariableRecordSize = -1; 33 42 43 /// @todo Documentation 34 44 SignatureT Signature[HEADER_SIGNATURE_LENGTH]; 35 DataTypeT Type; /* IMAGE, CAN, UNKNOWN, etc. */ 45 /// Record data type 46 /// Should default to @link FILE_DBT_UNKNOWN 47 /// @see DbiteFileTypes.h for more 48 DataTypeT Type; 49 /// File format version 36 50 VersionT VersionNumber; 37 DataOffsetT DataOffset; /* starting of the data */ 38 DataSizeT DataSize; /* number of byte for data */ 39 FileSizeT FileSize; /* current size of the file */ 40 road_time_t TimeMin, TimeMax; 41 RecordCountT NbRecords; /* number of records */ 51 /// Offset indicating the start of the data [bytes] 52 DataOffsetT DataOffset; 53 /// Current size of the data, without header [bytes] 54 DataSizeT DataSize; 55 /// Current size of the file [bytes] 56 FileSizeT FileSize; 57 /// @todo Documentation 58 road_time_t TimeMin; 59 /// @todo Documentation 60 road_time_t TimeMax; 61 /// Number of records already in the file 62 RecordCountT NbRecords; 42 63 }; 43 64 #pragma pack(pop) -
trunk/src/PacpusSensor/src/main.cpp
r31 r61 17 17 #ifdef WIN32 18 18 # include <windows.h> 19 # include <mmsystem.h>20 19 #endif 21 20 -
trunk/src/PacpusSensor/src/ui/pacpusmainwindow.cpp
r32 r61 27 27 28 28 ////////////////////////////////////////////////////////////////////////// 29 /// Constructor30 29 PacpusMainWindow::PacpusMainWindow(QWidget * parent) 31 30 : QDialog(parent) … … 63 62 64 63 ////////////////////////////////////////////////////////////////////////// 65 /// Destructor66 64 PacpusMainWindow::~PacpusMainWindow() 67 65 { … … 70 68 71 69 ////////////////////////////////////////////////////////////////////////// 72 /// slot73 /// Starts all the components and checks all the checkbox74 70 void PacpusMainWindow::startAcquisition() 75 71 { … … 80 76 81 77 ////////////////////////////////////////////////////////////////////////// 82 /// slot83 /// Stops all the components and unchecks all the checkbox84 78 void PacpusMainWindow::stopAcquisition() 85 79 { … … 89 83 } 90 84 91 //////////////////////////////////////////////////////////////////////////92 // slot93 // called when a checkbox is checked94 // start the corresponding component95 // start the monitoring loop if not running96 85 ////////////////////////////////////////////////////////////////////////// 97 86 void PacpusMainWindow::startComponent(QString component) … … 114 103 115 104 ////////////////////////////////////////////////////////////////////////// 116 /// slot117 /// called when a checkbox is unchecked118 /// stop the corresponding component119 /// eventually stop the monitoring loop if any other component is active120 105 void PacpusMainWindow::stopComponent(QString component) 121 106 { … … 145 130 ////////////////////////////////////////////////////////////////////////// 146 131 147 // Voir si besoin de faire un thread : un timer est peut être suffisant ??132 /// @todo Voir si besoin de faire un thread : un timer est peut être suffisant ?? 148 133 void PacpusMainWindow::monitoring() 149 134 { -
trunk/src/PacpusSensor/src/ui/pacpusmainwindow.h
r32 r61 33 33 34 34 public: 35 /// @todo Documentation 35 36 ComponentCheckBox(const QString & text, QWidget * parent, const char * /*name*/ = 0 ) 36 37 : QCheckBox(text, parent) … … 40 41 } 41 42 43 /// @todo Documentation 42 44 ~ComponentCheckBox() 43 45 { … … 45 47 46 48 public Q_SLOTS: 49 /// @todo Documentation 47 50 void change(bool state) 48 51 { … … 55 58 56 59 Q_SIGNALS: 60 /// @todo Documentation 57 61 void activate(QString); 62 /// @todo Documentation 58 63 void deactivate(QString); 59 64 }; 60 65 61 66 //////////////////////////////////////////////////////////////////////////////// 67 /// @todo Documentation 62 68 class PacpusMainWindow 63 69 : public QDialog … … 67 73 68 74 public: 75 /// Constructor 69 76 PacpusMainWindow(QWidget * parent = 0); 77 /// Destructor 70 78 ~PacpusMainWindow(); 71 79 72 80 public Q_SLOTS: 81 /// slot 82 /// Starts all the components and checks all the checkbox 73 83 void startAcquisition(); 84 /// slot 85 /// called when a checkbox is checked 86 /// start the corresponding component 87 /// start the monitoring loop if not running 74 88 void startComponent(QString component); 75 89 90 /// slot 91 /// Stops all the components and unchecks all the checkbox 76 92 void stopAcquisition(); 93 /// slot 94 /// called when a checkbox is unchecked 95 /// stop the corresponding component 96 /// eventually stop the monitoring loop if any other component is active 77 97 void stopComponent(QString component); 78 98 99 /// @todo Documentation 79 100 void monitoring(); 80 101
Note:
See TracChangeset
for help on using the changeset viewer.