-
-
Notifications
You must be signed in to change notification settings - Fork 17
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
Support Watermeter (Kamstrup Multical 21) #333
Comments
Okm,, in fact usage questions are hetter discussed in Forum then on GitHub, bit some infos: 1.) the signon sewuence you told is the default, so remove the one you entered because so it will send wrong stuff Ideally remove the instance and create new one to get back defaults. Then only change protol to SML and bare minimum changes. Thenset the instace to debug loglevel and show the log - there you see whats received |
I'm sure it's not SML. The poweropti supports SML and IEC1107. |
Ok, then show a debug log please and we will se what the device sends out |
That's the thing. There is nothing coming back with the setting I chose. |
NOT THE ANSWER, BUT SUGGESTION YOU MIGHT LOOK INTO for IEC62056-21 meters this usually works IEC 61107 I dunno, sorry for not having an answer for you, but I think it might worth a try RX/TX you can try swapping, also first thing to try, if you did not tried yet, is to try interface with the mirror or even white piece of paper, if it reads back what it sends. Again, this is not an answer just some suggestions, that will hopefully be helpful as i struggled getting everything working with similar interface and similar meters for the first time. Worst case you can use this https://github.com/jomjol/AI-on-the-edge-device . But if it is in the shaft in the ground it will get foggy and might hard to get proper reading. At leas tmine Reading bit more |
@copystring Regarding the sign on message ... I told you at the beginningnthat the string is wrong ... If you just now changed it then please re-read anything I posted |
Please leave the Signon message alone and simply leave empty ... then it is exactly sent correct because you just need the default, but just once. |
Ok. Same settings as above but with SignOn empty: No or too long answer from Serial Device after last request. |
Please show a debug log. Thank you |
As said: We only send the signon once ... mabe the 30 wakeup chars are then not enough? |
Maybe. Changed the 30 to 500. |
Please post a DEBUG log ... Silly is not helpful in this case. Thank you |
(and increasing 30->500 is most likely also not helpfull .. try 60 or such |
Oh. I thought it's the same but more. |
In fact the extended Log from the library was only acivated by debug log and not sentry .. so check log and you see what is sent out, So signon is as expected ( yes the linebreak is sent too), but the device do not respond. Hhmmm ... when the infos on https://wiki.volkszaehler.org/hardware/channels/meters/warming/kamstrup_multical_401 are correct then this is a mega szrange device ( if the 21 is same as 401 described there, but maybe worth a try). Try setting the serial connection parameter s to 7E1 or 7E2... But even then it is NOT D0 as protocol!! Or it is a different device then documentted there |
Yes line break is sent out correctly. 7E1 and 7E2 made no difference. Check this out sent by powerfox: https://pastebin.com/jq83RDEt |
... and it is not even sending out \r\n ... 0D 0A ?! ... |
YOu could try to contact manufactorr and ask for detailed specs :-) |
Hehe yeah I had that same idea. I guess I might actually do that but it would not surprise me if I'll get no answer. |
Okay. Well I did not get in touch with the manufacturer seeing it's a 5€ fee a year to use their service I doubt they'd help. Anyway. I managed to make the water meter to give a response by sending this: Looks like something to me. Now what do I do with that? 🤷♂️ |
Right. So I went and attached the read write head to the powerfox and waited for it to send Here's the log:
Can we do something with that? |
So this must be the IEC1107 protocol with a baud rate of 1200. You said this'd be better to discuss on the iobroker forum right? Maybe I should take it there. |
If it is a different protocol then ioBroker Forum will not help ;-) I need to look into it when I find time |
hi copystring, ive the same Multical 21 and try to get it read with esphome and homeassistant, I tried the multical401 files that sends "175,163,177" in multical401.h file and "\xAF\xA3\xB1" in the logfile over the optic head. [01:39:36][D][multical:168]: ERR(TIMEOUT): 1.722248 can you post your config where you get the time and date from the meter ? thx |
You can send
|
thank you, if I replace the byte sendmsg1[] = { 175,163,177 }; with byte sendmsg1[] = { 128,63,16 }; which should be hex 80 3F 10 |
What connection settings did you use? I tried with 1200 and 300 7E1 and 8N1. |
As I have read somewhere, the meter uses two different speeds for send/receive. The kamstrup meter might use a reed relay to shutdown their transmitter if there is no magnets detected in the reading eye As an alternative if a modbus is present: talked to a Kamstrup salesman (in Augsburg) yesterday, they are selling Wmodbus receivers, already paired to your device, for around 100€ plus a surcharge for quantities below minimum. You need to tell them the serial of your meter and the designated modbus id. Multical 21 modbus protocol is well documented. It delivers 2 temperatures, some alarms and the counters. My local water supplier offered to order for me with their next bigger order to avoid the extra charge. |
Multical21 uses baudrate 1200. Confirmed with oscilloscope. |
@onkelbeh Hi, I am interested in that solution, because I have modbus working already. Any news about your order by the local water supplier? Do you have a name or order number? |
No, did not continue yet. In fact, they try to make me believe they are stupid (as I asked for the Modbus key), and I dont want to honor that. Heard about other suppliers giving out the Wmodbus key to end users. I got the pins of the power meters from the same company, from an other (very friendly) department. Currently I try to read from the IR interface (https://github.com/onkelbeh/kamstrup/blob/master/Software%20eksempler/kamstrup_multical402/kamstrup_multical402.ino), will cost me a bit of playing to get the code packed into ESPHome. The guy from Kamstrup I talked with was Jeffrey Shirley +49 821 29722710 |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days. Please check if the issue is still relevant in the most current version of the adapter and tell us. Also check that all relevant details, logs and reproduction steps are included and update them if needed. Thank you for your contributions. |
I digged a bit further and found this: |
Sending 803f100100444dc00d can be split like this: on the receiving side: where 0044 stands for the current meter value
can be used to calculate the correct checksum |
Just posted a readout success here. Anybody here in this discussion who has a solution for "stop responding" issue discussed in the above linked thread? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days. Please check if the issue is still relevant in the most current version of the adapter and tell us. Also check that all relevant details, logs and reproduction steps are included and update them if needed. Thank you for your contributions. |
This issue has been automatically closed because of inactivity. Please open a new issue if still relevant and make sure to include all relevant details, logs and reproduction steps. Thank you for your contributions. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days. Please check if the issue is still relevant in the most current version of the adapter and tell us. Also check that all relevant details, logs and reproduction steps are included and update them if needed. Thank you for your contributions. |
Hello everyone,
so a while I try to get my water meter in my smart home. The water meter is placed outside in a metal shaft 2 meters deep. Wifi reception is obviously bad but could be worked around with a long cable for the antenna or similar.
The model is a Kamstrup Multical 21.
There are various ways to get to the data of the water meter. My first choice in via WMBUS however this needs an AES-Key which my provider will not hand out to me for privacy reasons.
So I looked for alternatives.
First I tried the pulse adapter
The way this one works is after pressing the button in the pulse adapter every 10 liters a pulse is send which could be used by for example a esp8266 or so to send it off to mqtt.
Problematic is the fact that sometimes a pulse is missed. Maybe by bad wifi signal or so. This is tedious to correct because I'd have to get the water out of its shaft every time to manually sync the current meter value with my smart home.
After a lot of research I found this device: Poweropti Powerfox PA201901
This can be put on my water meter which communicates via the bidirectional IR-LEDs.
I bought this and tried it out. It can actually read the current meter value with those LEDs. Nice!
Looking at the datasheet I found out Powerfox supports SML-Protokoll and IEC1107. IEC1107 is the same as IEC 61107 right? I believe it go renamed.
There is a similar topic here but I don't know how reliable the information is. Assuming the water meter is in fact using IEC1107/IEC 61107
/?!\r\n
(in HEX2F3F210D0A
) needs to be send. I bought an IR read write head and connected to an FTDI which is used by ioBroker.smartmeter setup like this:Sadly no data is returned.
I also have a oscilloscope (RIGOL DS1054) hooked up to TX and RX of the IR read write head while it was on powerfox to receivce what powerfox is sending. This is also connect to my PC with pulseview but not sure where to go from there.
How do I use that data?
Yeah I could just use powerfox in the end but that's not cool. I want to directly use the IR read write head on the meter. Also it costs a yearly fee after 2-3 years.
Let me know if I'm on the right track with this and if so how we can get this working.
Thank you
Felix
The text was updated successfully, but these errors were encountered: