I don't think you have told me which model of Arduino you have.
Its an Arduino Mega knockoff. Here is a link to it:https://www.amazon.com/gp/product/B01H4ZLZLQ/ref=ppx_yo_dt_b_asin_title_o08_s00?ie=UTF8&psc=1
I believe I've found the problem. It is a faulty board. I switched with another knockoff from a different vendor and the problem seems to have gone away. Yaaaaaaay! :). I sure hope it doesn't come back.
I had a quick look thorough your code (which would be a lot easier if it were not in a pdf document !).
Unfortunately I cannot help much because you do things very differently to how I would, and you use the Nextion libraries, which I would not touch with a barge pole (British expression).
I have attached the ino file if you're still interested. I understood the barge pole expression. Here it's 10 foot pole. I bet a barge pole is longer. 
I have no idea if your use of the Nextion library is correct or not. Note that the original Nextion library is full of bugs, there is a link from my tutorial to a better version by Ray Livingston, I suggest you try it. There is also Easy Nextion Library. Alternatively study my tutorial and use my methods, which don't use a library but do come with me to help. However, you will have to re-write your code and your Nextion configuration to use my methods.
I'm using an upgraded version of the Nextion library which came out last year. It appears to behave a lot better. I'll take a look at the other libraries you suggested. I'll also take a look at your methods which I'm very interested in.
However, at this point I have so much time and energy invested I'm going to stay the current course. I need to get this up and running and rewriting is not an option at the moment. I have a duplicate setup at my computer that I used for development. All of the options are not in the software yet and will take more time to write, test and initiate. Once complete, I can upload the option/improvements to the actual project which will reside in the garage. It is a system to control my pool and I want to get it out there because I'll be closing the pool again in 3 months.
Why are you using analogueWrite() to turn relays on and off?
This will be changed. Originally I was trying to use minimum current flow in order to reduce the load on the board. You helped me with that by telling me about the buck converter.
Don't use delay(). Ever
Removed
Have a read of
Demonstration for several things at the same time
Using millis for timing
Have looked at these and intend to incorporate them where needed.
I noticed at least 1 instance of String (capital S). Don't use String either, it causes problems with memory use leading to all sorts of odd behaviour, including processor restarts.
There is only one instance of String. I used it to receive a title in printTime(). This function tagged on to the end of different debugging Serial.print statements to tell me which function they were coming from. String will not be used during normal program run time.
I didn't know that String could cause any trouble. Thank you.
I have attached four photos of the project. Yes, I know it looks a bit messy, but its functional. The enclosure is too small. Like trying to stuff 5 Lb into a 1 Lb bag. It will probably be rebuilt at a later date. This is basically a prototype. There were a number of afterthoughts added on, so next time, bigger box.
Thank you again for your time and patience. I'm sure we'll be talking again in the near future, especially when I look into your methods of interacting with the Nextion.
By the way, did I mention I have a private pilots license? Almost as good as going into space :o .
PoolFilterSystem.ino (20.8 KB)