-
-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Request: Support for Kamstrup Omnipower meters using GPK11 encryption key #126
Comments
I propose we first establish whether the meter provides data at all, as there has been cases of meters not having the HAN port open despite the grid company insistance. Does the LED show a blue light flickering for around 1 second every 10 seconds? |
Theres a red flash every 2-3 seconds, and the HAN status In the web ui is red. |
If there are no blue flashes there is no incoming data. The red flashes indicate the same as the red HAN status. There is a similar case in one of the threads here, the problem turned out to be that the port was not activated after all. |
Here: #115 |
If using a multimeter to test if my meter is sending data, then what should i expect to read? |
And is that the same data that a Smart-me module would utilize? or is it another type of data? |
Data is pushed from the meter, not pulled. The DATA_IN pin (2) is not used. |
So... Result: a steady 3,29v for the whole 35 seconds. Not a single deviation at all. I assume this means no data is being sent from the meter. And if I used a smart-me module it wouldn't work either, correct? According to the grid company my meter should be ready for a smart-me module, but it doesn't makes sense to me at all. |
So - no data. You seem to have the same situation as the guy in #115 I would contact the grid company and ask them to double check that the HAN port is acivated. |
well.. decided to buy a smart-me module for testing... then I can tell the grid company, that even though they say a smart-me module will work, it doesn't (Or probably wont work) They state they don't have access to the feature in the Kamstrup software to enable/disable the HAN port, but a smart-me module works........... without data? |
Sounds like an expensive way to prove there is no data. I think the other guy was in contact with Kamstrup directly in some way. Maybe ask him in the other thread? |
Well yes it’s the expensive way…
So the smart me module was on my doorstep this morning…
And the result really bugs me 😔 plugged it in, joined Wi-Fi, added the gpk11 key and right away it reads data…. So there’s something different with the amstomqttbridge and smart-me module on how they get the data and the gpk keys.
I’d still rather use the pow-k module over the smart-me module, so let me know if It may be possible or if I can take part in some debugging
Hent Outlook til iOS<https://aka.ms/o0ukef>
…________________________________
Fra: ArnieO ***@***.***>
Sendt: Wednesday, October 13, 2021 8:27:50 PM
Til: gskjold/AmsToMqttBridge ***@***.***>
Cc: Heine Madsen ***@***.***>; Author ***@***.***>
Emne: Re: [gskjold/AmsToMqttBridge] Request: Support for Danish meters (Omnipower) using GPK11 key (#126)
Sounds like an expensive way to prove there is no data. I think the other guy was in contact with Kamstrup directly in some way. Maybe ask him in the other thread?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#126 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ALVECIEMUY6J2LXFCTIO473UGXFSNANCNFSM5FOGQJYQ>.
|
Well, this was surprising. There are around twenty Pow-K boards running in Denmark now, and I have not seen this problem before. The only idea I can think of is that the meter needs an "enable" signal on an input pin to ensure the meter outputs data. This is not specified for the Kamstrup meters, but is used in the IEC 62056-21 interface standard used in for instance Sweden and Netherlands (see my overview here). Those interfaces have a "Request" input that must be set high from the device in order to get data from the meter. The Kamstrup meter has one input pin, see this document, which is pin 2 (figure 5): The document states (page 9) that pin 2 is pulled high inside the meter by an 82k resistor. It also states that the pin is used for "serial communication of data to the meter", which is in most countries not used (disabled in the meter firmware, I assume) - to eliminate the possibility of the user being able to do whatever could be done from this port. This is why I chose to have pin 2 on Pow-K not connected. Now I can only speculate:
However, pin 2 is specified for maximum voltage of 3,3V, so you cannot connect it to pin 1. This is what you could do if you're comfortable with trying this and have access to a suitable resistor: Connect a resistor (I would try 10k, but anything smaller than than 82k should work) between connector pin 2 and 3,3V on the Pow-K board. If you're equipped to solder it in that is fine, just be careful not to short circuit the connector pins, and also do not apply too much heat close to the large capacitor! (Note that there is an unfortunate error on the silkscreen of the card: Vcc and GND on the large capacitor are switched.) |
Thanks for that really nice and detailed reply! :) I'm fairly confident in soldering things. Can you possibly link me to a resistor? Just so I order the correct one :) |
I would recommend a small kit, like this one: https://elektronik-lavpris.dk/p95985/k-res-e3-modstandssortiment-e3-480-stk/ (I am not familiar with Danish webshops for components, this was just the first one I found on google - there might be others that are better of cheaper, I have no idea. There might also be stores close to you where you can get such stuff.) |
Great.. just ordered... I might have some resistors laying around bit will have to check their values. I also assume i need to discharge the super-cap before doing anything... any how-to's on that? or should i just leave it unplugged for some time? |
Yes, that is the safe and simple way - just leave it unplugged for some time. It will self discharge. |
Yes that will work. In fact you could connect just a wire (no resistance), but in case you make a mistake with the connection it is safer to use a resistor. |
That looks good. |
Still no blue flashing, only red flashes and red status in the ui |
What makes this strange is that what you reported earlier (multimeter measurement) indicates that there is no data coming from the meter. However, the Smart-me unit works as expected and reads data from the meter. The blue pin on the LED is directly connected to the incoming data signal, so it will flash providing there is voltage on the board. Which there clearly is - as the ESP8266 is up and running, generates the UI and generates red flashes on the LED. So let us assume the board does receive data from the meter, and look for potential errors that could prevent the blue LED from flashing. Could you be so kind as to check two points:
|
So i tried checking the led... I can't measure any short circuit.... Just thinking out loud and with minimal knowledge about the meters... could I be that the smart me module gets the data from the meter wirelessly? And why does it only need one gpk key and the amstomqtt needs two gpk keys? |
Regarding the keys: #73 (comment) Just thinking out loud here, could it be that the smart-me module asks the meter for data rather than passively receiving? |
@gskjold not sure how to tie this with #73... But... i do recall that i might have read somewhere on the internet, that smart-me works by pull and amstomqttbridge works with push'ed data. Would i be possible to implement a pull meter to the amstomqttbridge? |
Quote from the linked comment from #73 : "It seems the key they provided me was for the Smart-Me module. They're looking into getting me the other keys now." If we are to implement data pull from the meter, I would need to know how to handshake the meter to receive data. If you have found any information related to this, let me know. |
Well.. that might be a dead-end :( A KMP protocol... Will try to reach out to Kamstrup and see if they are willing to hand out some documentation for this protocol. |
I think you are better of asking your grid company for the GPK60/61 keys instead, like @mikfoo did. Referencing this for the future (in case we ever figure out how this works): https://github.com/MTrab/Kamstrup @ArnieO is the meters RX pin connected on Pow-K at all? |
@lmcemaj - how do you request the needed keys? I just ordered a Pow-K+, so now would like to prepare for receiving and installing it. :-) |
I just wrote an email to them |
Should Pow-K+ be powered through microUSB when used with Kamstrup OMNIPOWER? Manual says:
But since Pow-K is not the same as Pow-K+ I'm in doubt. This is my meter: and this appears to be my problem: Seems like approximately 5 mm for the microUSB connector. And they are usually several cm. Did anyone successfully install this module in DIN-rail OMNIPOWER meter? @ArnieO - perhaps you could help/elaborate? Unfortunately I didn't foresee this and can't seem to find detailed mounting instructions in the different manuals I downloaded. |
@jlaur Pow-K and Pow-K+ take the power they need from the meter. The USB connector can be used if you want to power it on its own for configuration. It can also be used for reflashing the ESP if needed. There is a QR code on the protective bag that takes you to this video. It shows how to install and configure it: https://amsleser.no/blog/post/17-video-how-to-install-and-configure-your-pow-k |
I'm curious. I was fairly sure that mine was a Kamstrup Omnipower meter, and since my house is from 2016 i expected it to be "new enough". Are there an age cap on the Kamstrup Omnipower meters for it to be supported? Dinel just informed me: "Den måler du har installeret understøtter kun KMP protokollen via HAN modulet. Data er ikke krypteret. Which roughly translated means: The installed meter only supports the KMP protocol, using the HAN module. The data is not encrypted. I suspect the optic eye being the blinking light on the front. From what i can read here, KMP is proprietary and won't be supported - which leaves me with a bit of a dissapointment :| |
AFAIC it's not about "how new your installation is" but "how new the installations in the area" is. Dinel told me that it's because the meters communicate with each other so can't install a "meter model x" in an area where all the other meters are "model y"... :) But I'm no expert... I'm pretty sure the Omnipower meters says "Omnipower" on them. I recently had my meter replaced and they still installed a model 382MxG. |
That makes sense - Might be me, but i thought the 382MxG was an Omnipower device, and that Omnipower was basically an umbrella with multiple devices in a series. This was based on the official "sales material" stating Traslated turns out there was a port, but apparantly not that "open" as i expected :) So seems i took a wrong conclusion somewhere. |
Trying to return to the issue title.... Is there anything we can do to make the GPK11 work? |
I share your frustration, and understand there is a large number of "older" Kamstrup meters in Denmark that cannot be configured for Data push (which is the core issue). We will discuss the subject internally and get back to you in this thread. |
Update as promised: Following a technical dialogue with Kamstrup, we see a potential way to solve this. The need for this update has increased since this discussion started, as we have learned that the solution from Smart-Me is no longer available. |
Sounds good and definantly interested in trying it out. 👍 |
Question, does anyone of you have the GPK11 key? I am wondering if this is a HEX formatted key or just plain text. |
In this video the guy says he received the key via email an just copy/pastes it into the textfield. |
Perfect, thanks, this is text yes, but represents HEX. Now I know what I am dealing with at least |
Hi there, I also do have a Kamstrup Omnipower 3 phase smart meter in Austria. My (rather small) energy provider has no knowledge about the HAN interface and told me to contact Kamstrup directly. I sent them my serial number and the name of the energy provider and received following answer: leider kann bei Ihrem Zähler keine HAN-Aktivierung erfolgen, da der Zähler eine nicht passende Firmware besitzt (Upgrade nicht möglich). Unfortunately the HAN port can not be activated on your meter as the firmware is not suitable (upgrade not possible). |
Your energy provider have to replace the smartmeter in case no HAN port is supported. |
Hi @tauchmi, |
@Sonnengruesser @tauchmi : Are your meters a Kamstrup Omnipower model 382MxG? We are working on finding a solution, as there is a large number of such meters in Denmark that we want to be able to serve. The challenge is that model 382MxG cannot be upgraded to do data push. The only option to read from them is by using a Kamstrup proprietary protocol (KMP). We have tried reading them by using DLMS protocol - but as @Sonnengruesser points out: To access the interesting data, a special encryption key is needed that the grid companies do not have access to. So that turned out to be a dead end. 😞 We are now reverting our efforts towards using KMP. The challenge is that we need to sign an NDA with Kamstrup that does not allow us to publish source code that shows the implementation of the KMP protocol. We are looking into solving that by not publishing that sensitive part of the source code, but instead linking in a compiled binary section for that part. This means that users that need code for 382MxG will probably not be able to build the binary from source. This is currently the best compromise solution we see, given the need to use the KMP protocol for those meters. (To those of you that now want to point out that some individuals have already published Python code etc. for the KMP protocol on private Github repos: Yes, we know that. But we are running this as a business, so we cannot work like that. And we want to maintain a good relationship with Kamstrup.) |
Thank you! So I simply do not understand the message you received from your grid company. My Kamstrup model number is 684-11-31B-N24-3101-040, just as an indication. |
The message was from Kamstrup Austria. I can only guess, maybe they don't care because my energy provider is too small? I will try to get more information. |
You're right, I misread your first message - sorry for that. That answer was from Kamstrup Austria. There was a similar situation in some Danish grid companies two years ago: The meters could not be upgraded to do "Data push", and a proprietary protocol was needed to read them. It is resolved now, probably because Danish legislation required "open protocol" on the HAN ports, so I think (but not 100% sure) what happened is that the grid companies upgraded their service agreement with Kamstrup, and the meters were then upgraded to do Data push. |
Still a problem for many danish smaller grid providers. I have one of the legacy 382m meters. It only supports pull. And KMP protocol. So im using an esphome based solution until they decide to change the metersDen 19. dec. 2023 kl. 12.33 skrev ArnieO ***@***.***>:
The message was from Kamstrup Austria. I can only guess, maybe they don't care because my energy provider is too small?
I will try to get more information.
You're right, I misread your first message - sorry for that. That answer was from Kamstrup Austria.
It could indeed be that your energy provider has not bought that part of the package from Kamstrup, so that firmware upgrade is indeed not possible. In that case, your energy provider should be able to answer.
There was a similar situation in some Danish grid companies two years ago: The meters could not be upgraded to do "Data push", and a proprietary protocol was needed to read them. It is resolved now, probably because Danish legislation required "open protocol" on the HAN ports, so I think (but not 100% sure) what happened is that the grid companies upgraded their service agreement with Kamstrup, and the meters were then upgraded to do Data push.
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: ***@***.***>
|
Correct, the 382 meters cannot do data push. We're working on finding a solution to read them. #126 (comment) |
Update regarding supporting Kamstrup 382M meters will be provided in this thread: #725 |
@tauchmi : We are now getting close to finding a solution for the Kamstrup 385M meters, see #725 (comment). So we would like to find out whether this solution can also be used on your Kamstrup Omnipower 684-11-31B-N24-3101-040, which Kamstrup Austria has said cannot be upgraded to push data. Do you have a contact point at Kamstrup Austria, or can you help us with the dialogue (mein Deutsch ist leider ganz sclecht...)? EDIT: Followed up here: #725 (reply in thread) |
Hi...
I'm not sure this is even possible, as i have no deeper knowledge into this topic.
The case is, that i bought a Pow-K (Kamstrup) module from amsleser.no.
I have fittet it into my Kamstrup OmniPower meter and have supplied the GPK60 and GPK61 keys, but i get no data.
According to my power provider they state that it works with the Smart-Me modules using GPK11 key.
the provider does not have access to that part of the Kamstrup software where they can enable that feature.
So my request is, can this software use a GPK11 key to get data?
The text was updated successfully, but these errors were encountered: