Modification to StandardATO

Do you have a question on how to do something.
Ask in here.
Post Reply
jpalmer
Posts: 31
Joined: Tue May 01, 2012 11:49 pm

Modification to StandardATO

Post by jpalmer »

Hey all,

I'm about to order an eheim 300 pump for ATO, but I'd like to do it slightly differently that the way StandardATO does.

Ultimately, I'd like a 3rd float switch. The 3rd will be in the reserve container. I want standardATO to work the way it normally does, *only* if the 3rd float switch indicates there is water in the reserve.

I have 2 questions, will I need ti I/O board to connect a 3rd float switch?

And, Would you just use an "if" statement in the loop() to check for the status of the reserve float, or would you write a whole new function based on StandardATO?
I haven't looked into "best practices" for the arduino yet, so I'm not sure if wrapping StandardATO inside of an 'if' block would work, or even if it would.. if it'd be the best way.


Actually, since I'm posting anyway.. another question: I can't find any kind of "mirror" or "clone" library. but I'd like to have a port in the relay box mirror the status of another port. Would it be better to just have the sketch use the identical logic (memory, and processing time) as the original port, or would you write a small function to just mirror the existing status of the port which would probably be less memory size and definately less processing time in the loop()
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Modification to StandardATO

Post by rimai »

Yes, you will need the I/O module.
Then you can use this:

Code: Select all

  if (ReefAngel.IO.GetChannel(0))
    ReefAngel.StandardATO(Port1);
  else
    ReefAngel.Relay.Off(Port1);
To have one port the same as the other, use this:

Code: Select all

  ReefAngel.Relay.Set(Port1,ReefAngel.Relay.Status(Port2));
Roberto.
Post Reply