UtilitechAS / amsreader-firmware

ESP8266 and ESP32 compatible firmware to read, interpret and publish data to MQTT from smart electrical meters, both DLMS and DSMR is supported
Other
381 stars 73 forks source link

Testing v2.1.0 #247

Closed gskjold closed 2 years ago

gskjold commented 2 years ago

Attached is a new major version with changes outlined below. If anyone could test this on their setup, it would be highly appreciated.

!Warning! This is a firmware which is still under development. Testing this firmware is on your own risk. Please only test if you have possibility to flash via TTL or USB if anything goes wrong.

Changes:

Added:

Norway

Denmark

Sweden

esp32.zip esp8266.zip

esp32.zip esp8266.zip

esp32.zip esp8266.zip

esp32.zip esp8266.zip

esp32.zip esp8266.zip

esp32.zip esp8266.zip

esp32.zip esp8266.zip

esp32.zip esp8266.zip esp32s2.zip

Please reply to this post with your configuration (esp8266/esp32/pow-u etc), meter manufacturer, distribution type (IT/TT/TN) and country

Isaksson commented 2 years ago

Phase Current graph works great now when negative values on all three phases. I just installed this version so I have not used it for long but everything seems fine for now.

rugaard commented 2 years ago

@Jelboen Wouldn't you be up for testing the Kamstrup 3p in Denmark? 🤪 Then we could also test to see, if it fixes our issue (#244) as well.

If not, I could probably do it. Only thing is my meter is located outside behind annoying trap doors, so it's a bit complicated if I have to flash it multiple times 😆 But if no one else signs up, I wouldn't mind helping out @gskjold 👍

tronde-ams commented 2 years ago

ESP32: First impression on Aidon 3p IT without export is good. It does update all values in real time, also the total imported kWh.

I can see you push real time daily and hourly values on /data.json now. Have you made any changes for MQTT as well?

kabu-kabu commented 2 years ago

Just testet on ESP8266. Partly working with Kaifa 3p TN:

BKFlister commented 2 years ago

Tested ESP8266 on Pow-U, failed to upload firmware, got http 500 errors. Reset/reboot of the Pow-U, new upload firmware, upload seem OK, reboot by upgrade, the Pow-U is still on 2.0.11.

ArnieO commented 2 years ago

@BKFlister Did you use usb power when you tried to upgrade? It is necessary to use external power when upgrading Pow-U, or else it will go down for lack of energy, the upgrading sequence is power-hungry.

BKFlister commented 2 years ago

