Grafana & InfluxDB reliably setup with no scripting required!

1,771 views
Skip to first unread message

Rob_in

unread,
Feb 20, 2020, 3:25:00 AM2/20/20
to Loxone English
Hi all,

We have discussed getting Grafana & InfluxDB working for more detailed long term graphs here before. If you don't know what I'm talking about, stuff like this...

Screenshot from 2020-02-20 08-56-45.png


The problem was always that this is a pretty messy setup and until recently I was not happy with the way one is able to collect data points in Loxone. I have tried 2 options:


1. I wrote a script that pulled in Loxone stat files via FTP and imported them into InfluxDB. This is reliable (well - as reliable as the Miniserver and SD card) but there was always a time lag in importing the files and one is restricted to the Loxone statistics gathering limits.


2. One can use Loxone UDP logging (or SNMP traps or other such things) and a script to receive these events and munge the data (Loxone insists on putting timestamps on their UDP logging for example) before putting in InfluxDB. The problem with this is that it requires some kind of proxy script and UDP transmission is not guaranteed. Loxone does not have a periodic send on UDP logging either, so if you happen to be rebooting your InfluxDB instance when the heating turns off for example, well, it will miss that 'off' data point sent from Loxone - and as heating turns on and off infrequently (for us at least) means that it can be 'stuck' in the wrong state for many hours, days or even longer.


So I wasn't really happy with either of these, and other people weren't happy with them either because of the scripting skills required to set this up.


However, I recently discovered ioBroker as a much better alternative to Home Assistant when it comes to acting as a Z-Wave gateway.


ioBroker happens to have native Loxone and InfluxDB modules (they are called 'adapters') that run 'out of the box' with zero scripting skills required. Just install the package, configure via the web interface and you're good to go.


This is not only better for the non-technical (no scripting required) but it is more robust than UDP Logging and with no lag. Best of all worlds!


How this works is that ioBroker connects to Loxone and uses the web socket communications to pull data points. Ie. Loxone thinks ioBroker is a user logged in to it's web interface and sends updates of everything that user has access to instantly down this web socket. This is more reliable than UDP because if you happen to reboot your ioBroker instance while Loxone changes a data point, that point will be read and updated upon ioBroker re-connecting to Loxone, so it will never get 'stuck'. If you happen to have InfluxDB on a separate box and that is rebooted, ioBroker buffers it's writes and sends them when InfluxDB comes back. Moreover, the ioBroker InfluxDB adapter can be configured to send data points periodically whether it thinks they have changed or not - meaning worst case, even if InfluxDB misses points, things should only get 'stuck' for that short period between re-sending points.


The ioBroker InfluxDB adapter currently allows one to give each reading an 'Alias' which is a nice name (like 'KitchenTemperature') that is easily found in Grafana. Their measurements/tag config is a little weak but the Alias thing works fine and I might fix the tags thing for them ;)


Anyhow, so yes, I mention this to point out it's now possible to get nice graphs out of your Loxone system without any scripting and just some web interface configuration. I know people will be pleased to hear this as I was somewhat berated when I first brought this up and didn't want to do much to help with scripts ;)


If there's demand, I could write a small 'howto' page on the Wiki to describe the setup steps in a bit more detail. Just let me know.


Cheers,


Robin


Rob

unread,
Feb 20, 2020, 7:08:02 AM2/20/20
to Loxone English
That's fantastic Robin, what a great find with ioBroker, and thanks for sharing it.

I've wanted decent stats out of Loxone for ages but couldn't justify the time involved in trying to get it working seamlessly using scripts etc. but this looks so simple I'm going to give it a try when i get a bit of time next week.

Thanks again.

Rob

Rob_in

unread,
Feb 21, 2020, 4:10:54 AM2/21/20
to Loxone English
No worries. Just a couple of tips:

- I would recommend creating a special user for ioBroker and only giving it access to the things you want to monitor in there. If you give it regular user access then it will pull in all the changes from every control visible in the UI. Depending on the size of your system that could be confusing and/or slow things down.

- It's not immediately obvious how the InfluxDB adapter in ioBroker is supposed to work after enabling it. Looking closely though, when that adapter is running you will see a little config item appear next to every object (on the right hand side of each one in the objects table). It's in that config (on a per-object basis) that you enable sending updates from said object to InfluxDB (and where you setup the alias for that object too).

HTH,

Robin

Jan De Bock

unread,
Feb 21, 2020, 4:39:56 AM2/21/20
to Loxone English
Tx Rob, looks very interesting !
I saw there is a possibility to store also in postgres.
This is what I just did with UDP. 
SQL is more robust and extensive than influx, hence my interest there.

Rob_in

unread,
Feb 22, 2020, 1:24:34 AM2/22/20
to Loxone English
On Friday, 21 February 2020 10:39:56 UTC+1, Jan De Bock wrote:
This is what I just did with UDP. 

'Robust' implies never using UDP. In the process I describe Loxone -> ioBroker is TCP websockets and ioBroker -> InfluxDB is also via TCP.
 
SQL is more robust and extensive than influx, hence my interest there.

Not going to get into the whole debate about which time series database is best, but if you want to use PostgreSQL knock yourself out.

Robin

Daniel Feist

unread,
Feb 24, 2020, 11:21:32 AM2/24/20
to Rob_in, Loxone English
Robin,

Where are you physically running ioBroker, InfluxDB, and Grafana?  Do you have these running locally or are any of them sat in the cloud?

Also, wondering if ioBroker allows for triggering events in Loxone and not just reading values?  i.e. to integrate with ecosystems that Loxone doesn't support directly?

Thanks,
Dan



--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-englis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/loxone-english/61c9dcfd-a7b1-4680-9fa4-6bffc8d629dd%40googlegroups.com.

Rob_in

unread,
Feb 24, 2020, 12:06:33 PM2/24/20
to Loxone English
On Monday, 24 February 2020 17:21:32 UTC+1, Daniel Feist wrote:
Where are you physically running ioBroker, InfluxDB, and Grafana?  Do you have these running locally or are any of them sat in the cloud?

Locally. ioBroker on a Raspberry Pi and InfluxDB/Grafana on an x86 box I have lying around just because it's a bit quicker. There's actually no reason not to run the whole thing on a Pi if you can wait another 10th of a second for page load ;)
 
Also, wondering if ioBroker allows for triggering events in Loxone and not just reading values?

Yes it does. In fact the main reason I set it up was to pass events from our Z-Wave door/window sensors to Loxone.
 
i.e. to integrate with ecosystems that Loxone doesn't support directly?

Yes it can.

We have ioBroker playing a doorbell sound through a Chromecast for example when someone presses the doorbell that's attached to Loxone. I have also made ioBroker read out loud all the notifications Loxone spits out (easily achieved with the 'sayit' adapter and 4 lines of code).

Cheers,

Robin

Daniel Feist

unread,
Feb 24, 2020, 12:15:12 PM2/24/20
to Rob_in, Loxone English
Excellent.

Out of interest, what data are you putting into InfluxDB and what sensors are you using? Is it primarily temperatures at different locations in the house via one-wire sensors and/or room sensors?

About to start a self-build, so looking for some inspiration in terms of what might make sense to monitor over time, to get the sensors put in place as part of the build  Thinking:
- External temp/humidity
- Internal temps/humidity in different rooms (slab and/or room)
- Stats from MVHR
- Electricity use
- Electricity generation
- Electricity export

What am I missing?

Thanks,


--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-englis...@googlegroups.com.

Rob_in

unread,
Feb 24, 2020, 12:51:13 PM2/24/20
to Loxone English
On Monday, 24 February 2020 18:15:12 UTC+1, Daniel Feist wrote:
Out of interest, what data are you putting into InfluxDB and what sensors are you using? Is it primarily temperatures at different locations in the house via one-wire sensors and/or room sensors?

Just about everything ;) Temp/Humidity/Air Quality from 1-Wire (See the other thread regarding if 1-Wire is a good option though). Loads of stats from our boiler (via KNX). Electrical stuff (from a Legrand Ecocompteur that has an IP interface). Airflows, temps in/out, etc. from our HRV via Modbus.

What am I missing?

