docs/esp8266: Add ntptime usage to esp8266 quickref.
This commit is contained in:
parent
c0b3419261
commit
5a8f392f09
@ -243,6 +243,12 @@ See :ref:`machine.RTC <machine.RTC>` ::
|
||||
rtc.datetime((2017, 8, 23, 1, 12, 48, 0, 0)) # set a specific date and time
|
||||
rtc.datetime() # get date and time
|
||||
|
||||
# synchronize with ntp
|
||||
# need to be connected to wifi
|
||||
import ntptime
|
||||
ntptime.settime() # set the rtc datetime from the remote server
|
||||
rtc.datetime() # get the date and time in UTC
|
||||
|
||||
Deep-sleep mode
|
||||
---------------
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user