Node-Red Palette: Common Choices

I was just adding this as an edit but since you beat me....

After adding devices to the list, the will show up, but nothing happens with either status or control nodes. Output to debug show nothing either.

Let me try the github one.

1 Like

In case you can't find it easily ...

ummm and how do you import without using the manager?

1 Like
  1. Shutdown node-red
  2. Download an archive from Github, then expand it to its own directory under ~/.node-red/node_modules
  3. Go into that directory and run "npm install".
  4. Restart node-red

That should do it. In this particular case, I would first remove the existing node-red-contrib-lutron nodes.

1 Like

Nope. I've attempted to use version 1.03 of node-red-contrib-lutron (the one that @aaiyar noted) and it throws a Telnet error. I can't figure out why as the Telnet commands are the same. This goes back several months, but I opened Github issues for both this component and the Telnet driver and neither author was of much help.

2 Likes

If you manually telnet to the RA2 bridge, what are the prompts seen? For example, with the Caseta Pro bridge, the prompts are:

login:
password:

An unsuccessful login sends you back to the login prompt.

A successful login bring the following prompt:

GNET>

These prompts, along with the username/password of lutron/integration are hard-coded in node-red-contrib-lutron. I am wondering whether the issue is a slight difference in the prompts leading to an unrecoverable error. And if so, it opens the possibility of a relatively simple fix.

Thanks!

P.S. Also tagging @TechMedX

yep it's all the same with lutron and integration for creds, I just logged in via putty to check telnet
port 23 all that jazz.

After each command, do you have to send "\n" or "\r\n"? Meaning just LF or CRLF?

Edit: Found what I'm pretty sure is an error in the lutron config node.

In the 1.0.3 version, can you try changing line 52 of lutron-config.js from:

this.telent.getSocket().write(msg + '\n', fn);

to

this.telnet.getSocket().write(msg + '\n', fn);

1 Like

these look the same to me?

1 Like

telnet is mispelled on line 52 as "telent"

3 Likes

How many times a WEEK do I make that same typo? LOL Enough so I've seriously considered adding an Alias :smiley:

3 Likes

it's was misspelt a few place and a fixed them all, but still no change. Also getting this error inthe pallette screen

I checked github and I don't see that file.

EDIT @aaiyar do you use Lutron via NR? It seems like it might not be worth the time if both nodes are "one-way". I have many sequences the flow through devices.

1 Like

I'm going back in time, but I believe I tried it both ways. This is the error from the Node log:

Unhandled rejection Error: Cannot connect
at Socket.socket.setTimeout (/data/node_modules/telnet-client/lib/index.js:87:25)
at Object.onceWrapper (events.js:286:20)
at Socket.emit (events.js:198:13)
at Socket._onTimeout (net.js:443:8)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)

This was my end point. Why go through the hassle for some low functionality, poorly documented node. It would seem an easy thing to develop a Telnet wrapper for these basic Lutron commands, but this isn't it IMO.

2 Likes

Yes, these nodes are 1-way.

Just getting more in depth with Homebridge. Are you using the node-red-contrib-homebridge-automation node or some other means to get the notifications?

Yes I use the hb-status node from node-red-contrib-homebridge-automation to get those statuses out of Homebridge into Node-Red.

1 Like

Thanks! Working well with no issues with the node?

I have not had any problems with it, but only use it for informational purposes. The activity sensors are slow coming on and off, so it seems as accurate as far as I can tell. I just wish there was a way to get real HomeKit device data, but this only gets data that is available in Homebridge.

Thanks - I was only interested in smoke/CO2 anyway!

Not quite with you - what data do you mean?

I can clarify. Before doing any smarthome automation, I was an iPad/iPhone user. Some of the first smarthome devices I bought were homekit focused accessories (largely Eve products). Two types I bought were temperature sensors and a motion/presence detector. About the same time I was getting started with Hubitat, I installed several Nest Protects (wired).

As part of this evolution, I found that I could use homebridge to expose data from the Nest Protects to Homekit. I then learned that I could expose homebridge items to Hubitat and/or Node-Red. I found this was great as I could now build automations with the Nest Protect data. (As an aside, I think I found out that the wired versus battery Protects maybe do better presence sensing, but I could be wrong). I also created various virtual devices in homebridge for things that at the time seemed more supported there than Hubitat or Node-Red. I have since moved away from most of those.

What I wanted to do, however was recover the value of the Homekit only devices I had by getting their temperature reading and motion detection into Hubitat/Node-RED. Because Homekit sees itself as the center of the universe, it really doesn't have any provisions for sending its data to another program/hub/environment/etc.

I have been able to get motion data out from my homekit device by doing the following:

  1. Create a virtual switch in Homebridge
  2. Add the virtual switch to both Homekit and Hubitat/Node-RED
  3. Create an automation in Homekit, that changes the virtual switch whenever motion from my Eve device goes true or false
  4. Inside Hubitat/Node-Red treat the state of that switch, not as a switch, but as a motion detection true/false

For a binary item like motion detection, this works well. I thought about doing something similar for my 2 Homekit temperature/humidity sensors. Unfortunately, I haven't found a way take a numeric reading in homekit and put it into a virtual Homebridge device. I toyed with creating a virtual thermostat, but I stopped at the point it looked like I would have to have a separate automation rule for each temperature step and each humidity step for each temperature/humidity step within the range that I might subject them to. This was too much for the value added.

I now wonder if I can somehow use IOS shortcuts or Homekit automation to send the data via http call to Node-Red, but have other automation that I will work on first.

So back to your original ask for clarification, I just wish that in the same way I can expose Hubitat devices/states to Homebridge and vice versa, and the same between Homebridge and Node-RED and Node-Red and Hubitat, I wish there was a 2 way path for Homekit for something other than true false via a virtual switch.

2 Likes