1) Give a description of the problem
My Heat and A/C automation piston is working quite well, but I have been adding functionality to it and it has gotten a bit difficult to maintain.
2) What is the expected behavior?
I have a couple of pistons that work together to control my two thermostats based on the local outside temperature, if windows are open, time, presence, and soon I will add modes.
3) What is happening/not happening?
I am not a programmer by training but I think that there must be a better way to code this than what I have done. I suspect that I need to add some loops to eliminate a lot of the duplicated code but I am not familiar with their use.
4) Post a Green Snapshot of the piston
Here are the two pistons that are currently running the heat and A/C automation in my home. Any suggestions on ways to make them better would be greatly appreciated.
5) Attach any logs (From ST IDE and by turning logging level to Full)
Piston seems to be too big to allow logs to be created