mirror of
https://github.com/node-red/node-red-nodes.git
synced 2023-10-10 13:36:58 +02:00
set makeymakey node to use the module.exports style
This commit is contained in:
parent
232a11983b
commit
76d05dc2cd
@ -14,10 +14,11 @@
|
||||
* limitations under the License.
|
||||
**/
|
||||
|
||||
var RED = require(process.env.NODE_RED_HOME+"/red/red");
|
||||
var hids = require('hidstream');
|
||||
module.exports = function(RED) {
|
||||
"use strict";
|
||||
var hids = require('hidstream');
|
||||
|
||||
function MakeyNode(n) {
|
||||
function MakeyNode(n) {
|
||||
RED.nodes.createNode(this,n);
|
||||
this.vid = 0x1b4f; // MakeyMakey vendor ID
|
||||
this.pid = 0x2b75; // MakeyMakey product ID
|
||||
@ -80,5 +81,6 @@ function MakeyNode(n) {
|
||||
if (tout) { clearTimeout(tout); }
|
||||
if (node.makey) { node.makey.device.close(); }
|
||||
});
|
||||
}
|
||||
RED.nodes.registerType("makeymakey",MakeyNode);
|
||||
}
|
||||
RED.nodes.registerType("makeymakey",MakeyNode);
|
||||
|
Loading…
Reference in New Issue
Block a user