Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
ControlSystemAdapter-DoocsAdapter
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ChimeraTK Mirror
ControlSystemAdapter-DoocsAdapter
Commits
aa0bd46e
Commit
aa0bd46e
authored
5 years ago
by
Martin Christoph Hierholzer
Browse files
Options
Downloads
Patches
Plain Diff
bug fix: if data matching is disabled, do not send data twice
parent
d5a59a30
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/DoocsPVFactory.cc
+14
-6
14 additions, 6 deletions
src/DoocsPVFactory.cc
with
14 additions
and
6 deletions
src/DoocsPVFactory.cc
+
14
−
6
View file @
aa0bd46e
...
...
@@ -82,7 +82,9 @@ namespace ChimeraTK {
}
boost
::
dynamic_pointer_cast
<
DoocsProcessScalar
<
DOOCS_PRIMITIVE_T
,
DOOCS_T
>>
(
doocsPV
)
->
setMacroPulseNumberSource
(
mpnDecorated
);
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
if
(
propertyDescription
.
dataMatching
!=
DataConsistencyGroup
::
MatchingMode
::
none
)
{
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
}
}
// set data matching mode
...
...
@@ -110,8 +112,8 @@ namespace ChimeraTK {
assert
(
processArray
->
getNumberOfChannels
()
==
1
);
assert
(
processArray
->
getNumberOfSamples
()
==
1
);
// array of strings is not supported
boost
::
shared_ptr
<
D_fct
>
doocsPV
(
new
DoocsProcessScalar
<
std
::
string
,
D_textUnifier
>
(
_eqFct
,
propertyDescription
.
name
.
c_str
(),
processArray
,
_updater
));
boost
::
shared_ptr
<
D_fct
>
doocsPV
(
new
DoocsProcessScalar
<
std
::
string
,
D_textUnifier
>
(
_eqFct
,
propertyDescription
.
name
.
c_str
(),
processArray
,
_updater
));
// set read only mode if configures in the xml file or for output variables
if
(
!
processArray
->
isWriteable
()
||
!
propertyDescription
.
isWriteable
)
{
...
...
@@ -139,7 +141,9 @@ namespace ChimeraTK {
}
boost
::
dynamic_pointer_cast
<
DoocsProcessScalar
<
std
::
string
,
D_textUnifier
>>
(
doocsPV
)
->
setMacroPulseNumberSource
(
mpnDecorated
);
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
if
(
propertyDescription
.
dataMatching
!=
DataConsistencyGroup
::
MatchingMode
::
none
)
{
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
}
}
// set data matching mode
...
...
@@ -214,7 +218,9 @@ namespace ChimeraTK {
"' is used as a macro pulse number source, but it is not readable."
);
}
boost
::
dynamic_pointer_cast
<
DoocsSpectrum
>
(
doocsPV
)
->
setMacroPulseNumberSource
(
mpnDecorated
);
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
if
(
spectrumDescription
.
dataMatching
!=
DataConsistencyGroup
::
MatchingMode
::
none
)
{
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
}
}
// set data matching mode
...
...
@@ -414,7 +420,9 @@ boost::shared_ptr<D_fct> DoocsPVFactory::typedCreateDoocsArray(AutoPropertyDescr
}
boost
::
dynamic_pointer_cast
<
DoocsProcessArray
<
DOOCS_T
,
DOOCS_PRIMITIVE_T
>>
(
doocsPV
)
->
setMacroPulseNumberSource
(
mpnDecorated
);
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
if
(
propertyDescription
.
dataMatching
!=
DataConsistencyGroup
::
MatchingMode
::
none
)
{
_updater
.
addVariable
(
ChimeraTK
::
ScalarRegisterAccessor
<
int64_t
>
(
mpnDecorated
),
_eqFct
,
[]
{});
}
}
// set data matching mode
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment