mdegat01 / addon-amr2mqtt

HA Addon which runs rtlamr to read IDM power meter data and send to MQTT broker
MIT License
33 stars 15 forks source link

Change to multiplier and precision config options #43

Closed mdegat01 closed 2 years ago

mdegat01 commented 2 years ago

Need both multiplier and precision options in config to convert unit and keep precision in check from float issues.

Also took added state_class to discovery message for consumption sensors so they quality for Long-Term Statistics. For IDM interval consumption we're now using TransmitTimeOffset to calculate last_reset which I'm not 100% sure about but will test.

Besides that some refactoring into constants.