Add support for a new parameter scale_division in the YAML definition files which allows to divide the register(s) value by a constant number provided. The division is always done after the scaling happened.
This is useful for example for registers that display a value in minutes, but you want the sensor to be in hours: in that case, simply add scale_division: 60 and change the unit of measurement accordingly.
If you want days from minutes, supply scale_division: 1440 (60 * 24) and so on...
I took the opportunity to fix a bunch of typos in the customization readme, too.
Add support for a new parameter
scale_division
in the YAML definition files which allows to divide the register(s) value by a constant number provided. The division is always done after the scaling happened.This is useful for example for registers that display a value in minutes, but you want the sensor to be in hours: in that case, simply add
scale_division: 60
and change the unit of measurement accordingly.So this sensor:
can be transformed to this:
If you want days from minutes, supply
scale_division: 1440
(60 * 24) and so on... I took the opportunity to fix a bunch of typos in the customization readme, too.