Hi Again... here is the next installment of my garden controller project. The newest problem is getting the fan_relay to behave as expected when the code for all 3 functions is included in the sketch and turned on. The code for each function works properly isolated from the other two but having any two functions working at the same time and the relay hysteresis will not work as expected. I do see why but don't know how to resolve it.
The three functions are Fan Cycle Timer, Humidity Controlled Fan, and Temperature Controlled Fan.
the cycle timer is user defined to set the cycle every x hours to run the fan for x minutes. The humidity and temperature have user defined set points that go on at set point and off at -3% or -2C respectively... again, it's clear to see why they won't work together but I just can't wrap my head around how to make them work together.
Some code is turned off to show some of my failed attempts and for other obvious reasons.
this is working code with the exception of this latest bug and, oh... is huge so I've attached it.
Any help will be greatly appreciated - thank you in advance!
Cycle_Timer_nano_V3.ino (25.8 KB)