[SOLVED] AVM Fritz! Binding - Chart problem after updating to openhab 2.3

I updated openhab from 2.2 to 2.3 yesterday. The upgrade itself went without any trouble, but I have a chart for energy monitoring a Fritz! DECT 210 device via the AVM FRITZ! Binding.

Before the numeric value was around 700 kWh after the upgrade it changed to 700.000 kWh, see screenshot below:

I went into the settings for the Fritz! DECT device and changed the value to “Energy” and changed the global numeric system to “metric”, this did not change anything.

How can I fix this, and is there a way to get the scale back to normal without the jump after it is fixed?

I dont think, it’s a chart problem, but a problem of the item-value. What does the item show?
What persistence-service do you use?

Hi Harry,
thanks for your reply.

You are correct, the item itself is having the problem. I guess it is a problem in the binding itself?
Here is a screenshot of the item in the “Control”-Section:
steckdose

The “Verbrauch Total”-value is incorrect (should be 714,72 kWh), the “Verbrauch Momentan”-value is correct.

I use MariaDB/mysql on the local system as persistence.

Cheers!

Because the temperature is 21°, you use decimalpoint. So it is 714 kWh.

Thanks for your reply.

As you can see in the chart in the first post, it is not just a decimal point, otherwise the chart would not have skyrocketed.

I haven’t changed anything besides upgrading openhab. Maybe something changed between the 2.2 and 2.3 version of the binding? Maybe @cweitkamp has an idea? :slight_smile:

First I would change the system locale to de, to get the decimal komma in the output. If you use openHABian you can do that

1 Like

@northy Yes, I have. I have change the source unit of the energy channel to Wh instead of kWh (see https://github.com/openhab/openhab2-addons/pull/3477#issuecomment-381558983 for more info).

@cweitkamp Than the documentation has to be changed
Number:Energy Energy1 "Accumulated energy consumption [%.3f kWh]" { channel="avmfritz:FRITZ_DECT_200:1:xxxxxxxxxxxx:energy" }

No, from a user perspective kWh is more commonly used than Wh, so the resulting output should be in kWh. The framework handles the conversation on its own.

Do I undersand it right, if I define [… kWh] the item value is in kWh and if I define [… Wh] in Wh ???

Yes, absolutely. That is the big advantage. Have a look at this example using different temperatures. It can be applied for all items linked to a channel which supports an UoM QuantityType.

@northy Let my explain the issue we are facing a little bit more in detail. I have observed it in my environment for a different item too.

Lets assume we have a Number:Speed item which we want to display in the default speed unit (m/s) and in a different unit (km/h). For both units we want to have a chart in our sitemap. Which currently seems not to be possible.

Number:Speed testNumberSpeed
sitemap demo label="My home automation" {
    Frame label="Speed" {
        Text item=testNumberSpeed label="Windgeschwindigkeit [%.1f %unit%]" icon="wind"
        Text item=testNumberSpeed label="Windgeschwindigkeit [%.1f km/h]" icon="wind"
        Chart item=testNumberSpeed label="Windgeschwindigkeit [%.1f %unit%]" period=h legend=true
        Chart item=testNumberSpeed label="Windgeschwindigkeit [%.1f km/h]" period=h legend=true
    }
}

@cweitkamp: Yes, thanks for the information. Originally I added the DECT Switch via Paper UI only and there is no option to select what unit should be used, so I created the item manually:

Number:Energy Steckdose_Total "Verbrauch total [%.2f kWh]" { channel="avmfritz:FRITZ_DECT_200:192_168_100_1:xxxxxxx:energy" }

and after deleting the incorrect values from mysql and influxdb (I use grafana as well), the graphs now show the correct values:

Thanks again for your help :slight_smile: