Negative values - Home Assistant - grid export

I have an Emonpi linked with Home Assistant and I’m trying to get the energy section of Home Assistant to work correctly but it does not like negative values, I have one CT sensor on the main grid feed in, I’ve split this into two feeds one only allows positive numbers (grid importing) the other only allows negative numbers (grid exporting)

Within the input options is there away or removing the negative value so grid exporting is not negative, pretty sure it’s possible in Home Assistant but not had any joy with the forums.

I’ve no knowledge of Home Assistant, but if you multiply the negative-only value by -1 in your input processing (after you’ve saved it - if you need to save it), it will always be positive-only (or zero!). If you can do that before you send it, that should be a work-around.

Or, if Home Assistant allows you to scale values, will it accept -1 as a scale factor?

1 Like

Thanks Robert,

That worked like a charm all feeds are now positive, all ready for the solar panels to be turned on early next week.