Page 1 of 1

Ro Dump and Membrane flush

Posted: Sat Apr 22, 2017 6:40 pm
by duck
I would like some help with dumping RO output to drain (Port#X 12V wall wort to solenoid) before it hits the DI resin. The dump would start with an ATO low trigger and would need to run for about a minute to drop the TDS down to 1 or 2. It would cut off after the timer was done.

I would also like to trigger a port to flush the RO membrane via a timer, it would trigger every hour for around 3 minutes or so.

Also is there a way to increase the ATO timeout? I have it at 600 now which seems to be the max?

I need to start tinkering again with the code, I learned all this 5 years ago and everything has been rock solid. I just want to get back into it and refine some things! Thanks

Re: Ro Dump and Membrane flush

Posted: Sun Apr 23, 2017 12:04 pm
by duck
Also where can I find the web generator?

Re: Ro Dump and Membrane flush

Posted: Sun Apr 23, 2017 4:01 pm
by rimai
Web wizard:
http://forum.reefangel.com/viewtopic.php?f=8&t=6199
Try this:

Code: Select all

static unsigned long mytimer=0;
static boolean timeractive=false;
if (ReefAngel.LowATO.IsActive() && !timeractive) // If Low ATO is triggered
{
  timeractive=true;
  mytimer=now();
}
ReefAngel.Relay.Set(Port1,(now()-mytimer)<60)); // Port 1 for 1 minute after Low ATO is triggered
ReefAngel.Relay.Set(Port2,(now()-mytimer)<180)); // Port 2 for 3 minutes after Low ATO is triggered
if (!ReefAngel.LowATO.IsActive()) timeractive=false; // Wait for Low ATO to deactivate and disable timer

Re: Ro Dump and Membrane flush

Posted: Sun Apr 23, 2017 7:30 pm
by duck
thanks! Do you think this would work? I would like low ato to trigger the solenoid on port 5 for 3 minutes, clearing the higher TDS from between the membrane and the DI cartridges. After which, turn off port five and turn on port 7 to fill the sump until the ATO deactivates. Im just not sure if I would need to nest the operations? I havent uploaded anything yet, I will be using the web wizard to do it though.

Code: Select all

  //RO DUMP PRE DI
	  static unsigned long mytimer=0;
	  static boolean timeractive=false;
	  if (ReefAngel.LowATO.IsActive() && !timeractive) // If Low ATO is triggered
	  {
	    timeractive=true;
	    mytimer=now();
	  }

	  ReefAngel.Relay.Set(Port5,(now()-mytimer)<180)); // Port 5 for 3 minute after Low ATO is triggered

	  then
          
     ReefAngel.Relay.Set(Port7,(now()-mytimer)<180)); // Port 7 (until Low ATO is deactivated); after Port 5 is triggered
	  if (!ReefAngel.LowATO.IsActive()) timeractive=false; // Wait for Low ATO to deactivate and disable timer
        
	  ReefAngel.ShowInterface();

        }