Skip to content

Commit db94a2e

Browse files
author
brentru
committed
clarify localtime
1 parent 612008b commit db94a2e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

adafruit_ntp.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,8 @@ def __init__(self, esp):
5959
raise TypeError("Provided esp is not an ESP_SPIcontrol object")
6060

6161
def set_time(self):
62-
"""Fetches and sets the UTC time of
63-
this microcontroller.
62+
"""Fetches and sets the microcontroller's current time
63+
in seconds since since Jan 1, 1970.
6464
"""
6565
now = self._esp.get_time()
6666
now = time.localtime(now[0])

examples/ntp_simpletest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
current_time = time.time()
3737
print("Seconds since Jan 1, 1970: {} seconds".format(current_time))
3838

39-
# Convert the time in seconds to a struct_time
39+
# Convert the current time in seconds since Jan 1, 1970 to a struct_time
4040
now = time.localtime(current_time)
4141
print(now)
4242

0 commit comments

Comments
 (0)