Hi to everyone,
I’m experiencing a strange behaviour after converting the DB from sqlite to mysql:
I have a sonoff POW3 connected between the grid and my home electrical system with this configuration:
#Contabilizzatore energia
utility_meter:
montly_energy:
source: sensor.contatore_principale_energy_today
name: Contatore Mensile
unique_id: custom.meter.energy
cycle: monthly
tariffs:
- F1
- F2
- F3
until I used the sqlite DB everything went fine, but when I moved to mariadb the sum went nuts
other than that I have not changed anything. I also changed the €/KW/h cost to only 2 decimal digits (0,14 instead of 0,1436) but nothing changed.
what else should I check?
UPDATE:
I deleted the cost, rebooted, re-added the cost, rebooted. Same behaviour.
Now I’ve tried to add a daily-based meter
utility_meter:
daily_energy:
source: sensor.contatore_principale_energy_today
name: Contatore Giornaliero
unique_id: custom.daily_meter.energy
cycle: daily
tariffs:
- F1
- F2
- F3
on the same sensor.
The result is the same:
0,65 kWh → 1,12 € with a fixed price of 0,143 EUR/KWH