BoneScript
detachInterrupt(pin, [callback])
Remove an interrupt handler
Note: This function is still undergoing development and debug.
Arguments
- pin: the BeagleBone pin identifier
- callback: called upon completion
Return value
callback(x)
- x.err: error status message
Example
var b = require('bonescript'); var inputPin = 'P8_19'; b.pinMode(inputPin, b.INPUT); b.attachInterrupt(inputPin, true, b.CHANGE, interruptCallback); setTimeout(detach, 1000); function interruptCallback(x) { console.log(JSON.stringify(x)); } function detach() { b.detachInterrupt(inputPin); console.log('Interrupt detached'); }
See also
Topics
Related functions
Examples
Last updated by blog.hangerhead.com on Fri Jun 21 2013 14:37:54 GMT-0000 (UTC).