Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Instrument Control
NomadSpecialModules
Commits
ceec876a
Commit
ceec876a
authored
Feb 17, 2017
by
yannick legoc
Browse files
Added sleepTimeMS to remote dpp live process controllers.
parent
ee64cc8d
Changes
6
Hide whitespace changes
Inline
Side-by-side
src/controllers/remotenpp/RemoteDPPCoincidence.cpp
View file @
ceec876a
...
...
@@ -45,7 +45,6 @@ RemoteDPPCoincidence::RemoteDPPCoincidence(const std::string& name) :
detectorChannel
.
init
(
this
,
SAVE
,
"detector_channel"
);
coincidenceResolution
.
init
(
this
,
SAVE
,
"coincidence_resolution"
);
maxBlock
.
init
(
this
,
SAVE
,
"max_block"
);
refreshTimeS
.
init
(
this
,
SAVE
,
"refresh_time_s"
);
totalNumberOfChannels
.
init
(
this
,
NOSAVE
,
"total_number_of_channels"
);
nOrder
.
init
(
this
,
NOSAVE
,
"n_order"
);
...
...
src/controllers/remotenpp/RemoteDPPCoincidence.h
View file @
ceec876a
...
...
@@ -54,7 +54,6 @@ private:
DynamicProperty
<
int32
>
detectorChannel
;
Property
<
int32
>
coincidenceResolution
;
Property
<
int32
>
maxBlock
;
Property
<
int32
>
refreshTimeS
;
Property
<
int32
>
totalNumberOfChannels
;
...
...
src/controllers/remotenpp/RemoteDPPHistogram.cpp
View file @
ceec876a
...
...
@@ -44,7 +44,6 @@ RemoteDPPHistogram::RemoteDPPHistogram(const std::string& name) :
delay
.
init
(
this
,
SAVE
,
"delay"
);
dT
.
init
(
this
,
SAVE
,
"dT"
);
maxBlock
.
init
(
this
,
SAVE
,
"max_block"
);
refreshTimeS
.
init
(
this
,
SAVE
,
"refresh_time_s"
);
totalNumberOfChannels
.
init
(
this
,
NOSAVE
,
"total_number_of_channels"
);
crateId
.
init
(
this
,
NOSAVE
,
"crate_id"
);
...
...
src/controllers/remotenpp/RemoteDPPHistogram.h
View file @
ceec876a
...
...
@@ -53,7 +53,6 @@ private:
Property
<
int32
>
delay
;
Property
<
int32
>
dT
;
Property
<
int32
>
maxBlock
;
Property
<
int32
>
refreshTimeS
;
Property
<
int32
>
totalNumberOfChannels
;
...
...
src/controllers/remotenpp/RemoteDPPLiveProcess.cpp
View file @
ceec876a
...
...
@@ -39,6 +39,8 @@ RemoteDPPLiveProcess::RemoteDPPLiveProcess(const std::string& name) :
blockSize
.
init
(
this
,
SAVE
,
"block_size"
);
mode
.
init
(
this
,
SAVE
,
"mode"
);
testFileName
.
init
(
this
,
SAVE
,
"test_file_name"
);
refreshTimeS
.
init
(
this
,
SAVE
,
"refresh_time_s"
);
sleepTimeMS
.
init
(
this
,
SAVE
,
"sleep_time_ms"
);
}
RemoteDPPLiveProcess
::
RemoteDPPLiveProcess
(
const
RemoteDPPLiveProcess
&
controller
)
:
...
...
@@ -123,16 +125,16 @@ void RemoteDPPLiveProcess::fileReadingLoop() {
// Send the data
m_publisher
->
sendBinary
(
data
);
//
s
leep
(refreshTimeS());
usleep
(
10000
);
//
S
leep
for milliseconds.
boost
::
this_thread
::
sleep
(
boost
::
posix_time
::
milliseconds
(
sleepTimeMS
())
);
}
cout
<<
"controller has stopped"
<<
endl
;
m_publisher
->
sendEnd
();
cout
<<
"finished reading file"
<<
endl
;
}
}
std
::
auto_ptr
<
boost
::
thread
>
RemoteDPPLiveProcess
::
startFileReading
()
{
...
...
src/controllers/remotenpp/RemoteDPPLiveProcess.h
View file @
ceec876a
...
...
@@ -51,6 +51,8 @@ protected:
Property
<
int32
>
blockSize
;
Property
<
std
::
string
>
mode
;
Property
<
std
::
string
>
testFileName
;
Property
<
int32
>
refreshTimeS
;
Property
<
int32
>
sleepTimeMS
;
std
::
auto_ptr
<
cameo
::
Server
>
m_server
;
std
::
auto_ptr
<
cameo
::
application
::
Publisher
>
m_publisher
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment