How to get the actual date?
-
Hi there, i am new to pycom devices and i try out the example for pytrack from the github and i cannot get the actual date but only stop at year 1970. May i know how can i solve this? Thanks in advance.


-
@mj According to the documentation:
import machine rtc=machine.RTC() rtc.ntp_sync("pool.ntp.org") -
This post is deleted! -
You need a running WiFi and access to a time server. In the example from robert-HH the internet.
If you still trying to get the GPS data. You can get the UTC time from the sentence parsed by the lib. And don't forget to read the documentation from the GPS/GNSS chip. The chip sends two sentences according if it receive signals from US or the russian sattelites. But the lib parses only the russian sentence. Maybe the US sentence works better in your area.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login