Fixed kamstrup list version

This commit is contained in:
Gunnar Skjold
2021-11-17 21:47:00 +01:00
parent 9831d4aa78
commit 580085f717
2 changed files with 27 additions and 0 deletions

View File

@@ -144,8 +144,17 @@ IEC6205675::IEC6205675(const char* d, uint8_t useMeterType) {
} else if(memcmp(version->str.data, "Kamstrup", 8) == 0) {
meterType = AmsTypeKamstrup;
}
} else {
version = getCosemDataAt(1, ((char *) (d)));
if(version->base.type == CosemTypeString) {
if(memcmp(version->str.data, "Kamstrup", 8) == 0) {
meterType = AmsTypeKamstrup;
}
}
}
u32 = getString(AMS_OBIS_VERSION, sizeof(AMS_OBIS_VERSION), ((char *) (d)), str);
if(u32 > 0) {
listId = String(str);