Speed up GPS Location

  • Hi,

    I'm developing a mobile application which requires GPS coordinates. I've tried to use this class : http://doc.qt.io/qt-5/qml-qtpositioning-positionsource.html but it takes ages to update (more precisely 2 minutes).

    I find it very long and I wondered if there was a way to fasten the process.


  • Hi! You can set the updateInterval property to customize the frequency.

  • I used once QtPositioning QtPositioning but its update interval is minimum 1 second and that wasn't suitable for my application.
    Then I found this repo and I made a simpler version of this library to connect with GPSD.

  • Thank you guys for answering !

    I found another solution : Since I don't want to have constant updates on my location, I set the PositionSource active property on false. From the documentation I thought that update() would set that property on true for the update and set it back to false afterwards. Maybe that's what it does but I have to wait 2 minutes before receiving the signal onPositionChanged.

    So what I did : I manually enabled the active property before updating and then I set it back to false after the signal. I don't know why but by doing that, I get new coordinates in 20 seconds which is fine.

    However my phone tells me that the application is still searching for GPS signal while it shouldn't. If I find out why, I'll edit my comment.

    EDIT : So in order to stop the application from searching for GPS signal after the update, I had to call stop() out of the onPositionChanged signal handler.

  • Banned

    This post is deleted!

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.