Nilsen reactor

Basic / Standard Reef Angel hardware
Post Reply
johniii
Posts: 86
Joined: Sun Mar 03, 2013 8:37 am

Nilsen reactor

Post by johniii »

This weekend I will be getting a mrc Nilsen reactor.

I need to set my ato so that if the reactor has run in the last thirty minutes it won't turn on the pump. How would one go about coding this?

Sent from my DROID RAZR using Tapatalk 2
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Nilsen reactor

Post by rimai »

How do you turn your reactor on/off?
Roberto.
johniii
Posts: 86
Joined: Sun Mar 03, 2013 8:37 am

Re: Nilsen reactor

Post by johniii »

Going to use port 1 on a schedule

Sent from my DROID RAZR using Tapatalk 2
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Nilsen reactor

Post by rimai »

Can you post an example?
Roberto.
johniii
Posts: 86
Joined: Sun Mar 03, 2013 8:37 am

Re: Nilsen reactor

Post by johniii »

Haven't wrote the code yet. But will be port 1 on every hour for 5 mins.

I guess I need a if else statement for the ato.

Just don't need the ato to come on if the reactor has just stirred the kalk.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Nilsen reactor

Post by rimai »

That would mean you only want the ATO to work the last 25min of every hour, right?
Roberto.
johniii
Posts: 86
Joined: Sun Mar 03, 2013 8:37 am

Re: Nilsen reactor

Post by johniii »

Yes that should work
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Nilsen reactor

Post by binder »

if you are going to run port 1 for 5 minutes every hour on a schedule, then you could use the dosingpumprepeat functions.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Nilsen reactor

Post by rimai »

Try this and see if it works:

Code: Select all

  if (now()%3600<2100)
  {
    ReefAngel.Relay.Off(Port2);
    ReefAngel.LowATO.Timer=millis();
  }
  else
  {
    ReefAngel.SingleATO(true,Port2,60,0);
  }
Roberto.
johniii
Posts: 86
Joined: Sun Mar 03, 2013 8:37 am

Re: Nilsen reactor

Post by johniii »

rimai wrote:Try this and see if it works:

Code: Select all

  if (now()%3600<2100)
  {
    ReefAngel.Relay.Off(Port2);
    ReefAngel.LowATO.Timer=millis();
  }
  else
  {
    ReefAngel.SingleATO(true,Port2,60,0);
  }
Will try it and see.

But for the sake of me learning and not having to bug you guys, what do the numbers on the first line mean
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Nilsen reactor

Post by rimai »

It's seconds.
3600 = 1 hour
2100 = 35 minutes
% is a mathematical operation called modulo:
http://arduino.cc/en/Reference/Modulo
Roberto.
johniii
Posts: 86
Joined: Sun Mar 03, 2013 8:37 am

Re: Nilsen reactor

Post by johniii »

rimai wrote:It's seconds.
3600 = 1 hour
2100 = 35 minutes
% is a mathematical operation called modulo:
http://arduino.cc/en/Reference/Modulo

Thanks Roberto that's what I needed to know
Helpful as always
Post Reply