Neptune Apex Programming Tutorials, Part 2: Timers

TangoTang

Active Member
View Badges
Joined
Dec 8, 2015
Messages
119
Reaction score
89
Location
Miami
Rating - 0%
0   0   0
Hi I’d like some help

So I want to run a power head to clean debris from the bottom of my tank everyday expect the weekends from 7am to 8am. when this power head is on I want my other power heads and gyre to be off.

my program for the power head that will clean the tank is this:

If Time 07:00 to 7:59 Then On
If DoW S-----S Then OFF

now when I apply this to the rest of my power heads including the gyre that I want working all the time except when this powerhead turns on I’ve written this for the rest of the pumps just mentioned:

If Time 07:00 to 7:59 Then OFF
If DoW S-----S Then OFF

the problem I’m facing is that the last line is being read as turn off the gyres and main pumps on the weekend and they don’t run on Saturday or sunday. How do I have the main pumps run all the time while still including this schedule I want to incorporate

hope I explained this correctly and I’ll be open to suggestions on how to better this schedule

any form of support is appreciated thank you guys in advance and for this great tutorial as well
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
Hi I’d like some help

So I want to run a power head to clean debris from the bottom of my tank everyday expect the weekends from 7am to 8am. when this power head is on I want my other power heads and gyre to be off.

my program for the power head that will clean the tank is this:

If Time 07:00 to 7:59 Then On
If DoW S-----S Then OFF

now when I apply this to the rest of my power heads including the gyre that I want working all the time except when this powerhead turns on I’ve written this for the rest of the pumps just mentioned:

If Time 07:00 to 7:59 Then OFF
If DoW S-----S Then OFF

the problem I’m facing is that the last line is being read as turn off the gyres and main pumps on the weekend and they don’t run on Saturday or sunday. How do I have the main pumps run all the time while still including this schedule I want to incorporate

hope I explained this correctly and I’ll be open to suggestions on how to better this schedule

any form of support is appreciated thank you guys in advance and for this great tutorial as well

The simple way to accomplish this is with a virtual output that only comes on each weekday morning. Then program your cleaning powerhead to turn On when this virtual output is on, and your other powerheads turn Off when this virtual output is on:

CleaningCycle (virtual output)
--------------------
Set OFF
If Time 07:00 to 7:59 Then ON
If DoW S-----S Then OFF

Cleaning Powerhead
----------------
Set OFF
If Output CleaningCycle = ON Then ON

Other Powerheads
--------------------------
(existing programming here)
If Output CleaningCycle = ON Then OFF


See my other tutorial on Virtual Outputs for more details on setting up virtual outputs.
 

TangoTang

Active Member
View Badges
Joined
Dec 8, 2015
Messages
119
Reaction score
89
Location
Miami
Rating - 0%
0   0   0
Just realized that my Apex Jr doesn’t have support virtual outlets... looks like I’m going to sacrifice an empty outlet to use this. I have four outlets empty so can I assign this to an actual outlet and will it still work?

thanks for the quick response btw
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
Just realized that my Apex Jr doesn’t have support virtual outlets... looks like I’m going to sacrifice an empty outlet to use this. I have four outlets empty so can I assign this to an actual outlet and will it still work?

thanks for the quick response btw

Yes, an unused physical output is essentially the same as a virtual output. Just remember if you ever plug something into that unused output it's going to turn On every weekday morning for 1 hour.
 

TangoTang

Active Member
View Badges
Joined
Dec 8, 2015
Messages
119
Reaction score
89
Location
Miami
Rating - 0%
0   0   0
The simple way to accomplish this is with a virtual output that only comes on each weekday morning. Then program your cleaning powerhead to turn On when this virtual output is on, and your other powerheads turn Off when this virtual output is on:

CleaningCycle (virtual output)
--------------------
Set OFF
If Time 07:00 to 7:59 Then ON
If DoW S-----S Then OFF