I can highly recommend air quality sensors. You can have your HRV turned right down so long as there's not too much CO2 (or humidity) in the house.

If you are having a boiler/heatpump/aircon or anything like that it's very handy to see what that has been up to. Even if you don't have one for heating, assume you will for hot water. Our boiler reports leaving/inlet water temperature along with flow. From this you can calculate how much thermal power it's putting into the UFH or hot water tank. As Loxone also knows how much electricity it's pulling I have it work out the COP and graph that.

We have a temperature model of the house that predicts (based on 'known' - erm, estimated - heat loss and weather forecast) what the temperature will be in the future. Well, up to 24 hours ahead. I actually graph these in Influx and timeshift them so can compare what the model said 6/12/18/24 hours ahead to what actually happened. I did this to verify the model was good and see if it needs adjustment, but it's very satisfying when the predictions all line up with the actual as they should :)

If we had a sunshine sensor or any kind of weather station stuff here I'd certainly record that to see how solar gain may be impacting internal temperatures.

My moto is: if you can measure it, record and graph it ;) Joking aside, you can't tell how well something (your house) is working if you aren't measuring and analysing it's performance over time.

Cheers,

Rob

Tom Bernaerd

unread,
Feb 25, 2020, 2:33:18 AM2/25/20
to Rob_in, Loxone English
I am using this node script by Andras (also active here): https://github.com/andrasg/loxone-influx - it is based on your statistics importer script. 
I have it running as a docker instance, so far no issues with reliability but then again it is only running for a week now. 

The advantage is flexibility in the tagging setup, so if you plan to improve that for IOBroker, it seems like a perfect solution. 

Tom 


--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-englis...@googlegroups.com.

Jan De Bock

unread,
Feb 25, 2020, 3:04:26 AM2/25/20
to Loxone English
Hi Rob,

can you share how you do the prediction ?
This is one of the things I would like to do as well, but did not had the time yet :-) 

I am also logging many on/off statuses  from devices (TV, Audio, office equipment etc) so I can relate this back to the energy monitoring.  It allows me to know from many different devices how much  kWh they consume.
Altogether I have about 180 different data points I can play with.

I will certainly look into IO Broker !  Appreciate the info !

Best regards,
Jan 

Hidde Beumer

unread,
Feb 25, 2020, 9:54:22 AM2/25/20
to Loxone English
this looks like a good way to go for me. My idea is to switch my basic home functions for lighting and heating to KNX, then build a broker/mediation/logic layer based on iobroker and then connect loxone on top for the visualization and for some more logic.
In the iobroker layer I would then also be able to integrate other things like weather data, doorbird, shelly, tasmota bulbs etc. and of course proper logging and graph-ing.

My plan is to start building the Iobroker piece parallel to loxone (both still talk to KNX) but over time migrate iobroker to become the broker layer for everything.

Do you foresee any issues/challenges with this?

Hidde



Op donderdag 20 februari 2020 09:25:00 UTC+1 schreef Rob_in:

Rob_in

unread,
Feb 25, 2020, 1:41:35 PM2/25/20
to Loxone English
On Tuesday, 25 February 2020 08:33:18 UTC+1, Tom B wrote:
I am using this node script by Andras (also active here): https://github.com/andrasg/loxone-influx - it is based on your statistics importer script. 

Yes, but the point of this current thread is to show people who don't like scripts and the like one can simply install the packages, configure them in a web interface and have it work.

Robin

Rob_in

unread,
Feb 25, 2020, 1:49:59 PM2/25/20
to Loxone English
On Tuesday, 25 February 2020 15:54:22 UTC+1, Hidde Beumer wrote:
My plan is to start building the Iobroker piece parallel to loxone (both still talk to KNX) but over time migrate iobroker to become the broker layer for everything.

Do you foresee any issues/challenges with this?

Nope, especially if you use a separate KNX IP gateway to move completely away from reliance on Loxone. Although, and I'm sure others will chime in with the same, the whole point of using Loxone is that it's a commercial system with commercial support that can (or at least should) be supported even if something happens to the original installer. 

One thing to note is that you would want mission critical hardware to run ioBroker on... which is certainly OT for this thread!

Cheers,

Robin

Rob_in

unread,
Feb 25, 2020, 1:59:35 PM2/25/20
to Loxone English
On Tuesday, 25 February 2020 09:04:26 UTC+1, Jan De Bock wrote:
can you share how you do the prediction ?

It's OT for this thread, but super simple: current inside minus outside gives you current delta. Use that and your known loss per degree of delta per hour (which is a constant for your house - I worked it out using a table of recorded stats in a spreadsheet) and you now know the predicted temperature in 1 hour. From that you now know the outside delta in 1 hour (the 1 hour prediction you just calculated minus the outside forecast in 1 hour) from which you can work out the prediction in 2 hours and so it cascades.

Problem with the above is every time the inside temperature changes it causes the whole cascading calculation to be performed which is overkill but more importantly can cause a high CPU load on the Miniserver. For this reason I have a number of temperature variables that are 'super slow' (using analogue memory blocks that only update once every 5 minutes or so) and this works well.
 
Robin

Paulo Matos

unread,
Mar 11, 2020, 5:25:13 AM3/11/20
to Loxone English
Thanks for the post.

Is this the alternative using Grafana?

Paulo

Rob_in

unread,
Mar 12, 2020, 2:47:17 AM3/12/20
to Loxone English
On Wednesday, 11 March 2020 10:25:13 UTC+1, Paulo Matos wrote:
Is this the alternative using Grafana?

These are my scripts to import Loxone stats files into InfluxDB. Ideally I guess you would want to run those one time to pull all your historical data in and then setup ioBroker to keep things up-to-date from that import point on.

Robin

Paulo Matos

unread,
Mar 12, 2020, 1:00:17 PM3/12/20
to Loxone English
Thanks.

Have you written anything on how to setup the Grafana dashboard? Mainly, how to get influxdb regularly updated with data from Loxone?

Paulo

Rob_in

unread,
Mar 13, 2020, 6:24:06 AM3/13/20
to Loxone English
On Thursday, 12 March 2020 18:00:17 UTC+1, Paulo Matos wrote:
Have you written anything on how to setup the Grafana dashboard? Mainly, how to get influxdb regularly updated with data from Loxone?
 
No... bit I have now... ;)


I didn't say anything about Grafana dashboards, etc. but that's pretty easy and I'm sure there's plenty of great HowTo docs on that already.

HTH,

Robin
 

Paulo Matos

unread,
Mar 16, 2020, 4:12:29 PM3/16/20
to Loxone English
Thanks for the write up - I will give it a try this coming weekend.

Paulo

Andras

unread,
Mar 22, 2020, 11:00:58 AM3/22/20
to loxone-...@googlegroups.com
Wow, nice to see someone actually got use of it. I really didn't want to add iobroker and sorts, that's why I turned to Robin's websocket based solution and improved it (move to TypeScript, add Docker). Recently, I have moved it to a docker container and running on a Pi. I am about to add some buffering to it, so if influx goes down for few minutes, no data points are lost.

I have this script running for more than a year now, without any issues.


On Tuesday, February 25, 2020 at 8:33:18 AM UTC+1, Tom B wrote:
I am using this node script by Andras (also active here): https://github.com/andrasg/loxone-influx - it is based on your statistics importer script. 
I have it running as a docker instance, so far no issues with reliability but then again it is only running for a week now. 

The advantage is flexibility in the tagging setup, so if you plan to improve that for IOBroker, it seems like a perfect solution. 

Tom 


On Sat, Feb 22, 2020 at 7:24 AM Rob_in <rain...@gmail.com> wrote:
On Friday, 21 February 2020 10:39:56 UTC+1, Jan De Bock wrote:
This is what I just did with UDP. 

'Robust' implies never using UDP. In the process I describe Loxone -> ioBroker is TCP websockets and ioBroker -> InfluxDB is also via TCP.
 
SQL is more robust and extensive than influx, hence my interest there.

Not going to get into the whole debate about which time series database is best, but if you want to use PostgreSQL knock yourself out.

Robin

--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-...@googlegroups.com.

Hidde Beumer

