We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 18c62f2 + 55af7f1 commit d8c3e59Copy full SHA for d8c3e59
1 file changed
Macropad_2FA_TOTP/macropad_totp.py
@@ -27,12 +27,6 @@
27
DISPLAY_RATE = 1 # screen refresh rate
28
#-------------------------------------------------------------------------
29
30
-# TODO: remove this once this is resolved:
31
-# https://github.com/adafruit/circuitpython/issues/4893
32
-# and this gets merged:
33
-# https://github.com/adafruit/circuitpython/pull/4961
34
-EPOCH_OFFSET = 946684800 # delta from above issue thread
35
-
36
# Get sekrets from a secrets.py file
37
try:
38
from secrets import secrets
@@ -95,7 +89,7 @@
95
89
# H E L P E R F U N C S
96
90
97
91
def timebase(timetime):
98
- return (timetime + EPOCH_OFFSET - (UTC_OFFSET*3600)) // 30
92
+ return (timetime - (UTC_OFFSET*3600)) // 30
99
93
100
94
def compute_codes(timestamp):
101
codes = []
0 commit comments