Node-Red - Some initial questions

@erktrek @csteele - So I have been down the node-red rabbit hole and made great progress! Been watching videos and reading articles to have a basic understanding. So far so good.

However , got a few questions!

  1. I am having a problem with updates to device status on flows. Say, I start a sonos player, it correctly shows the status from "stopped" to playing, but all downstream nodes connected to the sonos player assume its off. I have to mostly restart the flow to get the correct status propagated. What could be causing this? My node-red is hosted on an ubuntu vm with 4 gb ram. I have tried refreshing the webhook connection in the config - seems to work for a while and the problem comes back.

  2. Is there a way to process commands sent back to hubitat devices in a batch and sequentially ? Something along the lines of first do this, and then that etc ... I have seen others use the delay button and chain nodes together. Is that the de facto way of doing this or is there a better way ? Just to reduce the visual clutter. I saw this (do-red (node) - Node-RED) and was wondering if that's the way to go ?

  3. For non-zwave devices without dnla support to help with status updates, is constant polling of the device the only way to get its status ? ( related to #1 above ). Is constant polling good or bad?

Thanks!

Do other events come through properly like Switch/Motion/Contacts? In the config did you click on the "configure webhook" button and get a green check box?

For Sonos I've been testing the SonosPlus and TTS-Ultimate Nodes in Node-RED, directly bypassing the need to use HE for those specific devices. Currently have an audio alert that notifies me if the basement refrigerator door has been open for an extended period of time.

I use both depending upon the situation. I like the organization DO-RED provides. edit: you can also encapsulate functionality in "subflows" as well. Those are very handy.

I'm not sure I understand the question? If you need to poll Z-Wave (non-plus) devices then you would do it directly from the HE Hub using the builtin Z-Wave poller app. Also some cloud connected devices like the Flume water monitor require polling as well. I have HE do this and then push the results to Node-RED via the HE Nodes.

edit: So constant polling is not necessarily a bad thing but it depends on your resources and how much activity your hub gets. Node-RED has the advantage of being hardware flexible so offloading as much of the heavier stuff to it should help. At least that's my philosophy.

1 Like

My issue isn't specific to sonos. There is another device on HE ( an Amp ) which also updates status slowly or not at all until a flow refreshed is done. But all other HE devices work well. I have configured the webhook and get a green check box. Perhaps I will take a look at SonosPlus. How does it compare to the HE integrated version? Any issues ?

That TTS thing sounds cool! Any hiccups using it at all?

Still wrapping my head around how this works. Got any flow I can look at for inspiration?

Apologies for the lack of clarity. Here , I am referring to devices not on HE at all - like my Yamaha amp ( No HE driver for it ). Is your Flume setup on HE? I assume for such devices, I will have to enable constant polling to get updated device status.

Here is my monthly water valve flow test (still a work in progress).. I am using DO-RED like a "task list".. Starts with the first output and continues along until the end.

SonosPlus am still experimenting with so nothing really to report yet. For the TTS-Ultimate stuff I am only using it in a few places but it seems to work as advertised.

I don't see any issue with constant polling with your PI - should be able to handle a lot of traffic and the nice thing is you could always swap out if necessary.

1 Like

Here is an example:
sonos is stopped but yahama on. The yahama's node ( in purple ) shows the correct status ( I have polling set up) but the last but one boolen node shows it in standby mode. Wont change until i refresh the flow.

What do your change nodes "mbr_sonos_state gv" and "sonos activity state" look like?

Also hook up a debug to your "Query Sonos State" device node - are you getting a msg when status changes?

1 Like

I hooked up a debug for both the sonos and yamaha nodes. they both show a full payload delivery. No errors there.

See below. Also provided the one for the yamaha. I suspect the issue is with the boolen nodes?




This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.