unread,
Mar 22, 2020, 11:48:09 AM3/22/20
to Andras, Loxone English
Andras,

Any chance you can share the docker container and latest updates with me/us? I like to run the docker containers on my synology.


Hidde

Op 22 mrt. 2020 om 16:00 heeft Andras <andra...@gmail.com> het volgende geschreven:

Wow, nice to see someone actually got use of it. I really didn't want to add iobroker and sorts, that's why I turned to this websocket based solution and improved it. Recently, I have moved it to a docker container and running on a Pi. I am about to add some buffering to it, so if influx goes down for few minutes, no data points are lost.

I have this script running for more than a year now, without any issues.

On Tuesday, February 25, 2020 at 8:33:18 AM UTC+1, Tom B wrote:
I am using this node script by Andras (also active here): https://github.com/andrasg/loxone-influx - it is based on your statistics importer script. 
I have it running as a docker instance, so far no issues with reliability but then again it is only running for a week now. 

The advantage is flexibility in the tagging setup, so if you plan to improve that for IOBroker, it seems like a perfect solution. 

Tom 


On Sat, Feb 22, 2020 at 7:24 AM Rob_in <rain...@gmail.com> wrote:
On Friday, 21 February 2020 10:39:56 UTC+1, Jan De Bock wrote:
This is what I just did with UDP. 

'Robust' implies never using UDP. In the process I describe Loxone -> ioBroker is TCP websockets and ioBroker -> InfluxDB is also via TCP.
 
SQL is more robust and extensive than influx, hence my interest there.

Not going to get into the whole debate about which time series database is best, but if you want to use PostgreSQL knock yourself out.

Robin

--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/loxone-english/61c9dcfd-a7b1-4680-9fa4-6bffc8d629dd%40googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Loxone English" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/loxone-english/q8_9Uh-Qvak/unsubscribe.
To unsubscribe from this group and all its topics, send an email to loxone-englis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/loxone-english/647054ec-4f19-4f7a-b3a4-c817941b310e%40googlegroups.com.

Sven Van den brande

unread,
Mar 22, 2020, 2:06:59 PM3/22/20
to Loxone English
Would be a good thing. A shared docker container. :)
Andras,

To unsubscribe from this group and all its topics, send an email to loxone-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/loxone-english/647054ec-4f19-4f7a-b3a4-c817941b310e%40googlegroups.com.

Andras

unread,
Apr 17, 2020, 12:50:39 PM4/17/20
to Loxone English
Hey Hidde and Sven,

You can find all you need here: https://github.com/andrasg/loxone-influx

Basically you will need to:
1) clone the repo to a computer
2) build the container using docker build
3) run the container from the image you built

Cheers,
András


On Sunday, March 22, 2020 at 4:48:09 PM UTC+1, Hidde Beumer wrote:
Andras,

To unsubscribe from this group and all its topics, send an email to loxone-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/loxone-english/647054ec-4f19-4f7a-b3a4-c817941b310e%40googlegroups.com.

Andras

unread,
Apr 17, 2020, 1:00:52 PM4/17/20
to Loxone English
Btw, added the feature to temporarily buffer incoming loxone events in case influx goes down.

Tomasz Nowak

unread,
May 5, 2020, 8:18:41 AM5/5/20
to Loxone English
Robin,
Did you figure out how to deny access rights to WeatherServer on that Loxone user that is used in ioBroker for InfluxDB stats?
I have tried everything including setting WeatherServer and Weather Data permissions to No Access within new v11 permissions panel, but I still get in ioBroker whole tree of WeatherServer objects (hundreds).
Can't figure out how to take it under control and I begin to think this impossible.

T.

Tom Bernaerd

unread,
May 5, 2020, 1:12:52 PM5/5/20
to Tomasz Nowak, Loxone English
Tomasz, 

I think you can just remove the entire tree in iobroker if it bothers you. Just did, took a few minutes but it is gone now. 

Tom 

--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-englis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/loxone-english/60109d17-c657-42db-93fd-af7fecb67cdc%40googlegroups.com.

Tomasz Nowak

unread,
May 5, 2020, 1:14:51 PM5/5/20
to Loxone English
I've tried that too, but seems it recreates itself after every restart of Loxone adapter instance.

