Skip to content

Commit 0ba0e9e

Browse files
authored
ReadoutCard API change (#25)
* fix because of incompatible API change in ReadoutCard v0.9.1
1 parent e094249 commit 0ba0e9e

File tree

3 files changed

+8
-14
lines changed

3 files changed

+8
-14
lines changed

CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,4 +180,9 @@ install(
180180
FILES readout.cfg
181181
DESTINATION ${CMAKE_INSTALL_PREFIX}/etc
182182
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
183+
184+
install(
185+
FILES src/RAWDataHeader.h
186+
DESTINATION ${CMAKE_INSTALL_PREFIX}/include/${MODULE_NAME}
187+
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
183188

src/ReadoutEquipmentRORC.cxx

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#include <ReadoutCard/MemoryMappedFile.h>
66
#include <ReadoutCard/DmaChannelInterface.h>
77
#include <ReadoutCard/Exception.h>
8-
#include <ReadoutCard/Driver.h>
8+
99

1010
#include <string>
1111
#include <mutex>
@@ -66,8 +66,8 @@ class ReadoutEquipmentRORC : public ReadoutEquipment {
6666
};
6767

6868

69-
std::mutex readoutEquipmentRORCLock;
70-
bool isDriverInitialized=false;
69+
//std::mutex readoutEquipmentRORCLock;
70+
7171

7272

7373
struct ReadoutEquipmentRORCException : virtual Exception {};
@@ -133,14 +133,6 @@ ReadoutEquipmentRORC::ReadoutEquipmentRORC(ConfigFile &cfg, std::string name) :
133133
BOOST_THROW_EXCEPTION(ReadoutEquipmentRORCException() << ErrorInfo::Message("Superpage must be at least 32kB"));
134134
}
135135

136-
// make sure ROC driver is initialized once
137-
readoutEquipmentRORCLock.lock();
138-
if (!isDriverInitialized) {
139-
AliceO2::roc::driver::initialize();
140-
isDriverInitialized=true;
141-
}
142-
readoutEquipmentRORCLock.unlock();
143-
144136
// open and configure ROC
145137
theLog.log("Opening ROC %s:%d",cardId.c_str(),cfgChannelNumber);
146138
AliceO2::roc::Parameters params;

src/testROC.cxx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ InfoLogger theLog;
1212
#include <ReadoutCard/MemoryMappedFile.h>
1313
#include <ReadoutCard/DmaChannelInterface.h>
1414
#include <ReadoutCard/Exception.h>
15-
#include <ReadoutCard/Driver.h>
1615

1716
#include <vector>
1817
#include <time.h>
@@ -257,8 +256,6 @@ int main(int argc, char**argv) {
257256

258257

259258

260-
AliceO2::roc::driver::initialize();
261-
262259
std::vector<ROCdevice> devices;
263260

264261
for (int i=argMin;i<argc;i++) {

0 commit comments

Comments
 (0)