Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. QPositioning horizontal accuracy missing
Qt 6.11 is out! See what's new in the release blog

QPositioning horizontal accuracy missing

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
3 Posts 3 Posters 1.0k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • W Offline
    W Offline
    wouter_inspiro
    wrote on last edited by
    #1

    I use the QPositioning library to parse the incoming NMEA sentences from our serial GPS receiver. The coordinates are returned correctly but the horizontal accuracy is not returned. The horizontal accuracy attribute should be present int the QGeoPositionInfo object according to the function:

    info.hasAttribute(QGeoPositionInfo::Attribute::HorizontalAccuracy)
    

    But reading the attribute returns a nan.

    The serial port is read using the serialnmea plugin connected to a handling funtion using:

    m_pPositionSource = QGeoPositionInfoSource::createSource("serialnmea", params, this);
    connect(m_pPositionSource, &QGeoPositionInfoSource::positionUpdated, this, &CGPS::HandleGPSRead);
    m_pPositionSource->startUpdates();
    

    The inputted nmea data is as follows:

    $GPRMC,135910.00,A,<lat>,N,<long>,E,0.062,,161220,,,A*76
    $GPVTG,,T,,M,0.062,N,0.116,K,A*21
    $GPGGA,135910.00,<lat>,N,<long>,E,1,08,1.08,7.5,M,46.1,M,,*58
    $GPGSA,A,3,13,28,15,14,30,05,24,08,,,,,1.66,1.08,1.26*0E
    $GPGSV,4,1,13,05,21,194,40,08,06,018,31,10,00,336,,13,81,131,47*79
    $GPGSV,4,2,13,14,52,075,46,15,59,288,46,17,08,124,,18,06,284,*7F
    $GPGSV,4,3,13,20,22,313,,23,22,317,,24,25,259,26,28,57,088,42*7E
    $GPGSV,4,4,13,30,27,074,42*48
    $GPGLL,<lat>,N,<long>,E,135910.00,A,A*6D
    

    If both the GPGGA and GPGSA messages contain the Horizontal Dilution of Precision (HDOP) describing the accuracy of the GPS location. However as described above the QPositioning library doesn't output the horizontal accuracy.

    My questions are:

    • What NMEA messages are used in determining the horizontal accuracy?
    • How can I get the horizontal accuracy out of the library?

    I use QT 5.15.1 and running on Debian 10.3

    J 1 Reply Last reply
    0
    • W wouter_inspiro

      I use the QPositioning library to parse the incoming NMEA sentences from our serial GPS receiver. The coordinates are returned correctly but the horizontal accuracy is not returned. The horizontal accuracy attribute should be present int the QGeoPositionInfo object according to the function:

      info.hasAttribute(QGeoPositionInfo::Attribute::HorizontalAccuracy)
      

      But reading the attribute returns a nan.

      The serial port is read using the serialnmea plugin connected to a handling funtion using:

      m_pPositionSource = QGeoPositionInfoSource::createSource("serialnmea", params, this);
      connect(m_pPositionSource, &QGeoPositionInfoSource::positionUpdated, this, &CGPS::HandleGPSRead);
      m_pPositionSource->startUpdates();
      

      The inputted nmea data is as follows:

      $GPRMC,135910.00,A,<lat>,N,<long>,E,0.062,,161220,,,A*76
      $GPVTG,,T,,M,0.062,N,0.116,K,A*21
      $GPGGA,135910.00,<lat>,N,<long>,E,1,08,1.08,7.5,M,46.1,M,,*58
      $GPGSA,A,3,13,28,15,14,30,05,24,08,,,,,1.66,1.08,1.26*0E
      $GPGSV,4,1,13,05,21,194,40,08,06,018,31,10,00,336,,13,81,131,47*79
      $GPGSV,4,2,13,14,52,075,46,15,59,288,46,17,08,124,,18,06,284,*7F
      $GPGSV,4,3,13,20,22,313,,23,22,317,,24,25,259,26,28,57,088,42*7E
      $GPGSV,4,4,13,30,27,074,42*48
      $GPGLL,<lat>,N,<long>,E,135910.00,A,A*6D
      

      If both the GPGGA and GPGSA messages contain the Horizontal Dilution of Precision (HDOP) describing the accuracy of the GPS location. However as described above the QPositioning library doesn't output the horizontal accuracy.

      My questions are:

      • What NMEA messages are used in determining the horizontal accuracy?
      • How can I get the horizontal accuracy out of the library?

      I use QT 5.15.1 and running on Debian 10.3

      J Offline
      J Offline
      jsmith883
      wrote on last edited by
      #2

      @wouter_inspiro , I've noticed the same thing. Did you happen to resolve the missing Horizontal Accuracy?

      1 Reply Last reply
      0
      • I Offline
        I Offline
        ivan.solovev
        wrote on last edited by
        #3

        Hi. According to the docs you need to set the user equivalent range error.
        Some details here:
        https://doc.qt.io/qt-5/qnmeapositioninfosource.html#setUserEquivalentRangeError
        https://doc.qt.io/qt-5/qnmeapositioninfosource.html#userEquivalentRangeError

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved