update changed behaviour of P1 dial

Dashticz, alternative dashboard based on HTML, CSS, jQuery

Moderators: leecollings, htilburgs, robgeerts

Post Reply
willemd
Posts: 736
Joined: Saturday 21 September 2019 17:55
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.1
Location: The Netherlands
Contact:

update changed behaviour of P1 dial

Post by willemd »

I updated to latest Dashticz version today and as result my P1 dial that showed daily total before now showed actual value and was going in reverse.

I solved it by adding
values: [
{
value: 'CounterToday',
isNeedle: true,
scale: -1,
}
],
to the dial block definition.

But why did it change behaviour? Has the default behaviour changed?
willemd
Posts: 736
Joined: Saturday 21 September 2019 17:55
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.1
Location: The Netherlands
Contact:

Re: update changed behaviour of P1 dial

Post by willemd »

Screenshot-2023-02-01-112636.jpg
Screenshot-2023-02-01-112636.jpg (19.97 KiB) Viewed 177 times
Screenshot-2023-02-01-113425.jpg
Screenshot-2023-02-01-113425.jpg (19.66 KiB) Viewed 177 times
The update also added back the incorrect unit display. It should be kWh.
So I had to adapt the block definition also to get that correct again. It now reads:

Code: Select all

blocks['P1_today'] = {
    idx: 1,
    title:'Grid today',
    type: 'dial',
    values: [
        {
        value: 'CounterToday',
        isNeedle: true,
        scale: -1,
        unit: 'kWh',
        showunit: true
        }
    ],
    min: -10,
    max: 10,
    decimals: 3,
    showring: true,
    showunit: false,
    shownumber: true,
    width: 4
}

Lokonli
Posts: 2292
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: update changed behaviour of P1 dial

Post by Lokonli »

willemd wrote: Wednesday 01 February 2023 11:17 I updated to latest Dashticz version today and as result my P1 dial that showed daily total before now showed actual value and was going in reverse.

I solved it by adding
values: [
{
value: 'CounterToday',
isNeedle: true,
scale: -1,
}
],
to the dial block definition.

But why did it change behaviour? Has the default behaviour changed?
There was some change in the code to make behavior consistent with other power devices, some functionality has been added.

The unit should be ok, I'll check.

Good that you found a way already to adapt it to your needs.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest