[SiPy] PyTrack GPS Not Working? (Firmware 0.0.4) [SOLVED]

  • I'm using what appears to be the latest firmware version available for the PyTrack module. Yaw, Pitch, Roll and Acceleration work perfectly fine on the device. GPS does not. When I try to get the GPS by calling "L76GNSSObj.coordinates()" it'll hang indefinitely if I do not specify a timeout. If I do specify a timeout, it'll stop trying to retrieve the GPS coordinates. Upon printing the results it returns "(None, None)". If I set Debug to True when calling that function, it says "GPS Timed Out." and then on a new line "None". I'm working on a project and I need the GPS to work. Is it not fully implemented yet? I've tried the GPS indoors and beside a window, but so far have been unable to test it outside. However I don't believe the results would be much different.

    I am running a PyTrack V1.0 and I'm using a SiPy V1.0. I've tried another PyTrack board and I've had the same trouble. I have 6 others I could test, but I don't think it's worth it to sift through all of the PyTrack boards.

    Has anyone had this issue? How can I fix it?

    Thanks in advance!

  • @OPCDF Unfortunately there isn't a way to mark it as resolved (we're looking into other forums that allow you to do it).

    The best thing you can do right now is to modify the title of this post to add '[SOLVED]' to the end of it!


  • @bucknall I had to move around a bit but eventually I got the GPS to work! I went outside and it didn't work initially, but I moved down a bit and it started returning coordinates! Thanks a bunch. Is there a way to mark this as solved?

  • @OPCDF Let me know how you get on; the GPS (as with most GPS sensors) requires line of sight with the satellites for the best performance.

  • @bucknall Hi. I've updated the GPS library and done some firmware upgrades on my SiPy. However the GPS still returns (None, None). I will try it outside later, perhaps that is the issue. As mentioned I have tried it beside a window facing outside, and that's about as close as I could get as it was raining for a few days. Once I get a chance to try it outside I will get back to you. Thanks again.

  • @OPCDF I've updated the GPS library to fix an existing bug so it'll be worth updating to it (https://github.com/pycom/pycom-libraries/blob/master/pytrack/lib/L76GNSS.py). However what you are experiencing sounds like intended behavior; if the GPS does not get a location from the satellites before the timeout, it will return (None, None) so as not to block the rest of your code from executing.

    If you don't want this functionality, simply do not pass the timeout parameter into the GPS constructor.


  • @bucknall Hi. I was out all weekend and didn't get a chance to see this until now. Here is all the code I've been using to call the GPS: https://pastebin.com/vfBF631h

    As I mentioned, when I run this code it just hangs and doesn't actually do anything. When the timeout runs out (in this case 20 seconds) it just returns "(None, None)". I'd imagine this is supposed to return a tuple with latitude and longitude coordinates instead.


  • Hi @OPCDF I've been working on the GPS lib to fix a memory issue, I'll check this now for you.

    Can you please share the code you're using to call the GPS?



Log in to reply

Pycom on Twitter