node-red-contrib-i2c
node-red-contrib-i2c copied to clipboard
"Error: Invalid I2C bus number 1"
Just updated and see in the node red debug window: "Error: Invalid I2C bus number 1"
to which version - I think 0.7.1 should fix it.
The fix is missing only on in node
to fix it replace code: // The Input Node function I2CInNode(n) { RED.nodes.createNode(this, n); this.busno = n.busno || 1; this.address = n.address; this.command = n.command; this.count = n.count; var node = this;
with // The Input Node function I2CInNode(n) { RED.nodes.createNode(this, n); this.busno = parseInt(n.busno || 1); this.address = parseInt(n.address); this.command = parseInt(n.command); this.count = parseInt(n.count); var node = this;