T.

Rob_in

unread,
May 6, 2020, 2:24:33 AM5/6/20
to Loxone English
On Tuesday, 5 May 2020 19:14:51 UTC+2, Tomasz Nowak wrote:
I've tried that too, but seems it recreates itself after every restart of Loxone adapter instance.

I thought there was an option to not do that... but now I come to look can't find it :(

Anyhow... because of the very coarse nature of Loxone permissions I have 3 groups for this:

- API
- User
- User+API

Kindof self explanatory but stuff I want to show up in the Loxone web interface/App gets 'User' and stuff that I want ioBroker to see gets 'API' and stuff that I want both to see get 'User+API'.

I don't have a Loxone Weather Server (actually using WeatherUnderground ioBroker module now) but surely the above method will work if you just assigned it's objects to 'User' only?

Robin

Tomasz Nowak

unread,
May 6, 2020, 6:26:35 AM5/6/20
to Loxone English
I don't have Loxone Weather Server also - I'm using LoxBerry Weather plugin to fake it.
My current setup for grafana stats is:
- dedicated ioBroker user
- Stats group with ioBroker user only
- access only to api (webinterface/apps) and single Humidity data for that Stats group
- no access to anything else
- denied access to Weather server and Weather data
And I still get hundreds of weather data via API.

Please see images attached

T.


Clipboard01.png
Clipboard02.png

Daniel Feist

unread,
May 6, 2020, 9:34:07 AM5/6/20
to Tomasz Nowak, Loxone English
Any one used one of these for running ioBroker (or LoxBerry) for the loxone->influxDB export?  Might not justified price-wise, but would look pretty neat on a DIN rail. They also have various extensions with different IO options.

image.png

--
You received this message because you are subscribed to the Google Groups "Loxone English" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loxone-englis...@googlegroups.com.

Rob_in

unread,
May 7, 2020, 2:07:30 AM5/7/20
to Loxone English
On Wednesday, 6 May 2020 12:26:35 UTC+2, Tomasz Nowak wrote:
- dedicated ioBroker user
- Stats group with ioBroker user only
- access only to api (webinterface/apps) and single Humidity data for that Stats group
- no access to anything else
- denied access to Weather server and Weather data
And I still get hundreds of weather data via API.

What about when you login to the web interface/app as that ioBroker user? Still see the weather info?

Sounds like a permissions bug with Loxone TBH. You are denying access to weather data but the user still sees it. Try logging a bug report.

Robin

Rob_in

unread,
May 7, 2020, 2:13:59 AM5/7/20
to Loxone English
On Wednesday, 6 May 2020 15:34:07 UTC+2, Daniel Feist wrote:

That does look nice. But... price... ouch!

Just type "raspberry pi DIN rail enclosure" into Google for many more affordable options :)

For a similar kind of 'system' this looks pretty interesting and *much* cheaper:


P1020614.jpg


Robin


Tomasz Nowak

unread,
May 7, 2020, 8:37:11 AM5/7/20
to loxone-...@googlegroups.com
Yes, when logged in to web interface I still see all weather info.
This seems to be bug. But I don't feel like being in a good place to report it - I don't pay for Loxone weather service so I feel I shouldn't expect support in this area also (just being fair).
Perhaps someone with Loxone weather subscription will report it instead. Anybody?


BTW, as for rail-mounted Pi I would recommend this: https://www.stv-electronic.de/produkt/smart-manager-4-0-mit-32gb-emmc-flash/

T.

Paulus

unread,
May 12, 2020, 10:31:12 AM5/12/20
to Loxone English
Andras, just installed your scripts thanks but I get an error "Cannot send point to Influx", is this a db permission issue. 
Paul

Andras

unread,
May 18, 2020, 9:38:49 AM5/18/20
to Loxone English
Hey Paul, not sure, could be any of the following:
- access to db is firewalled
- user/pass permissions issue
- database name (this is case sensitive)

I'd check these.

You could try modifying this line to add some logging about the reason why it failed: https://github.com/andrasg/loxone-influx/blob/master/src/InfluxStore.ts#L86