Cleaning Powerhead
----------------
Set OFF
If Output CleaningCycle = ON Then ON

Other Powerheads
--------------------------
(existing programming here)
If Output CleaningCycle = ON Then OFF


See my other tutorial on Virtual Outputs for more details on setting up virtual outputs.

ok just tried it with an actual outlet since I dont have access to virtual outlets and it works perfectly! Thank you so much!!!
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
Couldn’t you also just add a line to your gyre programming to say
If outlet CleaningPowerhead = On then off

Yes, you're correct. I thought of that after I had already posted the virtual output solution.

To clarify for @TangoTang16, this can be simplified without the need for a virtual or other unused output.

CleaningPowerhead (keep in mind output names are limited to 12 characters, so pick a shorter name)
--------------------------
Set OFF
If Time 07:00 to 7:59 Then ON
If DoW S-----S Then OFF

Other Powerheads
--------------------------
(existing programming here)
If Output CleaningPowerhead = ON Then OFF
 

GlassMunky

2500 Club Member
View Badges
Joined
Jan 30, 2014
Messages
2,807
Reaction score
3,585
Location
Philly
Rating - 0%
0   0   0
Im trying to figure out how to have a dosing pump turn on for 2 minutes and 15 seconds, once an hour, but only between the hours of 7A-7P.
Im assuming i need to use the OSC code and combine that with something else, maybe the TIme command, to make it only turn on between the 7A-7P?
Or would the OSC command not work cause it starts from midnight?
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
Im trying to figure out how to have a dosing pump turn on for 2 minutes and 15 seconds, once an hour, but only between the hours of 7A-7P.
Im assuming i need to use the OSC code and combine that with something else, maybe the TIme command, to make it only turn on between the 7A-7P?
Or would the OSC command not work cause it starts from midnight?

Try this:

OSC 000:00/002:15/057:45 Then ON
If Time 19:00 to 06:59 Then OFF
 

GlassMunky

2500 Club Member
View Badges
Joined
Jan 30, 2014
Messages
2,807
Reaction score
3,585
Location
Philly
Rating - 0%
0   0   0
Try this:

OSC 000:00/002:15/057:45 Then ON
If Time 19:00 to 06:59 Then OFF
I was thinking of going the opposite route of having the IF Time on then OSC but this makes more sense. Thanks!
should I maybe change the last part to IF Time 19:03 to 06:59 then OFF to allow it time to do the final dose of 2:15 at 7P (which would end at 19:02:15)
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
Hello. Can we combine two or more timer program?
I would like to use OSC program (000:00/005:00/025:00) from 21:00 to 6:00 only.
And if possible, only if PH < 8.0 too.
Can we make a code like this?

Yes. You just need to sequence the commands so OSC is first, then the If Time and pH restrictions to override the OSC next:

OSC 000:00/005:00/025:00 Then ON
If Time 06:00 to 21:00 Then OFF
If pH > 7.9 Then OFF
 

vadajo

New Member
View Badges
Joined
Oct 19, 2014
Messages
22
Reaction score
2
Rating - 0%
0   0   0
I have a Klir roller and sometimes the sensor get gunked up and keeps the motor on way too long resulting in clean unused filter being wasted. Is there a way to program the Apex to turn off its outlet if the Klir is on too long and then send me a message? Any suggestions would be appreciated.
 

Sleepydoc

Valuable Member
View Badges
Joined
Apr 10, 2017
Messages
1,423
Reaction score
1,265
Location
Minneapolis, MN
Rating - 0%
0   0   0
I have a Klir roller and sometimes the sensor get gunked up and keeps the motor on way too long resulting in clean unused filter being wasted. Is there a way to program the Apex to turn off its outlet if the Klir is on too long and then send me a message? Any suggestions would be appreciated.

The statement

When On > mmm:ss Then OFF

will turn the outlet off and trigger an error when the outlet has been on for greater than the specified time. (Note the outlet is fully OFF, not on 'auto.' with the outlet switched off. This means it will not come on again until you manually flip the outlet back to Auto in the Fusion interface.
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
I have a Klir roller and sometimes the sensor get gunked up and keeps the motor on way too long resulting in clean unused filter being wasted. Is there a way to program the Apex to turn off its outlet if the Klir is on too long and then send me a message? Any suggestions would be appreciated.
One way I can think of is to leverage the EB832's power monitoring capability. (Note: the older EB8, EB6 and EB4 do not have this capability.)

If your Klir is plugged into an EB832 output, and when its motor is running if the Apex can report how many watts it consumes compared to when it's off, then you could use this code:

[Klir] <-- EB832 output where Klir motor is plugged in
Set ON
If Output Klir Watts > 10 Then OFF
Defer 000:30 Then OFF
Min Time 060:00 Then OFF

[EmailAlm] <-- Alarm program output
Set OFF
If Output Klir = OFF Then ON

Just adjust the watts to the appropriate value for when the Klir motor is active, and adjust the Defer timer to the number of minutes : seconds you want for a limit.

See my tutorial on Apex Power Monitoring for more details on programming based on watts or amps:
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
The statement

When On > mmm:ss Then OFF

will turn the outlet off and trigger an error when the outlet has been on for greater than the specified time. (Note the outlet is fully OFF, not on 'auto.' with the outlet switched off. This means it will not come on again until you manually flip the outlet back to Auto in the Fusion interface.
The problem with this approach is that the Klir's output needs to be on at all times in order for the Klir's water level sensor to trigger the motor to advance the roll. The Apex doesn't tell the Klir when to run, so turning it off after x:xx time will never actually let the Klir do its job.
 

Mester320

Well-Known Member
View Badges
Joined
Jul 13, 2013
Messages
597
Reaction score
177
Location
Saint Marys, PA
Rating - 0%
0   0   0
What would my command look like if I needed my Geo kalk reactor stirrer to run 4 times/day for 30 seconds and the I need the kamoer fx dosing pump to run constantly unless the pH is greater than 8.4, thanks in advance for all your help
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
What would my command look like if I needed my Geo kalk reactor stirrer to run 4 times/day for 30 seconds and the I need the kamoer fx dosing pump to run constantly unless the pH is greater than 8.4, thanks in advance for all your help

For the Geo reactor, 4 times per day means a cycle every 6 hours, or 360 minutes. So you want the OSC timers to add up to 360, with it ON for 30 seconds and OFF for the remaining 359:30 minutes:

[Geo Kalk Reactor]
Fallback OFF
OSC 000:00/000:30/359:30 Then ON

[Kamoer Dosing Pump]
Fallback OFF
Set ON
If pH > 8.4 Then OFF
 
OP
OP
SuncrestReef

SuncrestReef

That Apex guy
View Badges
Joined
Jan 18, 2018
Messages
4,214
Reaction score
9,214
Location
Oregon
Rating - 0%
0   0   0
I just published a tutorial video about the Apex OSC command. It also includes a demonstration of my new OSC Calculator spreadsheet. Take a look:

 

Mester320

Well-Known Member
View Badges
Joined
Jul 13, 2013
Messages
597
Reaction score
177
Location
Saint Marys, PA
Rating - 0%
0   0   0
I ran into one other command that I need and it does not relate to the osc commands but I need to add a few lines to some of my outlets so that if my return pump RETURN_2_1 shuts off then they will be off until it kicks back on. Things like my heaters and recirculating skimmer pumps
 

Being sticky and staying connected: Have you used any reef-safe glue?

  • I have used reef safe glue.

    Votes: 92 87.6%
  • I haven’t used reef safe glue, but plan to in the future.

    Votes: 6 5.7%
  • I have no interest in using reef safe glue.

    Votes: 4 3.8%
  • Other.

    Votes: 3 2.9%
Back
Top