From ccea43902808717c81facef188872abebae0a290 Mon Sep 17 00:00:00 2001 From: Sylvain Munaut Date: Mon, 28 Dec 2009 14:51:08 +0100 Subject: rrlp-ephemeris: Fill ref pos with UBX NAV_POSLLH messages Signed-off-by: Sylvain Munaut --- rrlp-ephemeris/ubx-parse.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rrlp-ephemeris/ubx-parse.c b/rrlp-ephemeris/ubx-parse.c index cb8c22e83..60bc05763 100644 --- a/rrlp-ephemeris/ubx-parse.c +++ b/rrlp-ephemeris/ubx-parse.c @@ -69,7 +69,11 @@ _ubx_msg_parse_nav_posllh(struct ubx_hdr *hdr, void *pl, int pl_len, void *ud) //printf("[.] NAV_POSLLH\n"); - // FIXME: Extract info for "Reference Position" + gps->fields |= GPS_FIELD_REFPOS; + + gps->ref_pos.latitude = (double)(nav_posllh->lat) * 1e-7; + gps->ref_pos.longitude = (double)(nav_posllh->lon) * 1e-7; + gps->ref_pos.altitude = (double)(nav_posllh->height) * 1e-3; } static void -- cgit v1.2.3