HomeSeer / node-red-contrib-homeseer

HomeSeer Nodes for Node-RED
GNU Affero General Public License v3.0
5 stars 4 forks source link

Need Ability to Perform Z-Wave Config Actions #10

Closed jersilver closed 3 years ago

jersilver commented 3 years ago

Hi, awesome work getting Node Red into Homeseer, this is truly a huge step forward.

Question... are there any hooks that allow for setting (i.e. injecting) Z-Wave configuration parameters on device nodes?

For example, I have HS and Inovelli switches with RGB status LEDs. I’d like to change the color/status based on logic in Node Red flows, but there does not seem to be such an API exposed to Node Red.

Do you see it possible to add such capability?

HomeAssistant, for example, exposes a service to NR that allows for setting Z-Wave parameters. I suspect I could build a separate service and call it from NR, but would prefer to not if HS has something in the works. I do realize I could call HS events from NR, but that is quite rigid.

Happy to help add code from the NR side if hooks are available from HS.

Thanks in Advance, Jeremy

kmitch95120 commented 3 years ago

Since hs-server.js is using the JSON API to control an HS device, it should be possible to call a function within the Z-Wave plugin to do what you want. Some research into the Z-Wave plugin functions would need to be done as well as some experimenting with a browser before implementing the NR code.

The basic syntax is:

/JSON?request=pluginfunction&function=FUNCTION_NAME&plugin=PLUGIN_NAME&instance=INSTANCE_NAME&P#-PN=PARAMETER

jersilver commented 3 years ago

Since hs-server.js is using the JSON API to control an HS device, it should be possible to call a function within the Z-Wave plugin to do what you want. Some research into the Z-Wave plugin functions would need to be done as well as some experimenting with a browser before implementing the NR code.

The basic syntax is:

/JSON?request=pluginfunction&function=FUNCTION_NAME&plugin=PLUGIN_NAME&instance=INSTANCE_NAME&P#-PN=PARAMETER

jersilver commented 3 years ago

Thanks @kmitch95120, I appreciate the reply, I think yand ou are 100% correct : )

After doing some further digging, I was able to find the JSON spec for performing Z-Wave configuration, but it appears the JSON API is currently busted.

I posted about it here on the forums, so hopefully it can get addressed sooner than later: https://forums.homeseer.com/forum/homeseer-products-services/system-software-controllers/hs4-hs4pro-software/1426159-json-web-api-for-request-pluginfunction-with-plugin-z-wave-broken-in-hs4

Take care!

kmitch95120 commented 3 years ago

@jersilver - For some reason, I can't view that link. Any ideas?

MattL0 commented 3 years ago

Can you go to that Link ?

kmitch95120 commented 3 years ago

@MattL0 - Yesterday when I clicked on that link, it went to the forum but said something about me not being authorized to view it. Now it works. Thanks.

jersilver commented 3 years ago

@MattL0, @kmitch95120 : Sorry about that! It was my first HS forum post, so it had to be "moderated" first.

Now I guess I wait to see if they will put in a fix for the JSON API : /

spudwebb commented 3 years ago

I'm closing this issue as this is not an issue with node-red-contrib-homeseer but rather a bug in HS4