mirror of
https://github.com/node-red/node-red-nodes.git
synced 2023-10-10 13:36:58 +02:00
niggles in new Hummingboard GPIO node
This commit is contained in:
parent
785f2dde16
commit
5f78aa10ad
@ -6,6 +6,8 @@ A <a href="http://nodered.org" target="_new">Node-RED</a> node to read and write
|
|||||||
Install
|
Install
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
**This install is for Debian based OS on Hummingboard.**
|
||||||
|
|
||||||
Run the following command in the root directory of your Node-RED install:
|
Run the following command in the root directory of your Node-RED install:
|
||||||
|
|
||||||
npm install node-red-node-hpgpio
|
npm install node-red-node-hpgpio
|
||||||
|
@ -21,12 +21,12 @@ module.exports = function(RED) {
|
|||||||
|
|
||||||
var gpioCommand = '/usr/local/bin/gpiohb';
|
var gpioCommand = '/usr/local/bin/gpiohb';
|
||||||
|
|
||||||
//if (!fs.existsSync("/dev/ttyAMA0")) { // unlikely if not on a Pi
|
//if (!fs.existsSync("/etc/init.d/armhwinfo")) { // unlikely if not on a Hummingboard
|
||||||
//throw "Info : Ignoring Raspberry Pi specific node.";
|
//throw "Info : Ignoring Hummingboard specific node.";
|
||||||
//}
|
//}
|
||||||
|
|
||||||
if (!fs.existsSync(gpioCommand)) { // gpio command not installed
|
if (!fs.existsSync(gpioCommand)) { // gpio command not installed
|
||||||
throw "Info : Can't find "+gpioCommand+" command.";
|
throw "Error : Can't find "+gpioCommand+" command for Hummingboard.";
|
||||||
}
|
}
|
||||||
|
|
||||||
// Map physical P1 pins to Gordon's Wiring-Pi Pins (as they should be V1/V2 tolerant)
|
// Map physical P1 pins to Gordon's Wiring-Pi Pins (as they should be V1/V2 tolerant)
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name" : "node-red-node-hbgpio",
|
"name" : "node-red-node-hbgpio",
|
||||||
"version" : "0.0.1",
|
"version" : "0.0.3",
|
||||||
"description" : "A Node-RED node for the GPIO of the Hummingboard",
|
"description" : "A Node-RED node for the GPIO of the Hummingboard",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
},
|
},
|
||||||
"repository" : {
|
"repository" : {
|
||||||
"type":"tgz",
|
"type":"tgz",
|
||||||
"url":"http://dcj.dtdns.net/npms/hbgpio.tgz"
|
"url":"https://github.com/node-red/node-red-nodes/tree/master/hardware/HummingboardGPIO"
|
||||||
},
|
},
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"keywords": [ "node-red", "hummingboard", "gpio" ],
|
"keywords": [ "node-red", "hummingboard", "gpio" ],
|
||||||
|
Loading…
Reference in New Issue
Block a user