Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
d06c1906
Commit
d06c1906
authored
Aug 14, 2015
by
dogmaphobic
Browse files
Fixing Windows warnings.
parent
a656c246
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/uas/UAS.cc
View file @
d06c1906
...
...
@@ -149,19 +149,19 @@ UAS::UAS(MAVLinkProtocol* protocol, int id) : UASInterface(),
// Initialize HIL sensor noise variances to 0. If user wants corrupted sensor values they will need to set them
// Note variances calculated from flight case from this log: http://dash.oznet.ch/view/MRjW8NUNYQSuSZkbn8dEjY
// TODO: calibrate stand-still pixhawk variances
xacc_var
(
1.2914
),
yacc_var
(
0.7048
),
zacc_var
(
1.9577
),
rollspeed_var
(
0.8126
),
pitchspeed_var
(
0.6145
),
yawspeed_var
(
0.5852
),
xmag_var
(
0.4786
),
ymag_var
(
0.4566
),
zmag_var
(
0.3333
),
abs_pressure_var
(
1.1604
),
diff_pressure_var
(
1.1604
),
pressure_alt_var
(
1.1604
),
temperature_var
(
1.4290
),
xacc_var
(
1.2914
f
),
yacc_var
(
0.7048
f
),
zacc_var
(
1.9577
f
),
rollspeed_var
(
0.8126
f
),
pitchspeed_var
(
0.6145
f
),
yawspeed_var
(
0.5852
f
),
xmag_var
(
0.4786
f
),
ymag_var
(
0.4566
f
),
zmag_var
(
0.3333
f
),
abs_pressure_var
(
1.1604
f
),
diff_pressure_var
(
1.1604
f
),
pressure_alt_var
(
1.1604
f
),
temperature_var
(
1.4290
f
),
#ifndef __mobile__
simulation
(
0
),
...
...
@@ -3005,7 +3005,7 @@ float UAS::addZeroMeanNoise(float truth_meas, float noise_var)
/* Calculate normally distributed variable noise with mean = 0 and variance = noise_var. Calculated according to
Box-Muller transform */
static
const
float
epsilon
=
std
::
numeric_limits
<
float
>::
min
();
//used to ensure non-zero uniform numbers
static
const
float
two_pi
=
2.0
*
3.14159265358979323846
;
// 2*pi
static
const
float
two_pi
=
2.0
f
*
3.14159265358979323846
f
;
// 2*pi
static
float
z0
;
//calculated normal distribution random variables with mu = 0, var = 1;
float
u1
,
u2
;
//random variables generated from c++ rand();
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment