Changeset 66 in pacpussensors for trunk/Alasca/AlascaComponent.cpp
- Timestamp:
- Sep 25, 2014, 4:35:35 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Alasca/AlascaComponent.cpp
r2 r66 53 53 pendingBytes.time = 0; 54 54 pendingBytes.previousData = false; 55 recording = false;55 setRecording(false); 56 56 // default values 57 57 host_ = "172.17.130.205"; … … 74 74 //generator = new AlascaDataGenerator(this); 75 75 A_socket->connectToServer(host_, port_); 76 if (recording) {76 if (isRecording()) { 77 77 try { 78 78 dbtFile_.open(kAlaskaDbtFileName, WriteMode, ALASCA_XT, sizeof(AlascaXT)); … … 106 106 { 107 107 A_socket->closeSocket(); 108 if ( recording) {108 if (isRecording()) { 109 109 dbtFile_.close(); 110 110 dataFile_.close(); … … 119 119 ComponentBase::COMPONENT_CONFIGURATION AlascaComponent::configureComponent(XmlComponentConfig config) 120 120 { 121 if ( param.getProperty("recording") != QString::null)122 recording = param.getProperty("recording").toInt();123 if ( param.getProperty("alascaIP") != QString::null)124 host_ = param.getProperty("alascaIP");125 if ( param.getProperty("alascaPort") != QString::null)126 port_ = param.getProperty("alascaPort").toInt();121 if (config.getProperty("recording") != QString::null) 122 setRecording ( config.getProperty("recording").toInt() ); 123 if (config.getProperty("alascaIP") != QString::null) 124 host_ = config.getProperty("alascaIP"); 125 if (config.getProperty("alascaPort") != QString::null) 126 port_ = config.getProperty("alascaPort").toInt(); 127 127 128 128 return ComponentBase::CONFIGURED_OK; … … 489 489 setState(ComponentBase::MONITOR_OK); 490 490 // write data on the disk 491 if ( recording) writeData();491 if (isRecording()) writeData(); 492 492 // push data in shared memory 493 493 shmem_->write(&alascaData, sizeof(alascaData));
Note:
See TracChangeset
for help on using the changeset viewer.