mirror of
https://github.com/node-red/node-red-nodes.git
synced 2023-10-10 13:36:58 +02:00
Bump arduino node to latest firmata and serialport
shoudl work better with nodejs 10
This commit is contained in:
parent
602586ad82
commit
c1650b5d47
@ -11,7 +11,7 @@ module.exports = function(RED) {
|
||||
this.device = n.device || null;
|
||||
var node = this;
|
||||
|
||||
node.board = Board(node.device, function(e) {
|
||||
node.board = new Board(node.device, function(e) {
|
||||
//console.log("ERR",e);
|
||||
if ((e !== undefined) && (e.toString().indexOf("cannot open") !== -1) ) {
|
||||
node.error(RED._("arduino.errors.portnotfound",{device:node.device}));
|
||||
@ -32,7 +32,7 @@ module.exports = function(RED) {
|
||||
node.on('close', function(done) {
|
||||
if (node.board) {
|
||||
try {
|
||||
node.board.sp.close(function() {
|
||||
node.board.transport.close(function() {
|
||||
if (RED.settings.verbose) { node.log(RED._("arduino.status.portclosed")); }
|
||||
done();
|
||||
});
|
||||
@ -172,6 +172,5 @@ module.exports = function(RED) {
|
||||
SP.list(function(error, ports) {
|
||||
res.json(ports);
|
||||
});
|
||||
|
||||
});
|
||||
}
|
||||
|
@ -7,7 +7,7 @@ Arduino running standard firmata 2.2 or better.
|
||||
Install
|
||||
-------
|
||||
|
||||
Run the following command in your Node-RED user directory - typically `~/.node-red`
|
||||
Either use the Menu - Manage Palette option or run the following command in your Node-RED user directory - typically `~/.node-red`
|
||||
|
||||
npm i --unsafe-perm node-red-node-arduino
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
{
|
||||
"name" : "node-red-node-arduino",
|
||||
"version" : "0.0.18",
|
||||
"version" : "0.1.0",
|
||||
"description" : "A Node-RED node to talk to an Arduino running firmata",
|
||||
"dependencies" : {
|
||||
"firmata" : "~0.19.1"
|
||||
"firmata" : "^2.0.0"
|
||||
},
|
||||
"repository" : {
|
||||
"type":"git",
|
||||
@ -16,6 +16,7 @@
|
||||
"arduino": "35-arduino.js"
|
||||
}
|
||||
},
|
||||
"engines" : { "node" : ">=8" },
|
||||
"author": {
|
||||
"name": "Dave Conway-Jones",
|
||||
"email": "ceejay@vnet.ibm.com",
|
||||
|
Loading…
Reference in New Issue
Block a user