Rob_in

unread,
May 19, 2020, 3:02:41 AM5/19/20
to Loxone English
Hi,

Seems like this has morphed into a 'why doesn't this script work' discussion, which is precisely what the approach I was describing was supposed to avoid. No scripting!

Could whoever moderates this group please move those replies to their own thread? Failing that, may I suggest you guys start a new one?

Thx,

Robin

tarun

unread,
May 19, 2020, 9:22:04 PM5/19/20
to Loxone English
Hi Rob - would you mind sharing the grafana dashboard you made?

Rob_in

unread,
May 21, 2020, 1:37:12 AM5/21/20
to Loxone English
On Wednesday, 20 May 2020 03:22:04 UTC+2, tarun wrote:
Hi Rob - would you mind sharing the grafana dashboard you made?

I could, but it would be pretty pointless as you will probably want to name your measurements, rooms, etc. somewhat differently. They are super easy to setup exactly how you want. Just search for some Grafana tutorials if you're not sure.

Cheers,

Robin 

John Verdicchio

unread,
Jun 8, 2020, 4:48:28 PM6/8/20
to Loxone English
Robin
I read about your use of ioBroker and decided that my life wouldn't be complete without a complete record of my house's temperatures, humidity, power usage etc. So, a new Raspberry pi 4 and some free time...
Some thoughts and findings:
1. The out-of-the-box versions of influxdb and grafana on the pi image were quite old and I never got them to work e.g. influxdb has a command called influx - this did not exist. However, update to the latest versions from the respective websites and all was well.
2. The point about adding an alias in iobroker's objects to make them recognizable is vital, shame I'd gone through several objects before realising I'd need to go through them all again with the alias set.
3. iobroker documentation is a little sparse.
4. grafana is really cool - I might start working out some proper heat loss calculations now.

So thanks very much for that introduction.

budulinek

unread,
Jun 18, 2020, 8:38:19 PM6/18/20
to Loxone English
Thanks Robin for the suggestion. For long time I have been thinking about a solution for connecting Loxone with InfluxDB/Grafana. There is a bunch of websocket scripts (incl. yours), but I did not want to do all the manual configurations (such as adding UUIDs to scripts...). I was also aware of the UDP log solution and its limitations.

After reading this discussion, I have decided to try ioBroker - websocket solution which does not require scripting. But I was quite disappointed. Sure you do not need scripts. But you need one new service, two plugins and a dozen clicks in ioBroker just to link Loxone data with InfluxDB (create alias, click "enable" to link Loxone "object" with InfluxDB...). Sadly, the process can not be automated and you have to go back to ioBroker whenever you want to add new measurement.

So, at the end of the day I have settled with the UDP solution, revising the original script by Jan De Bock (thanks Jan!!). Going back to your complaints about the UDP solution:

2. One can use Loxone UDP logging (or SNMP traps or other such things) and a script to receive these events and munge the data (Loxone insists on putting timestamps on their UDP logging for example) before putting in InfluxDB. The problem with this is that it requires some kind of proxy script


Yes, but with UDP logging you only configure the script once!  You do the rest inside Loxone Config: you can add new measurements, configure tags inside Lox Config. No need to edit scripts again. On the other side, with the websocket solution, you need to manually edit scripts (add UUIDs) whenever you want to add a measurement. The same with ioBroker - you have to go back to ioBroker whenewer you want add / edit a measurement (add UUID). 

and UDP transmission is not guaranteed.


As long as you are inside your own LAN, transmission itself is not an issue IMHO. 
 

Loxone does not have a periodic send on UDP logging either


Yes it does!! You can easily configure periodic logging with Analog Memory and Pulse Generator.


OK, so here is my UDP solution, including tutorial:   https://github.com/budulinek/easy-loxone-influx
  • easy to setup
  • you only edit the script once (during installation), the rest is done in Loxone Config
  • no need to mess with users and permissions in Loxone Config (because this is a simple UDP listener, not a websocket client...)
  • if you need them, custom measurement name, custom tags (configured via Loxone Config)
  • periodic logging
Cheers

Budulinek
Reply all
Reply to author
Forward
0 new messages