Closed zibous closed 1 year ago
3. Identification ISk5MT174-0001 not found !
Solved, tricky regex:
# ----------------------------------------------------
# obis_code: id returns the manufacturer
# at identification the beginning of an OBIS telegram
# ISk5MT174-0001
# ----------------------------------------------------
- platform: obis_d0
name: "Smartmeter ID"
obis_d0_id: my_gridmeter
obis_code: "id"
entity_category: diagnostic
value_regex: "\\w{3}\\d\\w{2}\\d{3}\\-\\d{4}"
on_value:
then:
- logger.log:
level: WARN
tag: "obis_d0"
format: "Smartmeter ID: %s"
args: ["x.c_str()"]
\x020.9.1(150802) <---- STL+CODE+VALUE
Can't find how to fix it, only workaround with regex ?
According to the documentation on volkszaehler.org, the MT174 sends a STX and an ETX character. They are responsible for the issue with the Current Time
(because it is the first OBIS ID right after the STX) and probably also for the OBIS value end missing
message. I have to think about how to get rid of them (because we don't need them).
Regarding the regex for identification: The identification is not a critical value, e.g. it doesn't show up in Home Assistant statistics. Therefore I would simply omit the regex.
Hi, I created a fix in branch remove_stx_etx. Could you please try this out?
You just have to add the branch name to the external component repo (in case you are using this variant to include an external component):
external_components:
- source: github://mampfes/esphome_obis_d0@remove_stx_etx
Hi, I created a fix in branch remove_stx_etx. Could you please try this out?
Hi Steffen,
Thanks is working now. 💯
Hi
I get two errors evaluating the telegram (not critical) but I would like to know why:
Device Name /ISk5MT174-0001 --> obis_d0 [W][obis_d0:133]: OBIS value end missing
Current time #0020.9.1(135004)#015 After the meter name, the time is sent with STL. I have to enter the STL code (\x02) in the RegEx, otherwise the time will not be recognized.
Identification ISk5MT174-0001 not found ! Dashes are not supported in IDs, please use underscores instead. obis_d0_id: ISk5MT174-0001
see: https://wiki.volkszaehler.org/hardware/channels/meters/power/edl-ehz/iskraemeco_mt174
Telegram & Log:
Configuration: