Skip to content

Commit de81127

Browse files
docs: Add missing days parameter to microbit.run_every. (#767)
1 parent d591517 commit de81127

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

docs/microbit.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ Functions
6969
:param n: An integer or floating point number indicating the number of
7070
milliseconds to wait.
7171

72-
.. py:function:: run_every(callback, h=None, min=None, s=None, ms=None)
72+
.. py:function:: run_every(callback, days=None, h=None, min=None, s=None, ms=None)
7373
7474
Schedule to run a function at the interval specified by the time arguments.
7575

@@ -78,7 +78,7 @@ Functions
7878
* As a **Decorator** - placed on top of the function to schedule.
7979
For example::
8080

81-
@run_every(h=1, min=20, s=30, ms=50)
81+
@run_every(days=1, h=1, min=20, s=30, ms=50)
8282
def my_function():
8383
# Do something here
8484

@@ -89,14 +89,15 @@ Functions
8989
# Do something here
9090
run_every(my_function, s=30)
9191

92-
Each arguments corresponds to a different time unit and they are additive.
92+
Each argument corresponds to a different time unit and they are additive.
9393
So ``run_every(min=1, s=30)`` schedules the callback every minute and
9494
a half.
9595

9696
When an exception is thrown inside the callback function it deschedules
9797
the function. To avoid this you can catch exceptions with ``try/except``.
9898

9999
:param callback: Function to call at the provided interval.
100+
:param days: Sets the days mark for the scheduling.
100101
:param h: Sets the hour mark for the scheduling.
101102
:param min: Sets the minute mark for the scheduling.
102103
:param s: Sets the second mark for the scheduling.

0 commit comments

Comments
 (0)