And everything was working fine. But i need to move it to a trigger so i did it like below and it’s not working. So i can only use trigger:template for this?
It should handle negative numbers just fine, but I don’t quite understand what you mean by “the difference was less AVG 80 Trigger 75.”
You can test your template by copying it into the “template” field on the templates page of home assistant, under developer tools. Just replace the Paulus / Anne Therese example. It’s super helpful, and I would have never been able to get a template to work without it!
You can also spoof sensor values using the “states” developer tool, but I often find it easier to just tweak my template to test it (e.g. change the 15 in your template to a different number, just temporarily).