IR eye for Kamstrup electricity meter

Hi

I noticed a review on AliExpress when searching for an IR eye - and wonder if it could be a.member in here?

I have a Kamstrup 382Lx7 meter as well, but my ESPhome implementation of extracting data is not stable, so I would like to hear what other people do - e.g. what software to use with an IR eye and talking DLMS to the meter via IR…

Anyone ?

Regards
Brian

Kamstrup 382Lx7 is a version that comes with a built-in RF module, so maybe you can contact your provide and get an access key for that module.
The modules usually provide different access layers, so you can just get a read access.
In Denmark the providers are required to give such access.

I am not aware of a radio module in the meter, but I will try to contact the provider in order to get more information…
I short - DLMS/COSEM seems yo be a protocol, that is unnecessary complex in order to achieve a relatively simple task/job …
An article (in Danish - use google translate) that has a perspective on these (un)intelligent meters: Usmarte elmålere | PRO

1 Like

Search for integrated radios.

All the Kamstrup meters have a radio but it is the radio that transmites the data to the operator. They are simply small mobile phones with a data modem. They use the GSM network to send very small amounts of data.

I have not yet hacked mine but it seems you either have an IR serial or a wired serial connection option.
And you need an encryption key to use it which you can get

I asked my provider - they are not able to assist with information about the radio as an option for the user to get the usage data.

At least the communication on the optical eye on my 382Lx7 is not encrypted … But my solution with an ESP32 in ESPhome to grab the data is not so stable, so I am trying to figure out if it can be done in other ways…
For some reason I get fewer CRC errors in my ESP32 setup using the reverse engineered Kamstrup Meter Protocol , if I set the baud date to 9400 (even though the meter should run 9600bps)

Thanks for the article. It is really amusing and the same time saddening that this is the general approach to smart metering.

Soon, I am going to struggle with similar issues on an Iskra AM550…

One of the best is a Github repo’s read me from the comments:

Be warned that the DLMS protocol stack is created by a succession
of morons, doing one stupid thing after another for several decades.

But the reason why this mess was created is not referenced in the article…

The EU has a recommendation on smart metering and a directive as well. And both contains rules of data protection for privacy. The reason for encryption, but not for the authentication…

https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32012H0148

https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=celex%3A32019L0944

And updated version of the directive:

https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX%3A02019L0944-20220623

The interesting part is Article 20!

The authentication is used to differentiate users, because users can have different rights and views.

Exactly, unnecessary complex…

The meters should be spitting out basic information without any authentication, just encrypted. That is actually part of the EU recommendation.

And if you read the article and below the comments, you can see that this whole idea went too far, that anybody could explain it why is it necessary.

It is clear that with the authentication the DSOs are afraid that clients would reprogram the meter and rather blocks them to have access to it, because it is too complex that nobody knows how exactly it is working.

Disregarding the fact that the meters can have multiple user levels, as you stated and has a wide range of logging capabilities as well, as part of the requirement of the EU recommendation.

If you search for OpenSource projects around the Internet regarding DLMS and COSEM, nobody really wants to touch it and support it. Rather staright ahead says, no support for encryption…

Unnecessary complex, that’s what it is.

Yes it was my review. Here is fork from @golles /ha-kamstrup_403 with added 382 support.

1 Like

Oh… Nice - except that for me, it is not possible to connect the IR eye from my Kamstrup 382Lx7 electricity meter directly to the host running HA, as they are in opposite ends of the home…
So a solution based on ESPhome, or maybe a RPi Zero (connected via MQTT or similar) would be more usefull for me… But I will try to look at the code to see if it somehow can be adopted to fit my use-case…

Maybe use ser2net?