From 7f31099eead99718d279d9a4bb543131329891ce Mon Sep 17 00:00:00 2001 From: Marti Bolivar Date: Wed, 15 Dec 2010 01:50:56 -0500 Subject: Finalized 0.0.9 documentation. --- source/lang/api/nointerrupts.rst | 47 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 source/lang/api/nointerrupts.rst (limited to 'source/lang/api/nointerrupts.rst') diff --git a/source/lang/api/nointerrupts.rst b/source/lang/api/nointerrupts.rst new file mode 100644 index 0000000..68f0498 --- /dev/null +++ b/source/lang/api/nointerrupts.rst @@ -0,0 +1,47 @@ +.. highlight:: cpp + +.. _lang-nointerrupts: + +noInterrupts() +============== + +Description +----------- + +Disables interrupts. Interrupts allow certain important tasks to +happen in the background and are enabled by default. Some functions +will not work while interrupts are disabled, and incoming +communication may be ignored. Interrupts can slightly disrupt the +timing of code, however, and may be disabled for particularly critical +sections of code. + +Library Documentation +--------------------- + +.. doxygenfunction:: noInterrupts + +Example +------- + +:: + + void setup() {} + + void loop() { + noInterrupts(); + // critical, time-sensitive code here + interrupts(); + // other code here + } + +See Also +-------- + +- :ref:`interrupts() ` +- :ref:`attachInterrupt() ` +- :ref:`detachInterrupt() ` +- :ref:`Timers reference ` +- :ref:`Timer API ` +- :ref:`External interrupts ` + +.. include:: /lang/cc-attribution.txt -- cgit v1.2.3