aboutsummaryrefslogtreecommitdiffstats
path: root/wirish/ext_interrupts.h
diff options
context:
space:
mode:
authorMarti Bolivar <mbolivar@mit.edu>2010-10-25 21:15:28 -0400
committerMarti Bolivar <mbolivar@mit.edu>2010-11-17 12:44:28 -0500
commit95783b750fda95f5f4c1fac00ab24da03b31b517 (patch)
tree2b0bf89c101aa58af5796fbe76c7ec98eebbb0a5 /wirish/ext_interrupts.h
parent3a9a119e9a8ce72c0e1b8fa4d3904bdf84ce355c (diff)
downloadlibrambutan-95783b750fda95f5f4c1fac00ab24da03b31b517.tar.gz
librambutan-95783b750fda95f5f4c1fac00ab24da03b31b517.zip
arduino language reference nearing completion, properly CC-BY-SA 3.0 attributed
Diffstat (limited to 'wirish/ext_interrupts.h')
-rw-r--r--wirish/ext_interrupts.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/wirish/ext_interrupts.h b/wirish/ext_interrupts.h
index 80e2e9e..d44978a 100644
--- a/wirish/ext_interrupts.h
+++ b/wirish/ext_interrupts.h
@@ -34,7 +34,7 @@
#define _EXT_INTERRUPTS_H_
/**
- * The kind transition on an external pin which should trigger an
+ * The kind of transition on an external pin which should trigger an
* interrupt.
*/
typedef enum ExtIntTriggerMode_ {
@@ -56,13 +56,16 @@ extern "C"{
*
* The interrupt will be triggered on a given transition on the pin,
* as specified by the mode parameter. The handler runs in interrupt
- * context.
+ * context. The new handler will replace whatever handler is
+ * currently registered for the pin, if any.
*
* @param pin Maple pin number
* @param handler Function to run upon external interrupt trigger.
+ * The handler should take no arguments, and have void return type.
* @param mode Type of transition to trigger on, e.g. falling, rising, etc.
*
* @sideeffect Registers a handler
+ * @see detachInterrupt()
*/
void attachInterrupt(uint8 pin, voidFuncPtr handler, ExtIntTriggerMode mode);
@@ -70,6 +73,7 @@ void attachInterrupt(uint8 pin, voidFuncPtr handler, ExtIntTriggerMode mode);
* @brief Disable any registered external interrupt.
* @param pin Maple pin number
* @sideeffect unregisters external interrupt handler
+ * @see attachInterrupt()
*/
void detachInterrupt(uint8 pin);