Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
wolf_ros_gnss
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor 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
mobile_robotics
wolf_projects
wolf_ros
wolf_ros_gnss
Commits
696c9922
Commit
696c9922
authored
4 years ago
by
Joan Vallvé Navarro
Browse files
Options
Downloads
Patches
Plain Diff
bug fixed
parent
0d4bcf64
No related branches found
No related tags found
2 merge requests
!3
After cmake and const refactor
,
!1
new release
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/subscriber_gnss_receiver.cpp
+26
-21
26 additions, 21 deletions
src/subscriber_gnss_receiver.cpp
with
26 additions
and
21 deletions
src/subscriber_gnss_receiver.cpp
+
26
−
21
View file @
696c9922
...
...
@@ -18,15 +18,15 @@ SubscriberGnssReceiver::SubscriberGnssReceiver(const std::string& _unique_name,
publish_fix_
=
_server
.
getParam
<
bool
>
(
prefix_
+
"/publish_fix/enabled"
);
if
(
publish_fix_
)
{
// comparation of GNSS options
comp_options_
.
push_back
(
"000"
);
comp_options_
.
push_back
(
"001"
);
// comparation of GNSS options
RAIM-SBAS-IONO
//
comp_options_.push_back("000");
//
comp_options_.push_back("001");
comp_options_
.
push_back
(
"010"
);
comp_options_
.
push_back
(
"011"
);
comp_options_
.
push_back
(
"100"
);
comp_options_
.
push_back
(
"101"
);
comp_options_
.
push_back
(
"110"
);
comp_options_
.
push_back
(
"111"
);
//
comp_options_.push_back("011");
//
comp_options_.push_back("100");
//
comp_options_.push_back("101");
//
comp_options_.push_back("110");
//
comp_options_.push_back("111");
// params
pose_
=
_server
.
getParam
<
bool
>
(
prefix_
+
"/publish_fix/pose_msg"
);
...
...
@@ -160,9 +160,11 @@ void SubscriberGnssReceiver::createCaptureAndProcess()
// compute fix if publishing or not sats_available
if
(
not
sats_available_
or
publish_fix_
)
{
fix
=
GnssUtils
::
computePos
(
receiver_
->
getObservations
(),
receiver_
->
getNavigation
(),
compute_pos_opt_
);
}
// if (last time) satellites were not available: check if they are
if
(
not
sats_available_
)
...
...
@@ -211,42 +213,45 @@ void SubscriberGnssReceiver::publishFixComp()
if
(
not
ENU_defined_
and
not
listenTf
())
return
;
GnssUtils
::
Options
comp_pos_opt
=
compute_pos_opt_
;
for
(
auto
comp
:
comp_options_
)
{
// RAIM
if
(
comp
[
0
]
==
'0'
)
comp
ute
_pos_opt
_
.
raim
=
0
;
comp_pos_opt
.
raim
=
0
;
else
comp
ute
_pos_opt
_
.
raim
=
1
;
comp_pos_opt
.
raim
=
1
;
// SBAS
if
(
comp
[
1
]
==
'0'
)
{
comp
ute
_pos_opt
_
.
sateph
=
0
;
//eph broadcasted
comp
ute
_pos_opt
_
.
ionoopt
=
1
;
//iono broadcasted
comp
ute
_pos_opt
_
.
tropopt
=
1
;
//trop broadcasted
comp
ute
_pos_opt
_
.
sbascorr
=
0
;
//sbas corrections
comp_pos_opt
.
sateph
=
0
;
//eph broadcasted
comp_pos_opt
.
ionoopt
=
1
;
//iono broadcasted
comp_pos_opt
.
tropopt
=
1
;
//trop broadcasted
comp_pos_opt
.
sbascorr
=
0
;
//sbas corrections
}
else
{
compute_pos_opt_
.
sateph
=
2
;
//eph sbas
compute_pos_opt_
.
ionoopt
=
2
;
//iono sbas
compute_pos_opt_
.
tropopt
=
2
;
//trop broadcasted
compute_pos_opt_
.
sbascorr
=
15
;
//sbas corrections
comp_pos_opt
.
GAL
=
false
;
comp_pos_opt
.
sateph
=
2
;
//eph sbas
comp_pos_opt
.
ionoopt
=
0
;
//2; //iono sbas
comp_pos_opt
.
tropopt
=
0
;
//2; //trop broadcasted
comp_pos_opt
.
sbascorr
=
15
;
//sbas corrections
}
// IONOFREE combination
if
(
comp
[
2
]
==
'1'
)
{
comp
ute
_pos_opt
_
.
ionoopt
=
3
;
//iono-free combination
comp_pos_opt
.
ionoopt
=
3
;
//iono-free combination
if
(
comp
[
1
]
==
'1'
)
comp
ute
_pos_opt
_
.
sbascorr
=
11
;
//sbas corrections without iono
comp_pos_opt
.
sbascorr
=
11
;
//sbas corrections without iono
}
//std::cout << "//////////// Computing fix comp = " << comp << std::endl;
auto
fix
=
GnssUtils
::
computePos
(
receiver_
->
getObservations
(),
receiver_
->
getNavigation
(),
comp
ute
_pos_opt
_
);
comp_pos_opt
);
WOLF_INFO_COND
(
comp
==
"010"
and
not
fix
.
success
,
"computePos failed with msg: "
,
fix
.
msg
);
//std::cout << "//////////// Computed" << std::endl;
...
...
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