Skip to content
Snippets Groups Projects
Commit aed850a2 authored by Joan Vallvé Navarro's avatar Joan Vallvé Navarro
Browse files

New pntpos output

parent ab68e1c5
No related branches found
No related tags found
2 merge requests!20new tag,!19new tag
This commit is part of merge request !20. Comments created here will be created in the context of that merge request.
......@@ -42,7 +42,8 @@ struct ComputePosOutput
double age; // age of differential (s)
double ratio; // AR ratio factor for valiation
int pos_stat; // return from pntpos 1:ok,0:error
bool success; // return from pntpos true/false
std::string msg; // message returned (in case of error)
Eigen::Vector3d lat_lon; // latitude_longitude_altitude
std::map<int,Eigen::Vector2d> sat_azel; // azimuth and elevation of each satellite provided
......
......@@ -36,19 +36,17 @@ ComputePosOutput computePos(const GnssUtils::Observations& _observations,
std::vector<double> sat_elevations(2 * _observations.size());
// compute pose
output.pos_stat = pntpos(_observations.data(),
_observations.size(),
&(_navigation.getNavigation()),
&_prcopt,
&sol,
sat_elevations.data(),
sats_status,
msg);
output.success = pntpos(_observations.data(),
_observations.size(),
&(_navigation.getNavigation()),
&_prcopt,
&sol,
sat_elevations.data(),
sats_status,
msg);
// Fill output struct
if (output.pos_stat == 0)
std::cout << "computePos: error in computing positioning, message: " << msg << "\n";
output.msg = std::string(msg);
output.time = sol.time.time;
output.sec = sol.time.sec;
output.pos = Eigen::Vector3d(sol.rr);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment