I have a question regarding the use of websockets to communicate with the Loxone Miniserver.
Are there any best-practices or things to avoid you plan a config where you will control/monitor with websockets?
In my case, I want to control some devices (e.g. an amplifier) via NodeRED and as I understand it the best two-communication is using websockets (via node-red-contrib-loxone ). However, it does seem to me that you are a bit constructing things blindly: you just make control elements which you will access via the websockets - there is no single device in the Tree, no entry in virtual inputs or outputs, no templates... So does that mean you have to just organize with pages, category and room? So you make e.g. a knx button, named it logically and just leave it disconnected as all changes will go via the websocket? (just trying to wrap my head around it)
Just to give some context: I currently have a PC which runs Eventghost, and communciate with it through virtual inputs and virtual outputs, with defined templates for various devices. I'm now considering to move to something else as my Eventghost configuration was hard to maintain and I had a lot of duplication between my Loxone config and my Eventghost config. Since some database-crash, the Eventghost website went offline, together with the vast knowledge in the forum. The project was moved to github, but there is much now a much smaller active community, so I figured it is time for a change.
NodeRED seems to be the way to go, I've found flows that can control my TV, and I should be able to manage almost everything. But I need to redo big parts of my config, hence the question on some pointers to get started.
Thanks,
Jörg
At least I got the websocket part
, but it makes sense to limit the communication to easy identifiable controls/nodes.
There will be many output commands in Loxone, but they all go to the same TCP port (and thus the same NodeRED node). And it will look a lot like your approach: 1 virtual output (the NodeRED computer), with multiple virtual output commands. For the data sent from NodeRED to Loxone I need a lot of decoding: the values are codes which I need to translate, so I might as well just receive a string (1 virtual texty input) and parse it. the parsing at the same time will trigger the decoding. Otherwise I have to parse it in NodeRED (to identify which value it is), and then send it all to seperate nodes to then translate it. It seems easier to combine that step as one in the Loxone config: command recognition would immediately identify the command and give me the value..
Kommentar