summaryrefslogtreecommitdiffstatshomepage
path: root/docs/mimxrt/quickref.rst
diff options
context:
space:
mode:
authorrobert-hh <robert@hammelrath.com>2022-10-15 11:40:22 +0200
committerDamien George <damien@micropython.org>2022-10-27 14:09:29 +1100
commit65fa7fd8bbaf570be3f4654bcc597a46c70e4b75 (patch)
treea2d98ce6ee28f40c5bbd5f3d94c16774e193bc4e /docs/mimxrt/quickref.rst
parent9d2e179fa565d8af96fb6ce3643e00f999c9210a (diff)
downloadmicropython-65fa7fd8bbaf570be3f4654bcc597a46c70e4b75.tar.gz
micropython-65fa7fd8bbaf570be3f4654bcc597a46c70e4b75.zip
mimxrt/machine_timer: Use soft-timer implementation for machine.Timer.
This releases the hardware timers for other tasks, which need a higher resolution and faster response. And it is less port-specific code.
Diffstat (limited to 'docs/mimxrt/quickref.rst')
-rw-r--r--docs/mimxrt/quickref.rst9
1 files changed, 3 insertions, 6 deletions
diff --git a/docs/mimxrt/quickref.rst b/docs/mimxrt/quickref.rst
index c75fe60c8d..06f91f7f50 100644
--- a/docs/mimxrt/quickref.rst
+++ b/docs/mimxrt/quickref.rst
@@ -56,21 +56,18 @@ Use the :mod:`time <time>` module::
Timers
------
-The i.MXRT port has three hardware timers. Use the :ref:`machine.Timer <machine.Timer>` class
-with a timer ID from 0 to 2 (inclusive)::
+The i.MXRT port supports virtual Timers. Example of usage::
from machine import Timer
- tim0 = Timer(0)
+ tim0 = Timer(-1)
tim0.init(period=5000, mode=Timer.ONE_SHOT, callback=lambda t:print(0))
- tim1 = Timer(1)
+ tim1 = Timer(-1)
tim1.init(period=2000, mode=Timer.PERIODIC, callback=lambda t:print(1))
The period is in milliseconds.
-Virtual timers are not currently supported on this port.
-
.. _mimxrt_Pins_and_GPIO:
Pins and GPIO