diff options
author | Michael Dickens <michael.dickens@ettus.com> | 2019-07-23 13:57:31 -0400 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2019-07-23 15:12:57 -0700 |
commit | 8b294082d4804198c45b0acb1ad6393e4f6ef0da (patch) | |
tree | 207eaeadba607056c028e08306512a7caa9905e5 /host | |
parent | 7ecb72180728756efda3566a8a7b25e36c690ee7 (diff) | |
download | uhd-8b294082d4804198c45b0acb1ad6393e4f6ef0da.tar.gz uhd-8b294082d4804198c45b0acb1ad6393e4f6ef0da.tar.bz2 uhd-8b294082d4804198c45b0acb1ad6393e4f6ef0da.zip |
gpsd: Fix gpsdata API: .separation -> .fix.geoid_sep
See: https://gitlab.com/gpsd/gpsd/commit/c711d531a6faab93df68ec625a076631569a729d
Diffstat (limited to 'host')
-rw-r--r-- | host/lib/usrp/gpsd_iface.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/host/lib/usrp/gpsd_iface.cpp b/host/lib/usrp/gpsd_iface.cpp index c6b75c83d..ab9ae4163 100644 --- a/host/lib/usrp/gpsd_iface.cpp +++ b/host/lib/usrp/gpsd_iface.cpp @@ -265,11 +265,19 @@ private: // member functions string.append( str(boost::format("%.2f,M,") % _gps_data.fix.altitude)); +#if GPSD_API_MAJOR_VERSION < 9 if (boost::math::isnan(_gps_data.separation)) string.append(",,"); else string.append( str(boost::format("%.3f,M,") % _gps_data.separation)); +#else + if (boost::math::isnan(_gps_data.fix.geoid_sep)) + string.append(",,"); + else + string.append( + str(boost::format("%.3f,M,") % _gps_data.fix.geoid_sep)); +#endif if (boost::math::isnan(mag_var)) string.append(","); |