ratmandu / node-red-contrib-zblight

Zigbee light control for node red
Apache License 2.0
15 stars 9 forks source link

The Node zblight does not appear in Node-red dashboard #2

Closed juancreyes closed 7 years ago

juancreyes commented 7 years ago

Hi master,

I have installed contrib-zbling and required packages node-serialport and xbee-api. However after starting node-red the regarding nodes does not appear in node-red dashboard. Can ypu please advice what is missing ?

I am using Linux in Raspberry Pi2, Node-red and npm:

node -v

v0.12.6

npm -v

2.11.2

The outcome during installation:

node-red-contrib-zblight@1.0.0 node_modules/node-red-contrib-zblight xbee-api@0.4.3 node_modules/xbee-api ├── buffer-builder@0.2.0 └── buffer-reader@0.0.3 node-red-node-serialport@0.3.0 node_modules/node-red-node-serialport └── serialport@3.1.2 (bindings@1.2.1, es6-promise@3.2.1, commander@2.9.0, debug@2.2.0, nan@2.4.0, object.assign@4.0.4)

Regards.-

ratmandu commented 7 years ago

Did you run the commands in your node-red folder? Did you also restart node-red so it would register the new nodes?

juancreyes commented 7 years ago

Yes, I did

I have restarted several times node-red, reload the RBPi2 and cannot see the Xbee nodes, zblight neither.

The path where run "npm install" is /home/pi/.node-red

Node-red printout show version v0.14.6,

23 Aug 21:36:37 - [info] Node-RED version: v0.14.6 23 Aug 21:36:37 - [info] Node.js version: v0.12.6 23 Aug 21:36:37 - [info] Linux 4.4.17-v7+ arm LE 23 Aug 21:36:37 - [info] Loading palette nodes 23 Aug 21:36:49 - [info] Dashboard up and running 23 Aug 21:36:55 - [info] UI started at /ui

ratmandu commented 7 years ago

You will also need to refresh the browser page to get them to show up, in my experience.

The zblight node should show up in the "function" palette. The serial output node should show up in the "output" palette. xbee-api does not have a node in node-red, as it is a node.js library that I use to generate the api frames to be sent to the xbee.

Look around in the /home/pi/.node-red folder and see if you can locate the node-red-contrib-zblight folder. You may have to check the settings.js file, and adjust the nodesDir variable depending on your setup.

juancreyes commented 7 years ago

Ok thank you for clarifying about xbee-api

The update: "serial output" and "serial input" do exist along of input and output palette.

zblight Node doesn't came up yet in "function" pallete. I refreshed several time the browser.

The folder is located as per below, into node_modules dir where are installed other nodes: rbpi ~/.node-red/node_modules $ pwd /home/pi/.node-red/node_modules

Details of new contrib: rbpi ~/.node-red/node_modules $ ls -l node-red-contrib-zblight/ total 532 -rw-r--r-- 1 pi pi 52126 Aug 21 14:36 config.png -rw-r--r-- 1 pi pi 53955 Aug 21 14:36 flow.png -rw-r--r-- 1 pi pi 11357 Aug 21 15:51 LICENSE -rw-r--r-- 1 pi pi 48492 Aug 21 15:01 mqtt-flow.png -rw-r--r-- 1 pi pi 2156 Aug 21 15:51 node-red-contrib-zblight.html -rw-r--r-- 1 pi pi 2390 Aug 21 15:51 node-red-contrib-zblight.js -rw-r--r-- 1 pi pi 1564 Aug 23 21:11 package.json -rw-r--r-- 1 pi pi 2796 Aug 21 15:09 README.md -rw-r--r-- 1 pi pi 354618 Aug 21 14:53 xctu.png

settings.js has default configuration, that is, /home/pi/.node-red is the folder where Node-RED will scan to find nodes.

BR.

ratmandu commented 7 years ago

I don't have a raspberry pi to test with, but I will test with a completely fresh install and see if I can replicate the behavior.

ratmandu commented 7 years ago

The issue has been fixed with the above commit. Please test and let me know if it works for you.

juancreyes commented 7 years ago

Hi master,

Now it works, the node come up in dashboard. I saw the small statement was missing. Thank for your support. BR

ratmandu commented 7 years ago

Awesome! Thanks for the feedback!