Closed vaniwaar closed 5 years ago
This is verified as a known bug. Schedules crossing midnight will be cut short. Working on a fix. Sorry...
Just saw the TODO note in core.cpp...
Do want to say that this is a wonderful piece of software and I am deeply appreciative of your writing it. For about $150 I have a web based sprinkler control system that is many times more powerful than any of the ones I can buy off the shelf and I get SOURCE CODE!
This code adjusts the schedule for events after midnight I believe
void RemoveEventsNotScheduledAfterMidnight() { int newNumEvents = 0; for (int i=0; i < iNumEvents; ++i) { if (events[i].time > 1440) { events[i].time -= 1440; events[newNumEvents++] = events[i]; } } iNumEvents = newNumEvents; }
Then the top of ReloadEvents then becomes void ReloadEvents(bool bAllEvents) { if (false == bAllEvents) { ClearEvents(); TurnOffZones(); } else { RemoveEventsNotScheduledAfterMidnight(); }
Just remove clearEvent() and forget TurnOffZone() this will merge the newer event
where is the code to correct? this bug also affects me
I scheduled the yard system to run at 11:30 at night. The first zone took 27 minutes, the second zone took 25 minutes and then no more zones went. I haven't had a chance to really get into the code yet but will see what I can find. For now, I have changed my schedule to just start after midnight...