Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Achim Morschhauser
GeomagLogger
Commits
c7fd6705
Commit
c7fd6705
authored
Oct 26, 2020
by
Achim Morschhauser
Browse files
Add supplementary channel scale values and offsets
parent
486e4d33
Changes
2
Hide whitespace changes
Inline
Side-by-side
usr/par/parameters_default.par
View file @
c7fd6705
...
...
@@ -41,6 +41,13 @@ X_s=1.0
Y_s=1.0
Z_s=1.0
# Scale values of supplementary channel
S3_s=0.1
S4_s=0.1
# Offsets values of supplementary channel
S3_o=-273.15
S4_o=-273.15
# Recording frequency [Hz]
FREQ_VEC=3
...
...
usr/src/OBSDAQ_Logger.cpp
View file @
c7fd6705
...
...
@@ -61,16 +61,20 @@ int main(int argc, char* argv[]) {
// Set the calibration constants.
// Will be done in driver_obs_obsdaq constructor in future, and parameter
// file will be given as argument to constructor
double
R
,
X_s
,
Y_s
,
Z_s
,
T
1_s
,
T
2_s
;
double
R
,
X_s
,
Y_s
,
Z_s
,
S
1_s
,
S
2_s
,
S3_s
,
S1_o
,
S2_o
,
S3_o
;
R
=
par
.
get_dbl
(
"R"
,
1.0
);
X_s
=
par
.
get_dbl
(
"X_s"
,
1.0
);
Y_s
=
par
.
get_dbl
(
"Y_s"
,
1.0
);
Z_s
=
par
.
get_dbl
(
"Z_s"
,
1.0
);
T1_s
=
par
.
get_dbl
(
"T1_s"
,
1.0
);
T2_s
=
par
.
get_dbl
(
"T2_s"
,
1.0
);
S1_s
=
par
.
get_dbl
(
"S1_s"
,
1.0
);
S1_o
=
par
.
get_dbl
(
"S1_o"
,
0.0
);
S2_s
=
par
.
get_dbl
(
"S2_s"
,
1.0
);
S2_o
=
par
.
get_dbl
(
"S2_o"
,
0.0
);
S3_s
=
par
.
get_dbl
(
"S3_s"
,
1.0
);
S3_o
=
par
.
get_dbl
(
"S3_o"
,
0.0
);
std
::
cout
<<
"R: "
<<
R
<<
" X_s: "
<<
X_s
<<
std
::
endl
;
std
::
vector
<
double
>
offset
;
offset
.
assign
(
8
,
0
)
;
std
::
vector
<
double
>
scale
=
{
X_s
/
R
,
Y_s
/
R
,
Z_s
/
R
,
T1_s
,
T2_s
,
1.0
,
1.0
,
1.0
};
std
::
vector
<
double
>
offset
=
{
0.0
,
0.0
,
0.0
,
0.0
,
0.0
,
S1_o
,
S2_o
,
S3_o
}
;
std
::
vector
<
double
>
scale
=
{
X_s
/
R
,
Y_s
/
R
,
Z_s
/
R
,
1.0
,
1.0
,
S1_s
,
S2_s
,
S3_s
};
// Add standard pipe buffer to multi buffer
buffer_obs_mult
mult
=
new
buffer_obs_mult
(
new
buffer_obs_pipe
(
5
));
...
...
Write
Preview
Supports
Markdown
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