Skip to content

Commit 6e27619

Browse files
authored
Little docstring change
1 parent 20bbf77 commit 6e27619

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

timings/monotonic_loop.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
"""
2+
Loop with 2 timers, using time.monotonic()
23
4+
NOTE: time.monotonic() loses precision after many hours of running.
5+
Prefer using time.monotonic_ns() on boards that support it.
6+
Since monotonic_ns is in nano seconds, you have to adapt the delays.
37
"""
48
import time
59

@@ -8,10 +12,6 @@
812
# every 2 seconds:
913
TIMER_2_DELAY = 2
1014

11-
# NOTE: time.monotonic() loses precision after many hours of running.
12-
# Prefer using time.monotonic_ns() on boards that support it.
13-
# Since monotonic_ns is in nano seconds, you have to adapt the delays.
14-
1515
# Change *_next_run to now or 0 if you want to trigger it on the first loop.
1616
# Or "now + X" to trigger at a different time the first time.
1717
now = time.monotonic()

0 commit comments

Comments
 (0)