DSMR Reader Add-on for Home Assistant

I do this to export data from DSMR to influxDB for example:

dsmrreader-export behing --to-influx-database is database you have in InfluxDB


. /app/bash.sh

./manage.py dsmr_influxdb_export_all_readings --to-influx-database dsmrreader-export

or when you want do it in batches:

./manage.py dsmr_influxdb_export_all_readings --to-influx-database dsmrreader-export --max-batches 100

The addon wil be updated a few days after the DSMR software and it’s Docker release by xirixiz. I could automate this but i want to make sure it works before everybody pushes the update button :slight_smile:.

1 Like

2021-03-13: 0.2.0 Update to DSMR-reader v4.13.0 (amd64 & arm64v8 only for now)

2 Likes

2021-03-18: 0.2.1 Update to DSMR-reader v4.13.0 (arm32v7)

1 Like

Exactly this i was hoping someone would create eventually. Great stuff!

I don’t know if i miss something, but i used to have both the power delivery and consumption on the dashboard page (when i was using the DSMR reader via docker), but right now i only see the delivery (green) info, i see the value fluctuating so i know the data is coming in. If i go to live view i see the graph filled with both the delivery and consumption. Is this a bug?

Tried on my iPhone 12, Macbook pro with Safari and Google Chrome also.

Trying to get this addon working on my HAssOS VM, but at step 7 I’m unable to login. This is the error when I get when trying to access http://myhassosip:7777/admin/:
This site can't be reached. ERR_CONNECTION_REFUSED

HA Supervisor System log shows this when installing the timescaledb addon:
21-03-20 14:14:52 ERROR (MainThread) [supervisor.api.security] Invalid token for access /host/info

Subsequently, the Watchdog starts giving warnings about dsmr_reader:
21-03-20 14:17:35 WARNING (MainThread) [supervisor.misc.tasks] Watchdog found a problem with 0826754b_dsmr_reader!

This message repeats every minute.

Update - apparently I had a configuration error in de TimescaleDB addon, I only added - dsmrreader under databases: and not also under timescale_enabled:. After adding this and restarting the TimescaleDB addon, the TimescaleDb Log shows
[15:38:44] NOTICE: TimescaleDb is running!

I also restarted the DSMR Reader addon, but still I’m unable to access http://myhassosip:7777/admin/.

DSMR Reader Log shows:
nc: getaddrinfo: Name does not resolve

Update2:
On the configuration page of TimescaleDB I’m seeing this under ‘Network’:
Container: 5432/tcp
Host: Disabled

Perhaps I should put something after Host? If so, what? localhost? 127.0.0.1? Something else?

Update3:
Apparently the field under Host only accepts a single number as valid entry, so I’m guessing that’s a badly labeled ‘Port’ field.
Looking at the configuration of the DSMR Reader addon, I’m seeing this:
DJANGO_DATABASE_HOST
77b2833f-timescaledb

Perhaps this is where I should put ‘localhost’ instead of ‘77b2833f-timescaledb’?

Update 4:
Tried changing 77b2833f-timescaledb to both localhost and 127.0.0.1. In both cases, DSMR Reader logs shows this after a couple of minutes:
[ FAIL ] Database connectivity couldn't be verified! Please verify your settings. Exiting...

Update 5:
Fixed it by applying the solution of this post:

So apparently the default host in the DSMR Reader Configuration (77b2833f-timescaledb) might not match the actual internal hostname of TimescaleDB.

Not entirely sure what you mean, it’s just that you are producing more energy than you are using right? So what your seeing is correct? You can check again now when the sun is going down?

First you need to make sure TimescaleDB is running correctly, you only need to add the database to the databases entry, not timescale_enabled. After this is running properly you can check it’s internal hostname:


That is the name which should be used in the DSMR reader addon.

What i mean is I used to see a green icon and a red icon. The green icon shows the data regarding solar panels the red one the live electricity I’m using. Now I only see the green icon and missing the red one. If that makes sense :grin:

Oh i really don’t know. I think you can better direct your question to the author of DSMR Reader. Maybe you need to adjust your settings?

Guys, I’m new to this topic, so may I ask some really stupid/beginner questions? Hopefully they’re also useful for others like me.
I read the add-on Github and went through some of the discussions in the forum (there are more than one, which is also not helping). This info must be somewhere, as many of you did it already, so a pointer to the correct places would be really helpful.

  1. is there a nice intro and overview (diagram) of the flow and how this all works?
    Do I need to connect a RPi to the P1 port, or do we have a hook into the meter logic or a API that we can call to extract the data “over the air”?
  2. Assuming (1) is a physical connection, then to my understanding I can use a RPi locally in the utility cupboard, that runs “ser2net”, and I can connect remotely from my Home Assistant RPi to this local RPi to pull the data into HA?
    • Any write-up how to set up and configure the local RPi that connects to the meter?
    • Any hardware requirements for the local RPi? I have a really old Raspberry Pi 1B laying around and collecting dust. Or do I need more horsepower than that to pull this off?

Thanks…

for me the solution was , the hostname was different as proposed in the help files

in the config timescaledb see below

Hi Johan, you can start with the official documentation of the DSMR Reader project, see for example the hardware setup here:https://dsmr-reader.readthedocs.io/en/v4/intro.html#hardware-requirements

An Raspberry Pi 1B is not that powerful but you could use it to perform only the datalogger part. In that case you hookup the P1 port to the Raspberry Pi 1B and manually install either https://dsmr-reader.readthedocs.io/en/v4/installation.html#option-d-install-datalogger-only, use my DSMR Datalogger addon if you want to use HA (don’t know how it runs on a Raspberry Pi 1B) or indeed use ser2net. But in any case, yes you need to connect physically to the P1 port.

Based on above you then can setup the receiver part (The full DSMR Reader Addon).

1 Like

Is there a way to integrate a water meter, or maybe even solar panels? The dsmr reader is a great tool. So kudo’s for making this.

2021-03-26: 0.3.0 Update to DSMR-reader v4.14.0

3 Likes

Kudo’s need to go to Dennis, the author of DSMR Reader.

There is no standard digital system to monitor the watermeter. What do you mean with solar? It’s already registering the electricity generation?

It was a bug. After updating the addon both delivery and consumption is correctly presented.

I mean to measure how much your solar system is providing. I know you can see how much you are providing back to the grid. But doesn’t it deduct it from what you are using? So lets say you used 4kwh and deliverd 5kwh it will say 1 kwh right? Haven’t got any solar panels just yet. But will have them soon. And was looking for an option in DSMR reader. But even without solar panels and water meter it is a great tool.

Hi i’m running dsmr reader and progressDB over portainer addon in HA
I want to switch over but dont want to lose any data

How should i do this?

Install the repostitory and then this addon
And then instal the timescale db addon
And then how do i get the current db into the timescale one
The nstop the old dsmr reader, and start the new one?

It does register and show distribution over phases. See pic.
L1+ and L2+ is consumption. L3- is production.

Usually you can integrate your inverter into HA. These sensors will provide production data too.