@ArnieO Yes, it was on usb power. Tried again, and then the usb power went down on me when flashing :( , and now the Pow-U is "dead" Will get the FTDI-adapter and try to flash it

Thanks

svhaaland commented 2 years ago

Testet on ESP8266 with Aidon 3p IT (Norway)

tronde-ams commented 2 years ago

ESP32 I have tested the config file now. It does save and re-load, but something seems to be wrong with re-creation of the dayplot and monthplot.

I have two ESP32 running c38034c.

One of them is OK, the other went haywire in the plots when I upgraded from 2.0.10. I can load the config from the OK unit, and everything except the plots are transfered OK. The plots does not change to the values in the config file.

I have not tried a factory reset yet, in case there is something I should try first,

gskjold commented 2 years ago

I can see you push real time daily and hourly values on /data.json now. Have you made any changes for MQTT as well?

Raw mode sends '/realtime/import/hour' and '/realtime/import/threshold'. JSON mode has realtime: { h: 0.00, t: 0 } for hourly and threshold.

Have not modified HA or Domoticz.

gskjold commented 2 years ago

Can confirm that config download/upload has a problem. New update in first post.

gskjold commented 2 years ago

@kabu-kabu if you use Google Chrome, tell me if there is any output in the developer console.

First open dev tools: chrome-dev-tools

Then go to the console tab: chrome-dev-tools-console

Reload page

gskjold commented 2 years ago

@BKFlister is it totally dead, or is there LED activity?

If there is LED activity, it should light the green LED for 1s, then flash other colors. During the 1s the green LED is on, press and hold AP button (do not start pressing it before green), it should then change to yellow for 2s and then red. When it turns red, release button. It should then factory reset and should be reachable via AP.

If that doesn't work, you can also try to repeat, but keep holding through the red and flashing led, then release.

kabu-kabu commented 2 years ago

No output in the Chrome dev console.

Import and export graphs are 0 and within the next two boxes I get red message boxes "Data table is not defined." using Firefox on Android.

20220315-amsmqttbridge

gskjold commented 2 years ago

Aha, I see. It must have trouble decoding the full frames. Could you enable the internal debugger in System -> Debugging and set it to verbose. Give me some output from the telnet console.

kabu-kabu commented 2 years ago

Here are some HAN messages.

(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F1 D0 C8  1C 4A E3 F2
(D) 3E 09 3B E9  62 13 67 F2  15 13 E7 0E  D2 4B 84 B2
(D) D2 45 0B DD  92 3D 27 16  D2 28 23 B1  A3 B6 03 CD
(D) 56 4F D3 5D  C4 E3 6D 2A  25 54 7A 60  EE 35 A9 3A
(D) 42 3A FD BE  A1 B1 18 15  7A 18 5B 6D  8D 87 DB 72
(D) 37 6A 19 E4  EE 05 93 5A  35 22 46 EE  14 27 79 4D
(D) 31 E4 50 D1  7A CD A0 E2  33 62 E1 A6  9F 26 74 1B
(D) 30 39 DE F4  AB 2C 9E 47  87 00 84 AE  00 12 FE 9E
(D) F9 94 5D 7B  DA 5E 4D 41  A8 D1 22 B9  BC 5F E4 DF
(D) 69 53 93 4B  58 FB BA E8  86 0D CE 03  69 3F AF E7
(D) 84 1E E3 C7  BF AB 12 58  E1 BE 50 CF  34 9A EB 25
(D) 92 D1 48 DE  D4 D5 61 BA  B2 8A 19 AA  FF 08 B4 7B
(D) 29 25 C3 DC  C2 73 43 DB  45 24 A3 22  60 E3 20 20
(D) 86 D7 10 4C  08 99 1C 3E  31 C6 6E CC  55 6B D7 96
(D) 51 6A 21 CD  0F B0 1C A7  3C E1 E5 8B  0C 57 51 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 C1 F8 CF  A9 1A E3 04
(D) 0A 3B AE 85  60 FB 7B 0C  57 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F1 0F 80  4C 7F B7 0C
(D) 07 E6 03 0F  02 0A 06 28  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 06 28  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 8E  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 12 FF 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 56 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 47  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  56 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 B3 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 A6 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 A6  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 ED 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F1
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F2 60 25  42 F3 1A 74
(D) 10 B9 C6 04  D2 62 D5 EB  48 3F FA 9D  C4 E3 3C 3A
(D) 98 B8 31 0C  42 AE 68 D7  7F 18 A5 64  75 9B CD AF
(D) 20 8A AD BD  22 B2 71 46  69 B1 B7 76  2B 9C 2C 4F
(D) 32 67 2C EE  9B 6B EB 29  45 CC 93 35  D5 72 6B 46
(D) 47 01 38 FE  FB 2F E7 3C  FA C8 E1 AF  AC 62 9F D1
(D) AD CE 71 B4  3D E6 B5 91  14 DE B6 9D  72 D1 55 D7
(D) 53 56 0B E7  CD B5 52 05  79 45 AA A1  77 11 B8 70
(D) DF 06 B2 29  87 A7 6E 7C  94 94 18 2E  31 19 25 20
(D) 1A A6 46 94  40 B1 59 BA  C0 F1 34 68  65 A2 E8 A9
(D) 6D D8 DE C9  2D 44 B0 91  C5 87 62 AC  E8 67 14 B9
(D) AE 4C C0 28  EC A0 11 69  4E 0C 76 E9  51 F5 3C 52
(D) 25 35 BF D3  1F E8 7C 42  F8 2D 19 FA  A0 B6 F0 25
(D) DD 4B B6 62  0F 54 8B D9  48 C8 B7 DC  C3 12 92 EE
(D) A8 5F F4 32  B2 A5 43 9A  00 72 75 6A  41 8F 29 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 98 0A 31  33 7B 7B A0
(D) F7 DD F3 54  E6 DA 70 F1  A3 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F2 0F 80  4C 7F B8 0C
(D) 07 E6 03 0F  02 0A 06 2D  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 06 2D  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 95  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 10 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 56 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 49  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  56 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 B5 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 AA 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 A7  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 11 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F2
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (loop) Used 0 ms to update temperature
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F3 B1 72  D9 68 76 8B
(D) 47 94 DB 13  39 A3 7E BD  F5 B3 81 E7  C3 CB C9 37
(D) C9 A0 DF DC  0C 40 DF F9  D5 13 90 58  FB 5E 3E F4
(D) 23 2D E7 77  1C BA FC 66  75 26 D2 01  16 87 20 DE
(D) B4 CA 2F 3D  71 58 AC 82  47 22 FF BF  A0 DD 5D 14
(D) CA 23 A8 22  AD 8B C9 1A  70 22 16 AD  F1 5C 75 9E
(D) 81 ED C7 15  B8 4B F2 0C  E3 09 52 39  1D FD 34 1E
(D) C4 93 AC 6D  4B 5D FE 1E  CD 12 72 39  7F EC 11 7E
(D) 9C 40 AA 81  97 FA 58 81  96 25 3C F9  92 EE FD A0
(D) C4 46 1D 11  B5 1B F6 9A  68 FF 03 15  D3 49 9D A9
(D) 27 11 24 80  63 13 64 96  B8 9C 1F DD  D2 30 0A 1E
(D) E0 09 7C E4  6F 4B 61 6A  11 50 48 4A  B8 2D EA 1F
(D) 25 95 1B 2A  83 4D BD 55  83 AA 05 76  73 8F 33 4A
(D) 83 99 DE 48  EB 2F 11 BC  70 10 7E 77  91 44 3E 25
(D) D2 0B 1D 71  C2 7C 6A B6  3E 9E AC 06  C0 93 03 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 7F 88 83  94 08 BA 34
(D) CC 65 93 D8  84 D8 E4 8F  4A 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F3 0F 80  4C 7F B9 0C
(D) 07 E6 03 0F  02 0A 06 32  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 06 32  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 9C  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 22 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 56 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 49  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  57 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 B6 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 AE 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 A9  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 92 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F3
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F4 20 F6  9F B6 62 8A
(D) 51 1D 46 72  06 21 9D 40  79 04 70 6D  08 75 55 FE
(D) 6C 82 C7 AE  64 3F 50 CC  24 85 C1 83  65 A2 4C 02
(D) 62 90 3B 42  9E 86 9C F0  46 C1 EA 4F  3C 5A AC E2
(D) 7B E9 92 41  A3 7D 32 E5  D4 FB B9 84  63 6D C7 24
(D) EC 80 D2 C2  1D 04 D9 E9  7B 6E 9A FD  80 48 3C 6C
(D) B6 ED D9 F6  A9 8C 26 A8  75 5E D7 BE  2E 9E 56 8E
(D) 7E 7E 94 BD  10 DF 1D 26  7E 08 F7 9F  05 A9 47 6D
(D) 26 97 0E AA  01 8F C0 C5  10 64 2D CE  C0 7A 87 A7
(D) 4B D0 F7 59  4C D9 21 FF  0C 2A 41 17  91 5D 69 89
(D) 0D D4 F4 C5  27 37 92 16  60 07 6B C1  F2 7C 22 CE
(D) 92 B6 9C B7  D8 B4 1A 59  57 61 90 9B  56 68 33 5C
(D) CE 83 B9 A2  4E 4F 8A 13  3E E5 E7 63  10 DB 7E 9A
(D) EE 3E 2B 9D  09 FC C4 CB  3A 27 82 CF  67 E6 87 9A
(D) 6B 28 73 A3  AB 59 4E 9C  7F 26 7E D7  37 9A 96 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 B6 ED 6B  9B 3C 85 7E
(D) 6D AC 16 5F  E7 F3 46 23  84 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F4 0F 80  4C 7F BA 0C
(D) 07 E6 03 0F  02 0A 06 37  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 06 37  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 A3  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 30 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 54 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 4A  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  58 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 B9 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 AF 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 AB  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 5F 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F4
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F5 53 A3  2D B4 BB BC
(D) F9 98 95 B0  B9 72 B7 28  4C 12 77 D1  AC 63 DE CF
(D) 9A D0 60 6D  20 6F E5 F2  E8 CB 57 58  0B C6 46 9C
(D) F9 23 C8 F8  41 B1 C6 8B  EC EC 32 C9  7E DA 00 75
(D) 14 32 07 5A  49 66 69 73  A5 51 27 F4  F7 D7 D7 23
(D) AC 51 BD 52  B9 3A C2 A0  64 F3 6C D4  C5 AF 8B 66
(D) F2 C3 37 79  97 36 52 12  4F D2 22 F1  A5 FB 15 A0
(D) 66 2C 44 6F  86 53 1D D6  86 E5 2F 1F  07 25 21 37
(D) 79 8C A1 73  4D A3 08 48  D2 1E 42 EB  1B EA 2E 4A
(D) AD 61 4B 93  2F 16 C8 D7  18 2D EC A0  16 88 6C 2C
(D) 7F E2 D6 09  FF 6F B1 76  6A E5 3E C5  B0 6C 4A 1A
(D) 6F 20 B5 5D  40 F0 71 84  A4 57 4E 82  5A A0 E4 95
(D) 50 AF 4F 19  98 24 36 04  43 15 F9 7F  3B D7 9C AD
(D) E4 DD E6 36  5A E0 A6 26  50 DC 85 00  80 1C A3 7C
(D) F0 DD 2D 2B  AF A1 73 E6  5F 89 ED 92  9A 22 4C 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 18 51 66  AB 78 24 E0
(D) C8 8D CF 48  00 82 D5 6A  EE 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F5 0F 80  4C 7F BB 0C
(D) 07 E6 03 0F  02 0A 07 00  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 07 00  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 AA  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 35 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 56 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 4C  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  57 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 B9 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 B0 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 AB  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 7F 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F5
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F6 47 3C  15 0B 11 D2
(D) 15 DD 5C BB  AF 74 0A 4C  AC 24 5D A7  A2 89 2C C9
(D) 5F 9E 81 2E  11 73 27 D7  6B 31 7D AC  47 00 7F D1
(D) BE 4E 7E 50  F5 70 B8 4D  39 A8 BB D2  E9 48 AA CF
(D) A6 D9 84 CE  F9 23 11 CA  64 02 26 68  EA 75 F9 EA
(D) C1 D3 55 1E  5F 55 FB 55  7A 74 F5 5F  8D 87 C8 50
(D) BA 5E BA FC  A8 C5 6A 18  78 CE 1C 84  C7 57 01 A5
(D) 30 FD 6F 14  02 2E 7A DF  E9 0D 10 0D  31 1F BC 46
(D) B1 DE 88 86  51 5F 9E 08  CA C7 33 F9  11 D4 35 A8
(D) BA EE C2 CF  3B 88 6A 20  07 1F 89 52  F7 3C 4C 20
(D) 75 D4 AA 0F  DE E7 40 70  CB 23 EA 92  98 EF 04 85
(D) F1 CA 5D 54  F8 7E 0C 65  0F 78 9F CF  CD 79 C8 75
(D) 46 59 5C E8  0C 48 57 93  35 B0 90 E7  B6 C9 6B B3
(D) 68 18 1C 96  27 23 CF 88  7C A6 64 76  FB FF 0F 70
(D) CE 47 95 B3  9E 67 5B 5E  BC 0B 95 B0  23 9A 32 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 1A AC 47  F7 04 A2 B1
(D) 4B 70 5C 09  F4 AE 66 1B  69 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F6 0F 80  4C 7F BC 0C
(D) 07 E6 03 0F  02 0A 07 05  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 07 05  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 B0  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 56 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 52 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 55  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  57 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 BD 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 B4 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 AF  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 E0 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F6
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (loop) Used 0 ms to update temperature
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F7 65 11  51 A3 3D 08
(D) 64 63 6A 4D  1C D2 E6 91  0A F7 8F 38  18 DD 5D A7
(D) 4D AD EE D6  C3 79 B5 9C  03 E2 5E 74  8F 0C D9 C5
(D) 27 DD 82 2A  AA 97 85 14  3A 47 EB 28  BB 11 F4 9E
(D) 7B 42 35 F0  82 61 8A 6D  68 CD FB 61  15 19 78 2B
(D) 02 BF E1 8A  32 4E 1E 18  F1 50 17 1F  81 3D 10 A1
(D) 61 6C 96 41  1F 70 9C AB  E3 28 A7 00  02 23 52 AC
(D) 39 E5 8E D4  F5 3D 9B 27  F8 1A 8E 7F  29 34 93 A5
(D) 05 FB 2C 2F  66 EC 72 28  1B 42 2A 58  82 FA 0F DD
(D) 4E 5C 1A 7B  60 77 E9 22  D3 7E FB 09  CA 1B 5C 73
(D) DA 06 E5 3E  12 D3 4C BD  FA 89 1E 61  D6 09 B3 F4
(D) 53 39 88 2C  C3 81 24 65  12 6B 8E 2E  75 F2 52 C5
(D) 1D 27 BE 8B  83 6A FD 50  E5 B3 E3 A1  6F A4 AF 18
(D) 18 46 B7 D9  10 B2 E8 67  7D 16 71 2F  8A EB 74 FD
(D) 12 E7 A1 82  B7 05 C7 28  C2 1C E6 E5  57 8D C0 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 08 14 28  D1 D8 91 98
(D) 98 A8 65 B9  24 A3 79 A7  26 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F7 0F 80  4C 7F BD 0C
(D) 07 E6 03 0F  02 0A 07 0A  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 07 0A  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 B7  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 7A 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 52 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 54  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  58 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 C2 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 BA 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 B4  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 2B 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F7
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
(D) (AmsWebServer)Serving /data.json over http...
(I) (readHanPort) Intermediate segment
(D) (readHanPort) Frame dump (256b):
(D) 68 FA FA 68  53 FF 00 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F8 84 04  70 F9 01 5F
(D) 99 87 1C 22  F0 D4 B3 01  23 D6 61 70  D4 BF 9D 1D
(D) 05 98 85 C8  7E BE 57 B0  45 FD 9D DD  BB 15 30 1B
(D) 56 22 3C 48  7F E2 E1 DF  59 BF 80 ED  56 29 93 B4
(D) AD CD 9D 84  58 C7 EA 77  78 51 9E 72  57 B7 07 5A
(D) 0C 88 9B FF  69 C0 05 C4  D2 FC D0 DF  DF 04 42 13
(D) 71 1B 0C 28  16 DD 5C FA  06 B5 DF 2A  F4 50 A8 0D
(D) 5B FA F4 C9  1F 64 88 20  60 80 65 18  0C E0 5D BE
(D) 65 C4 73 F7  0D 8C F1 91  41 42 77 98  C6 22 EA CF
(D) 2C 95 FA D6  49 38 ED 46  A1 03 7B D7  E1 46 E9 D5
(D) BD 84 C2 B6  60 D5 0A 8D  43 88 7B BF  A0 86 EC E3
(D) 5A 1A BB E9  3A AD DA 54  F8 44 C2 D3  EB BE 48 8D
(D) BC AB E0 3C  3A BE C3 C5  D2 7F 90 C0  68 A6 E1 CD
(D) 77 D3 03 1A  27 0B F6 9C  FE EE 93 A8  DF 8E 41 20
(D) 4B AA 40 62  DE C0 15 89  91 F6 68 9A  0E 9F 0A 16
(D)
(I) (readHanPort) Final segment
(D) (readHanPort) Frame dump (26b):
(D) 68 14 14 68  53 FF 11 01  67 EB 59 F6  0D 48 E7 5E
(D) 8C AA BB 6D  33 B5 0F D9  CD 16
(D) (readHanPort) Frame dump (271b):
(D) 68 00 00 68  53 FF 10 01  67 DB 08 4B  46 4D 65 50
(D) 9A 0F 03 81  F8 20 00 06  C9 F8 0F 80  4C 7F BE 0C
(D) 07 E6 03 0F  02 0A 07 0F  00 FF C4 00  02 23 09 0C
(D) 07 E6 03 0F  02 0A 07 0F  00 FF C4 00  09 06 01 00
(D) 01 08 00 FF  06 00 27 86  74 02 02 0F  00 16 1E 09
(D) 06 01 00 02  08 00 FF 06  00 82 48 BE  02 02 0F 00
(D) 16 1E 09 06  01 00 01 07  00 FF 06 00  00 00 00 02
(D) 02 0F 00 16  1B 09 06 01  00 02 07 00  FF 06 00 00
(D) 13 8F 02 02  0F 00 16 1B  09 06 01 00  20 07 00 FF
(D) 12 09 52 02  02 0F FF 16  23 09 06 01  00 34 07 00
(D) FF 12 09 56  02 02 0F FF  16 23 09 06  01 00 48 07
(D) 00 FF 12 09  55 02 02 0F  FF 16 23 09  06 01 00 1F
(D) 07 00 FF 12  02 C5 02 02  0F FE 16 21  09 06 01 00
(D) 33 07 00 FF  12 02 BD 02  02 0F FE 16  21 09 06 01
(D) 00 47 07 00  FF 12 02 B7  02 02 0F FE  16 21 09 06
(D) 01 00 0D 07  00 FF 12 03  E7 02 02 0F  FD 16 FF 09
(D) 0C 31 38 31  32 31 30 30  39 36 33 38  37 1C 16
(D) (readHanPort) System title:
(D) 4B 46 4D 65  50 9A 0F 03
(D) (readHanPort) Initialization vector:
(D) 4B 46 4D 65  50 9A 0F 03  00 06 C9 F8
(D) (readHanPort) Additional authenticated data:
(D) 20 00 00 00  00 00 00 00  00 00 00 00  00 00 00 00
(D) 00
(D) (readHanPort) Authentication tag:
(D) 00 00 00 00  00 00 00 00  00 00 00 00
(D) (readHanPort) Valid data, start at byte 44
(V) (EnergyAccounting)  calculating threshold, currently at 10
(V) (EnergyAccounting)  new threshold 10
gskjold commented 2 years ago

@kabu-kabu Thanks! What country are you in? Have this meter worked with previous versions?

kabu-kabu commented 2 years ago

I live in Austria, my meter is Kaifa MA309.

Jumped into the project by using version 2.0.11 - my meter was recognized as "manufacturer: Sagemcom, model: unknown"; I got plausible data which was pushed via MQTT; only problem was a regular restart while accessing the gui.

With version 2.1.0 my meter is not recognized ("manufacturer: unknown") but I do get plausible data via MQTT. gui is not working.

ArnieO commented 2 years ago

I live in Austria, my meter is Kaifa MA309.

Jumped into the project by using version 2.0.11 - my meter was recognized as "manufacturer: Sagemcom, model: unknown"; I got plausible data which was pushed via MQTT; only problem was a regular restart while accessing the gui.

With version 2.1.0 my meter is not recognized ("manufacturer: unknown") but I do get plausible data via MQTT. gui is not working.

Interesting! What hardware are you using? Regular restart while accessing GUI is probably linked to issues outside of the firmware. I suspect some restart issues are linked to Wifi. What is your RSSI (indicated on GUI)?

gskjold commented 2 years ago

Thanks! I figured it was Austria. The format is same as Sagecom, but I find it strange it was recognized as that as well, because the identifier differs. I will use your data dump as source for debugging locally when I have time.

tronde-ams commented 2 years ago

ESP32 / 42a627e All graphs updated correctly when I reloaded config from the OK module to the one being incorrect, but real time price values for day and month did not change. .

source copy

gskjold commented 2 years ago

Day cost is calculated on the fly based on values from graph, cost for those hours received from entsoe, and entsoe multiplier. Did any of those change?

bjornsivertsen commented 2 years ago

I am using Kamstrup in Denmark, and there appears to be issues. HAN status flashes between yellow and green. image image

If I enable logging like this: image

Where is the output located?

It worked for previous versions.

ArnieO commented 2 years ago

I am using Kamstrup in Denmark, and there appears to be issues. HAN status flashes between yellow and green.

Can you please show "System/GIPO"? You might need to set "HAN" to GPIO12 again.

tronde-ams commented 2 years ago

Day cost is calculated on the fly based on values from graph, cost for those hours received from entsoe, and entsoe multiplier. Did any of those change?

The costs are OK now. Updated when new hour? All graphs on both units was equal when the prices was wrong.

I have also tested the raw MQTT /realtime/import/hour and /realtime/import/threshold to be OK.

As of now, I find no other errors from what I can test. I do only use the GUI and raw MQTT to an android app.

One wish: Is it possible to push /realtime/import/day as MQTT as well?

ArnieO commented 2 years ago

Where is the output located?

@bjornsivertsen You will not be able to use serial debugging from a Pow-K. Use Telnet, then open a command window and type "telnet . You might need to activate Telnet on your PC, it is inactive by default (Google will help!)

tronde-ams commented 2 years ago

source copy

I see one thing I did not notice. The 150 kWh treshold did not change. I had one one hour value of 131 kW in the unit that went haywire, and it seems like it has triggered the 150 kWh that is still there even when the costs have changed back to correct values.

bjornsivertsen commented 2 years ago

I am using Kamstrup in Denmark, and there appears to be issues. HAN status flashes between yellow and green.

Can you please show "System/GIPO"? You might need to set "HAN" to GPIO12 again.

image

Here you go

bjornsivertsen commented 2 years ago

Where is the output located?

@bjornsivertsen You will not be able to use serial debugging from a Pow-K. Use Telnet, then open a command window and type "telnet . You might need to activate Telnet on your PC, it is inactive by default (Google will help!)

Thank you, it looks like this:

(D) (readHanPort) Frame dump (1b): (D) 6F (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D E2 8C (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) 4B 20 2E A4 64 32 F0 C0 31 47 7F C9 (W) (readHanPort) Unknown data format 6F (D) (AmsWebServer)Serving /data.json over http... (D) (loop) Used 0 ms to update temperature (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (loop) Used 0 ms to update temperature (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (320b): (D) 7B 22 69 6D 22 3A 39 32 30 30 2C 22 6F 6D 22 3A (D) 30 2C 22 6D 66 22 3A 34 30 2C 22 69 22 3A 30 2C (D) 22 65 22 3A 30 2C 22 72 69 22 3A 30 2C 22 72 65 (D) 22 3A 30 2C 22 69 63 22 3A 30 2E 30 30 30 2C 22 (D) 65 63 22 3A 30 2E 30 30 30 2C 22 72 69 63 22 3A (D) 30 2E 30 30 30 2C 22 72 65 63 22 3A 30 2E 30 30 (D) 30 2C 22 75 31 22 3A 30 2E 30 30 2C 22 75 32 22 (D) 3A 30 2E 30 30 2C 22 75 33 22 3A 30 2E 30 30 2C (D) 22 69 31 22 3A 30 2E 30 30 2C 22 69 32 22 3A 30 (D) 2E 30 30 2C 22 69 33 22 3A 30 2E 30 30 2C 22 66 (D) 22 3A 30 2E 30 30 2C 22 66 31 22 3A 30 2E 30 30 (D) 2C 22 66 32 22 3A 30 2E 30 30 2C 22 66 33 22 3A (D) 30 2E 30 30 2C 22 76 22 3A 33 2E 34 32 32 2C 22 (D) 72 22 3A 2D 35 36 2C 22 74 22 3A 2D 31 32 37 2E (D) 30 30 2C 22 75 22 3A 35 37 33 36 2C 22 6D 22 3A (D) 31 33 38 30 38 2C 22 65 6D 22 3A 31 2C 22 68 6D (D) 22 3A 33 2C 22 77 6D 22 3A 31 2C 22 6D 6D 22 3A (D) 30 2C 22 6D 65 22 3A 30 2C 22 70 22 3A 6E 75 6C (D) 6C 2C 22 6D 74 22 3A 32 35 35 2C 22 64 73 22 3A (D) 31 2C 22 65 61 22 3A 7B 22 78 22 3A 31 2E 35 C3 (D) (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D E2 8C (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) 4B 20 2E A4 64 32 F0 C0 31 47 7F C9 (W) (readHanPort) Unknown data format 7B (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (loop) Used 0 ms to update temperature (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (491b): (D) 7E A1 E9 41 03 13 C6 37 E6 E7 00 DB 08 4B 41 4D (D) 45 01 C2 37 8C 82 01 D0 30 00 0D E2 96 0F 00 00 (D) 00 00 0C 07 E6 03 0F 02 12 35 0A FF 80 00 00 02 (D) 41 0A 0E 4B 61 6D 73 74 72 75 70 5F 56 30 30 30 (D) 31 09 06 01 01 01 08 00 FF 06 00 0B FB A6 09 06 (D) 01 01 02 08 00 FF 06 00 00 00 00 09 06 01 01 03 (D) 08 00 FF 06 00 00 62 C8 09 06 01 01 04 08 00 FF (D) 06 00 0B DD BC 09 06 01 01 00 00 01 FF 06 01 4C (D) 4F A9 09 06 01 01 01 07 00 FF 06 00 00 00 F4 09 (D) 06 01 01 02 07 00 FF 06 00 00 00 00 09 06 01 01 (D) 03 07 00 FF 06 00 00 00 00 09 06 01 01 04 07 00 (D) FF 06 00 00 01 90 09 06 00 01 01 00 00 FF 09 0C (D) 07 E6 03 0F 02 12 35 0A FF 80 00 00 09 06 01 01 (D) 20 07 00 FF 12 00 E1 09 06 01 01 34 07 00 FF 12 (D) 00 DF 09 06 01 01 48 07 00 FF 12 00 00 09 06 01 (D) 01 1F 07 00 FF 06 00 00 00 B5 09 06 01 01 33 07 (D) 00 FF 06 00 00 00 28 09 06 01 01 47 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 15 07 00 FF 06 00 00 00 (D) BA 09 06 01 01 29 07 00 FF 06 00 00 00 3A 09 06 (D) 01 01 3D 07 00 FF 06 00 00 00 00 09 06 01 01 21 (D) 07 00 FF 12 00 30 09 06 01 01 35 07 00 FF 12 00 (D) 43 09 06 01 01 49 07 00 FF 12 00 64 09 06 01 01 (D) 0D 07 00 FF 12 00 34 09 06 01 01 16 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 2A 07 00 FF 06 00 00 00 (D) 00 09 06 01 01 3E 07 00 FF 06 00 00 00 00 09 06 (D) 01 01 16 08 00 FF 06 00 00 00 00 09 06 01 01 2A (D) 08 00 FF 06 00 00 00 00 09 06 01 01 3E 08 00 FF (D) 06 00 00 00 00 09 06 01 01 15 08 00 FF 06 00 09 (D) BB 85 09 06 01 01 29 08 00 FF 06 00 02 40 20 09 (D) 06 01 01 3D 08 00 FF 06 00 00 00 00 DE 24 12 26 (D) A8 4A C4 C9 4D 4D 16 B2 44 A7 7E (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D E2 96 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) DE 24 12 26 A8 4A C4 C9 4D 4D 16 B2 (D) (readHanPort) Valid data, start at byte 47 (V) (EnergyAccounting) Adding 0.0068 kWh (V) (EnergyAccounting) calculating threshold, currently at 0 (V) (EnergyAccounting) new threshold 0 (D) (AmsDataStorage) Month 1647366793 - 0 > 3600 (D) (readHanPort) Its time to update data storage (D) (readHanPort) using estimated data (D) (AmsDataStorage) Month 1647366793 - 0 > 3600 (V) (AmsDataStorage) Time is: 1647366793 (D) (AmsDataStorage) Last day update: 1647363603 (D) (AmsDataStorage) Last month update: 0 (V) (AmsDataStorage) Clearing day: 1 (V) (AmsDataStorage) Clearing day: 2 (V) (AmsDataStorage) Clearing day: 3 (V) (AmsDataStorage) Clearing day: 4 (V) (AmsDataStorage) Clearing day: 5 (V) (AmsDataStorage) Clearing day: 6 (V) (AmsDataStorage) Clearing day: 7 (V) (AmsDataStorage) Clearing day: 8 (V) (AmsDataStorage) Clearing day: 9 (V) (AmsDataStorage) Clearing day: 10 (V) (AmsDataStorage) Clearing day: 11 (V) (AmsDataStorage) Clearing day: 12 (V) (AmsDataStorage) Clearing day: 13 (V) (AmsDataStorage) Clearing day: 14 (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (328b): (D) 7B 22 69 6D 22 3A 39 32 30 30 2C 22 6F 6D 22 3A (D) 30 2C 22 6D 66 22 3A 34 30 2C 22 69 22 3A 30 2C (D) 22 65 22 3A 30 2C 22 72 69 22 3A 30 2C 22 72 65 (D) 22 3A 30 2C 22 69 63 22 3A 30 2E 30 30 30 2C 22 (D) 65 63 22 3A 30 2E 30 30 30 2C 22 72 69 63 22 3A (D) 30 2E 30 30 30 2C 22 72 65 63 22 3A 30 2E 30 30 (D) 30 2C 22 75 31 22 3A 30 2E 30 30 2C 22 75 32 22 (D) 3A 30 2E 30 30 2C 22 75 33 22 3A 30 2E 30 30 2C (D) 22 69 31 22 3A 30 2E 30 30 2C 22 69 32 22 3A 30 (D) 2E 30 30 2C 22 69 33 22 3A 30 2E 30 30 2C 22 66 (D) 22 3A 30 2E 30 30 2C 22 66 31 22 3A 30 2E 30 30 (D) 2C 22 66 32 22 3A 30 2E 30 30 2C 22 66 33 22 3A (D) 30 2E 30 30 2C 22 76 22 3A 33 2E 34 32 32 2C 22 (D) 72 22 3A 2D 35 39 2C 22 74 22 3A 2D 31 32 37 2E (D) 30 30 2C 22 75 22 3A 35 37 36 36 2C 22 6D 22 3A (D) 31 33 37 36 30 2C 22 65 6D 22 3A 31 2C 22 68 6D (D) 22 3A 31 2C 22 77 6D 22 3A 31 2C 22 6D 6D 22 3A (D) 30 2C 22 6D 65 22 3A 30 2C 22 70 22 3A 6E 75 6C (D) 6C 2C 22 6D 74 22 3A 32 35 35 2C 22 64 73 22 3A (D) 31 2C 22 65 61 22 3A 7B 22 78 22 3A 31 2E 35 2C (D) 22 74 22 3A 35 2C 22 B5 (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D E2 96 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) DE 24 12 26 A8 4A C4 C9 4D 4D 16 B2 (W) (readHanPort) Unknown data format 7B (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (491b): (D) 7E A1 E9 41 03 13 C6 37 E6 E7 00 DB 08 4B 41 4D (D) 45 01 C2 37 8C 82 01 D0 30 00 0D E2 99 0F 00 00 (D) 00 00 0C 07 E6 03 0F 02 12 35 28 FF 80 00 00 02 (D) 41 0A 0E 4B 61 6D 73 74 72 75 70 5F 56 30 30 30 (D) 31 09 06 01 01 01 08 00 FF 06 00 0B FB A6 09 06 (D) 01 01 02 08 00 FF 06 00 00 00 00 09 06 01 01 03 (D) 08 00 FF 06 00 00 62 C8 09 06 01 01 04 08 00 FF (D) 06 00 0B DD BC 09 06 01 01 00 00 01 FF 06 01 4C (D) 4F A9 09 06 01 01 01 07 00 FF 06 00 00 01 30 09 (D) 06 01 01 02 07 00 FF 06 00 00 00 00 09 06 01 01 (D) 03 07 00 FF 06 00 00 00 00 09 06 01 01 04 07 00 (D) FF 06 00 00 01 94 09 06 00 01 01 00 00 FF 09 0C (D) 07 E6 03 0F 02 12 35 28 FF 80 00 00 09 06 01 01 (D) 20 07 00 FF 12 00 E2 09 06 01 01 34 07 00 FF 12 (D) 00 DF 09 06 01 01 48 07 00 FF 12 00 00 09 06 01 (D) 01 1F 07 00 FF 06 00 00 00 C5 09 06 01 01 33 07 (D) 00 FF 06 00 00 00 28 09 06 01 01 47 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 15 07 00 FF 06 00 00 00 (D) F6 09 06 01 01 29 07 00 FF 06 00 00 00 3A 09 06 (D) 01 01 3D 07 00 FF 06 00 00 00 00 09 06 01 01 21 (D) 07 00 FF 12 00 3A 09 06 01 01 35 07 00 FF 12 00 (D) 43 09 06 01 01 49 07 00 FF 12 00 64 09 06 01 01 (D) 0D 07 00 FF 12 00 3C 09 06 01 01 16 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 2A 07 00 FF 06 00 00 00 (D) 00 09 06 01 01 3E 07 00 FF 06 00 00 00 00 09 06 (D) 01 01 16 08 00 FF 06 00 00 00 00 09 06 01 01 2A (D) 08 00 FF 06 00 00 00 00 09 06 01 01 3E 08 00 FF (D) 06 00 00 00 00 09 06 01 01 15 08 00 FF 06 00 09 (D) BB 86 09 06 01 01 29 08 00 FF 06 00 02 40 20 09 (D) 06 01 01 3D 08 00 FF 06 00 00 00 00 A0 9D C8 34 (D) 69 83 66 BD 31 30 43 96 EA 18 7E (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D E2 99 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) A0 9D C8 34 69 83 66 BD 31 30 43 96 (D) (readHanPort) Valid data, start at byte 47 (V) (EnergyAccounting) Adding 0.0025 kWh (V) (EnergyAccounting) calculating threshold, currently at 0 (V) (EnergyAccounting) new threshold 0 (D) (AmsDataStorage) Month 1647366823 - 0 > 3600 (D) (readHanPort) Its time to update data storage (D) (readHanPort) using estimated data (D) (AmsDataStorage) Month 1647366823 - 0 > 3600 (V) (AmsDataStorage) Time is: 1647366823 (D) (AmsDataStorage) Last day update: 1647363603 (D) (AmsDataStorage) Last month update: 0 (V) (AmsDataStorage) Clearing day: 1 (V) (AmsDataStorage) Clearing day: 2 (V) (AmsDataStorage) Clearing day: 3 (V) (AmsDataStorage) Clearing day: 4 (V) (AmsDataStorage) Clearing day: 5 (V) (AmsDataStorage) Clearing day: 6 (V) (AmsDataStorage) Clearing day: 7 (V) (AmsDataStorage) Clearing day: 8 (V) (AmsDataStorage) Clearing day: 9 (V) (AmsDataStorage) Clearing day: 10 (V) (AmsDataStorage) Clearing day: 11 (V) (AmsDataStorage) Clearing day: 12 (V) (AmsDataStorage) Clearing day: 13 (V) (AmsDataStorage) Clearing day: 14 (D) (loop) Used 1 ms to update temperature

dioden55 commented 2 years ago

hi Tested pow-u and Aidon meter. it works as earlier, how to test changing wfi power, what are the power span to test ?

BKFlister commented 2 years ago

@gskjold Thanks. There was LED activity, but the factory reset did not work. USB Power was plugged in a power bank, but it seems that the power bank "turned off" during the upgrade and the upgrade failed. Earlier I had the HAN cable plugged in, that probably saved me on previous upgrades.

I got hold of a FTDI-adapter and have managed to flash it with the latest 2.1.0 It is now up and running again.

Now I will try to get data in using "Home Assistant" as Payload.

tronde-ams commented 2 years ago

ESP32 / 42a627e

Real time calculation for hour did not reset when new hour. Same on both units and MQTT

I used 2 kWh between 20:00 and 21:00. Same consumption on all three units (one is 220124.2) I have running at the moment. It did reset at 20:00.

feil 2022-03-15_211105

tronde-ams commented 2 years ago

The calculation did reset correctly on both units at 22:00. Bar graphs also OK.

What vent wrong at 21?

kabu-kabu commented 2 years ago

@ArnieO I'm using a Joy-It Node MCU 8266 and a MIKROE-4137 connected to GPIO04. RSSI is on my screenshot: -41 and better; I even turned down TX power. AP is pretty close and wireless is not busy - I do like wired connections.

Restarts are gone with 2.1.0 and I do get plausible data via MQTT. In my situation it's just GUI which is not working as expected.

ArnieO commented 2 years ago

@ArnieO I'm using a Joy-It Node MCU 8266 and a MIKROE-4137 connected to GPIO04. RSSI is on my screenshot: -41 and better; I even turned down TX power. AP is pretty close and wireless is not busy - I do like wired connections.

Restarts are gone with 2.1.0 and I do get plausible data via MQTT. In my situation it's just GUI which is not working as expected.

OK, so RSSI is good, your Wifi not busy... sounds good. This is an unusual problem that I don't believe we've seen before. I'll let @gskjold have some time to think about it. In the mean time: Did you try to completely erase flash memory before reflashing? In some cases that has resolved strange issues so might be worth a try.

ArnieO commented 2 years ago

Thank you, it looks like this:

@bjornsivertsen Thank you! So the firmware often reads payloads as invalid. Valid payloads start with "7E".

@gskjold Maybe you could add to the first post a request to inform whether hardware is based on ESP8266 or ESP32? Would help tracking down if particular issues could be related to ESP8266 (did we reach the end of its capability somewhere?). Any idea what could be causing what @bjornsivertsen is experiencing?

I have for the last days tested an ESP32-based Pow-K board in my Kamstrup. I'll revert to an ESP8266 board with v2.1.0 now firmware and see what happens.

ArnieO commented 2 years ago

So...

From time to time I see these short payloads that are unreadable. It is not the first time I see it, and suspect this is actually something the meter sends from time to time: image

@gskjold Maybe a far fetched theory but... could there be an issue with hardware serial vs software serial when it comes to capturing data?

I will power up a board that is identical to the one @bjornsivertsen runs (HAN to GPIO12, so software serial) - and see what that gives.

ArnieO commented 2 years ago

So... I changed boards:

I'm basically seeing the same as from the board with HAN to UART0. So I think the hypothesis on SW vs HW serial can be buried.

It looks stable (short test only), including those occasional short payloads starting with 7B 22: image

gskjold commented 2 years ago

What vent wrong at 21?

I will check the logic here, it probably missed the hourly data.

gskjold commented 2 years ago

how to test changing wfi power, what are the power span to test ?

Not sure it is an easy thing to test, but the range is 0-19.5 for esp32 and 0-20.5 for esp8266

gskjold commented 2 years ago

This is an unusual problem that I don't believe we've seen before. I'll let @gskjold have some time to think about it.

Unusual problem indeed, I need some time to think about this.

Maybe you could add to the first post a request to inform whether hardware is based on ESP8266 or ESP32?

Done

Any idea what could be causing what @bjornsivertsen is experiencing?

Nothing comes to mind.. But it could be either a buffer issue or some sort of timing issue

bjornsivertsen commented 2 years ago

Is there anything more I can do to collect data or troubleshoot?

gskjold commented 2 years ago

Is there anything more I can do to collect data or troubleshoot?

Could you try to open /data.json from your browser and post the content?

bjornsivertsen commented 2 years ago

Is there anything more I can do to collect data or troubleshoot?

Could you try to open /data.json from your browser and post the content?

{"im":9200,"om":0,"mf":40,"i":0,"e":0,"ri":0,"re":0,"ic":0.000,"ec":0.000,"ric":0.000,"rec":0.000,"u1":0.00,"u2":0.00,"u3":0.00,"i1":0.00,"i2":0.00,"i3":0.00,"f":0.00,"f1":0.00,"f2":0.00,"f3":0.00,"v":3.423,"r":-53,"t":-127.00,"u":63803,"m":16080,"em":1,"hm":1,"wm":1,"mm":0,"me":0,"p":null,"mt":255,"ds":1,"ea":{"x":1.5,"t":5,"h":{"u":0.23,"c":0.00},"d":{"u":4.67,"c":0.00},"m":{"u":4.67,"c":0.00}},"c":1647430665}

gskjold commented 2 years ago

I think I got it now, try this: esp32.zip esp8266.zip

bjornsivertsen commented 2 years ago

I think I got it now, try this: esp32.zip esp8266.zip

You definitely did something right, as all visualisations are showing up now.

image

HAN status is green perhaps 90% of the time, when it briefly goes to red and yellow. Here are the HAN logs through Telnet

(D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (2b): (D) 7B 7E (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D FC 31 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) F9 D0 D0 A3 F6 04 4C A2 0F 66 67 A2 (W) (readHanPort) Unknown data format 7B (D) (loop) Used 0 ms to update temperature (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (loop) Used 0 ms to update temperature (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (491b): (D) 7E A1 E9 41 03 13 C6 37 E6 E7 00 DB 08 4B 41 4D (D) 45 01 C2 37 8C 82 01 D0 30 00 0D FC 36 0F 00 00 (D) 00 00 0C 07 E6 03 10 03 0D 06 1E FF 80 00 00 02 (D) 41 0A 0E 4B 61 6D 73 74 72 75 70 5F 56 30 30 30 (D) 31 09 06 01 01 01 08 00 FF 06 00 0B FE 43 09 06 (D) 01 01 02 08 00 FF 06 00 00 00 00 09 06 01 01 03 (D) 08 00 FF 06 00 00 62 F0 09 06 01 01 04 08 00 FF (D) 06 00 0B E0 1C 09 06 01 01 00 00 01 FF 06 01 4C (D) 4F A9 09 06 01 01 01 07 00 FF 06 00 00 01 F8 09 (D) 06 01 01 02 07 00 FF 06 00 00 00 00 09 06 01 01 (D) 03 07 00 FF 06 00 00 00 00 09 06 01 01 04 07 00 (D) FF 06 00 00 01 90 09 06 00 01 01 00 00 FF 09 0C (D) 07 E6 03 10 03 0D 06 1E FF 80 00 00 09 06 01 01 (D) 20 07 00 FF 12 00 E4 09 06 01 01 34 07 00 FF 12 (D) 00 E3 09 06 01 01 48 07 00 FF 12 00 00 09 06 01 (D) 01 1F 07 00 FF 06 00 00 00 E3 09 06 01 01 33 07 (D) 00 FF 06 00 00 00 5A 09 06 01 01 47 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 15 07 00 FF 06 00 00 01 (D) 79 09 06 01 01 29 07 00 FF 06 00 00 00 7F 09 06 (D) 01 01 3D 07 00 FF 06 00 00 00 00 09 06 01 01 21 (D) 07 00 FF 12 00 4C 09 06 01 01 35 07 00 FF 12 00 (D) 52 09 06 01 01 49 07 00 FF 12 00 64 09 06 01 01 (D) 0D 07 00 FF 12 00 4E 09 06 01 01 16 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 2A 07 00 FF 06 00 00 00 (D) 00 09 06 01 01 3E 07 00 FF 06 00 00 00 00 09 06 (D) 01 01 16 08 00 FF 06 00 00 00 00 09 06 01 01 2A (D) 08 00 FF 06 00 00 00 00 09 06 01 01 3E 08 00 FF (D) 06 00 00 00 00 09 06 01 01 15 08 00 FF 06 00 09 (D) BD 65 09 06 01 01 29 08 00 FF 06 00 02 40 DD 09 (D) 06 01 01 3D 08 00 FF 06 00 00 00 00 D2 D9 F5 78 (D) BC 56 81 1C AA A5 3F 53 30 96 7E (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D FC 36 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) D2 D9 F5 78 BC 56 81 1C AA A5 3F 53 (D) (readHanPort) Valid data, start at byte 47 (V) (EnergyAccounting) Adding 0.0070 kWh (V) (EnergyAccounting) calculating threshold, currently at 0 (V) (EnergyAccounting) new threshold 0 (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (198b): (D) 7B 22 69 6D 22 3A 39 32 30 30 2C 22 6F 6D 22 3A (D) 30 2C 22 6D 66 22 3A 34 30 2C 22 69 22 3A 35 30 (D) 34 2C 22 65 22 3A 30 2C 22 72 69 22 3A 30 2C 22 (D) 72 65 22 3A 34 30 30 2C 22 69 63 22 3A 37 38 35 (D) 39 2E 38 37 30 2C 22 65 63 22 3A 30 2E 30 30 30 (D) 2C 22 72 69 63 22 3A 32 35 33 2E 32 38 30 2C 22 (D) 72 65 63 22 3A 37 37 38 32 2E 36 38 30 2C 22 75 (D) 31 22 3A 32 32 38 2E 30 30 2C 22 75 32 22 3A 32 (D) 32 37 2E 30 30 2C 22 75 33 22 3A 30 2E 30 30 2C (D) 22 69 31 22 3A 32 2E 32 37 2C 22 69 32 22 3A 30 (D) 2E 39 30 2C 22 69 33 22 3A 30 2E 30 30 2C 22 66 (D) 22 3A 30 2E 37 38 2C 22 66 31 22 3A 30 2E 37 36 (D) 2C 22 66 32 22 3A (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D FC 36 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) D2 D9 F5 78 BC 56 81 1C AA A5 3F 53 (W) (readHanPort) Unknown data format 7B (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (491b): (D) 7E A1 E9 41 03 13 C6 37 E6 E7 00 DB 08 4B 41 4D (D) 45 01 C2 37 8C 82 01 D0 30 00 0D FC 39 0F 00 00 (D) 00 00 0C 07 E6 03 10 03 0D 07 00 FF 80 00 00 02 (D) 41 0A 0E 4B 61 6D 73 74 72 75 70 5F 56 30 30 30 (D) 31 09 06 01 01 01 08 00 FF 06 00 0B FE 43 09 06 (D) 01 01 02 08 00 FF 06 00 00 00 00 09 06 01 01 03 (D) 08 00 FF 06 00 00 62 F0 09 06 01 01 04 08 00 FF (D) 06 00 0B E0 1C 09 06 01 01 00 00 01 FF 06 01 4C (D) 4F A9 09 06 01 01 01 07 00 FF 06 00 00 02 03 09 (D) 06 01 01 02 07 00 FF 06 00 00 00 00 09 06 01 01 (D) 03 07 00 FF 06 00 00 00 00 09 06 01 01 04 07 00 (D) FF 06 00 00 01 91 09 06 00 01 01 00 00 FF 09 0C (D) 07 E6 03 10 03 0D 07 00 FF 80 00 00 09 06 01 01 (D) 20 07 00 FF 12 00 E4 09 06 01 01 34 07 00 FF 12 (D) 00 E2 09 06 01 01 48 07 00 FF 12 00 00 09 06 01 (D) 01 1F 07 00 FF 06 00 00 00 E8 09 06 01 01 33 07 (D) 00 FF 06 00 00 00 5B 09 06 01 01 47 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 15 07 00 FF 06 00 00 01 (D) 84 09 06 01 01 29 07 00 FF 06 00 00 00 7F 09 06 (D) 01 01 3D 07 00 FF 06 00 00 00 00 09 06 01 01 21 (D) 07 00 FF 12 00 4D 09 06 01 01 35 07 00 FF 12 00 (D) 52 09 06 01 01 49 07 00 FF 12 00 64 09 06 01 01 (D) 0D 07 00 FF 12 00 4E 09 06 01 01 16 07 00 FF 06 (D) 00 00 00 00 09 06 01 01 2A 07 00 FF 06 00 00 00 (D) 00 09 06 01 01 3E 07 00 FF 06 00 00 00 00 09 06 (D) 01 01 16 08 00 FF 06 00 00 00 00 09 06 01 01 2A (D) 08 00 FF 06 00 00 00 00 09 06 01 01 3E 08 00 FF (D) 06 00 00 00 00 09 06 01 01 15 08 00 FF 06 00 09 (D) BD 66 09 06 01 01 29 08 00 FF 06 00 02 40 DD 09 (D) 06 01 01 3D 08 00 FF 06 00 00 00 00 3F 71 04 10 (D) 5B 71 DC E8 25 4B 9C C6 00 66 7E (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D FC 39 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) 3F 71 04 10 5B 71 DC E8 25 4B 9C C6 (D) (readHanPort) Valid data, start at byte 47 (V) (EnergyAccounting) Adding 0.0043 kWh (V) (EnergyAccounting) calculating threshold, currently at 0 (V) (EnergyAccounting) new threshold 0 (D) (loop) Used 0 ms to update temperature (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (AmsWebServer)Serving /data.json over http... (D) (readHanPort) Frame dump (274b): (D) 7B 22 69 6D 22 3A 39 32 30 30 2C 22 6F 6D 22 3A (D) 30 2C 22 6D 66 22 3A 34 30 2C 22 69 22 3A 35 31 (D) 35 2C 22 65 22 3A 30 2C 22 72 69 22 3A 30 2C 22 (D) 72 65 22 3A 34 30 31 2C 22 69 63 22 3A 37 38 35 (D) 39 2E 38 37 30 2C 22 65 63 22 3A 30 2E 30 30 30 (D) 2C 22 72 69 63 22 3A 32 35 33 2E 32 38 30 2C 22 (D) 72 65 63 22 3A 37 37 38 32 2E 36 38 30 2C 22 75 (D) 31 22 3A 32 32 38 2E 30 30 2C 22 75 32 22 3A 32 (D) 32 36 2E 30 30 2C 22 75 33 22 3A 30 2E 30 30 2C (D) 22 69 31 22 3A 32 2E 33 32 2C 22 69 32 22 3A 30 (D) 2E 39 31 2C 22 69 33 22 3A 30 2E 30 30 2C 22 66 (D) 22 3A 30 2E 37 38 2C 22 66 31 22 3A 30 2E 37 37 (D) 2C 22 66 32 22 3A 30 2E 38 32 2C 22 66 33 22 3A (D) 31 2E 30 30 2C 22 76 22 3A 33 2E 34 32 34 2C 22 (D) 72 22 3A 2D 35 34 2C 22 74 22 3A 2D 31 32 37 2E (D) 30 30 2C 22 75 22 3A 39 32 34 2C 22 6D 22 3A 31 (D) 33 33 39 32 2C 22 65 6D 22 3A 31 2C 22 68 6D 22 (D) 3A 47 (D) (readHanPort) System title: (D) 4B 41 4D 45 01 C2 37 8C (D) (readHanPort) Initialization vector: (D) 4B 41 4D 45 01 C2 37 8C 00 0D FC 39 (D) (readHanPort) Additional authenticated data: (D) 30 09 DF 55 4F A7 4E C8 92 27 B3 7D 32 11 77 1B (D) 97 (D) (readHanPort) Authentication tag: (D) 3F 71 04 10 5B 71 DC E8 25 4B 9C C6 (W) (readHanPort) Unknown data format 7B

ArnieO commented 2 years ago

Last version working. I still get relatively frequent (invalid) payloads of varying length starting with "7B 22" ("Unknown data format 7B"). Always the same start bytes.

And I see the same in @bjornsivertsen log above: Payloads starting with "7B 22 69 6D" ("Unknown data format 7B").

Interesting indeed...

gskjold commented 2 years ago

Are we sure this isnt a serial parity problem? 8N1 vs 8E1 ?

ArnieO commented 2 years ago

Are we sure this isnt a serial parity problem? 8N1 vs 8E1 ?

With 90% of payloads ok? If so it is in the code, not in the config setting.

gskjold commented 2 years ago

Alright, I can't remember how parity affects the data, but I remember that one works for the other in one of the cases.