Apollon77 / ioBroker.mbus

Communicate with mbus devices
MIT License
10 stars 8 forks source link

Datum wird manchmal nicht angezeigt #330

Closed Klaus-Lucas closed 10 months ago

Klaus-Lucas commented 1 year ago

Bei meinen Kaltwasserzähler wird in der Objektübersicht bei den Datumsfeldern manchmal "invalid date" angezeigt. Siehe: 2-1, 26-12, 28-13

klu_008

grafik

grafik

grafik

Versions:

Debug Ausgabe: "SlaveInformation": { "Id": 28125937, "Manufacturer": "WZG", "Version": 3, "ProductName": "Modularis ETW-EAX", "Medium": "Cold water", "AccessNumber": 147, "Status": 0, "Signature": 0 }, "DataRecord": [ { "id": 0, "Function": "Instantaneous value", "StorageNumber": 0, "Unit": "Volume (m m^3)", "Value": 18849, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 1, "Function": "Instantaneous value", "StorageNumber": 0, "Unit": "Time Point (time & date)", "Value": "2023-09-10T16:11:00", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 2, "Function": "Instantaneous value", "StorageNumber": 1, "Unit": "Time Point (date)", "Value": "2000-00-00", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 3, "Function": "Instantaneous value", "StorageNumber": 1, "Unit": "Volume (m m^3)", "Value": 0, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 4, "Function": "Instantaneous value", "StorageNumber": 1, "Unit": "Time Point (date)", "Value": "2023-12-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 5, "Function": "Instantaneous value", "StorageNumber": 0, "Unit": "Fabrication number", "Value": 364481, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 6, "Function": "Instantaneous value", "StorageNumber": 2, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2022-11-30", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 7, "Function": "Instantaneous value", "StorageNumber": 2, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 0, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 8, "Function": "Instantaneous value", "StorageNumber": 3, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2022-12-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 9, "Function": "Instantaneous value", "StorageNumber": 3, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 0, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 10, "Function": "Instantaneous value", "StorageNumber": 4, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-01-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 11, "Function": "Instantaneous value", "StorageNumber": 4, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 48, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 12, "Function": "Instantaneous value", "StorageNumber": 5, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-02-28", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 13, "Function": "Instantaneous value", "StorageNumber": 5, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 48, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 14, "Function": "Instantaneous value", "StorageNumber": 6, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-03-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 15, "Function": "Instantaneous value", "StorageNumber": 6, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 48, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 16, "Function": "Instantaneous value", "StorageNumber": 7, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-04-30", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 17, "Function": "Instantaneous value", "StorageNumber": 7, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 197, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 18, "Function": "Instantaneous value", "StorageNumber": 8, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-05-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 19, "Function": "Instantaneous value", "StorageNumber": 8, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 4090, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 20, "Function": "Instantaneous value", "StorageNumber": 9, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-06-30", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 21, "Function": "Instantaneous value", "StorageNumber": 9, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 8745, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 22, "Function": "Instantaneous value", "StorageNumber": 10, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-07-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 23, "Function": "Instantaneous value", "StorageNumber": 10, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 13308, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 24, "Function": "Instantaneous value", "StorageNumber": 11, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2023-08-31", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 25, "Function": "Instantaneous value", "StorageNumber": 11, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 17524, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 26, "Function": "Instantaneous value", "StorageNumber": 12, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2000-00-00", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 27, "Function": "Instantaneous value", "StorageNumber": 12, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 0, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 28, "Function": "Instantaneous value", "StorageNumber": 13, "Tariff": 0, "Device": 0, "Unit": "Time Point (date)", "Value": "2000-00-00", "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 29, "Function": "Instantaneous value", "StorageNumber": 13, "Tariff": 0, "Device": 0, "Unit": "Volume (m m^3)", "Value": 0, "Timestamp": "2023-09-10T15:08:51Z" }, { "id": 30, "Function": "Manufacturer specific", "Value": "01 00 00", "Timestamp": "2023-09-10T15:08:51Z" } ] }

Apollon77 commented 1 year ago

Bitte Admin Issue anlegen bzw an das existierende dranhängen. Auch: @foxriver76

foxriver76 commented 1 year ago

bereits gefixt

foxriver76 commented 1 year ago

bzw ja grundsätzlich bitte valide TS strings nutzen mit dieser Rolle, ansonsten zeigt Admin aber bei Invalid Date in Zukufnt als Fallback den tatsächlichen Wert an, ist aber trotzdem unschön

Apollon77 commented 1 year ago

Was wäre denn hier invalide?

foxriver76 commented 1 year ago

alles was parsebar bei new Date(var) ist und nicht in invalid Date durch ein parsen endet. Die Timestamps aus den gelieferten Examples sollten passen, ansonsten mal den Wert anklicken und schauen was wirklich hinter dem Invalid Date steckt.

Klaus-Lucas commented 1 year ago

Datumswerte stimmen jetzt

grafik

grafik

grafik

foxriver76 commented 1 year ago

Vermutlich mit Admin 6.10.1?

Ist der Fallback, da

const x = new Date('2000-00-00')
console.log(x) // -> Invalid Date
Klaus-Lucas commented 1 year ago

@foxriver76 genau