Need A Hand From A Resident APEX Code Guru:

  • Thread starter Thread starter Fish Styx
  • Start date Start date
  • Tagged users Tagged users None

Fish Styx

In Cod We Crust
View Badges
Joined
May 10, 2020
Messages
15,909
Reaction score
92,339
Location
Washington, DC Metro
Rating - 100%
1   0   0
Hey, all. I need a hand with an APEX script, if you please. Here's the rundown: I have two PMUPs in my ATO res. One goes directly to a float switch in the return section of the sump. The other routes to a Kalk reactor, that in-turn, discharges into the return section of the sump. The return section has dual optical sensors, marking high and low limits. I need a hand with the control script that would do the following:

If the sump level is low and ph is >8.2, turn on the ATO PMUP. turn it off when the sump high limit is reached.
if the sump level is low and ph is < 8.2, turn on the Kalk PMUP. turn it off when the sump high level is reached

Any and all help or guidance is absolutely welcomed and appreciated, as I begin turning on different features of my system and coding isn't my forte. I've always been able to hunt around and find what I've been looking for, but can't seem to track something like this down.

Namaste.
 
Bueller..? Bueller..?
I’m 3 jaegers and a pepper vodka in over here…

Honestly whenever I have an issue like this I email [email protected] and they help me. Not the exact answer you want, but they always give me the code within 24 hours and away I go.
 
I’m 3 jaegers and a pepper vodka in over here…

Honestly whenever I have an issue like this I email [email protected] and they help me. Not the exact answer you want, but they always give me the code within 24 hours and away I go.
I appreciate that, thanks.
 
You will need to use virtual outlets to make this happen. Definitely doable. Let me run a few test to verify the programing.

What are your high and low optical sensor names, pmup names, and pH probe name? Just for clarity posting the code.
 
You will need to use virtual outlets to make this happen. Definitely doable. Let me run a few test to verify the programing.

What are your high and low optical sensor names, pmup names, and pH probe name? Just for clarity posting the code.
Thank you!
 
This program runs without any virtual outlets. I added in a shutdown for the Kalk_Pmup If the pH rises over 8.5 as a safety to prevent an overdose. You can adjust the times to your preferences. Just keep in mind that you cannot have both pumps set to <>8.2 or they will both run if the pH is exactly 8.2 which will happen with this setup.

The last line is for power management on battery backup and can be removed if you are not monitoring your Apex power.

ATO_Pmup program:

Fallback OFF
Set OFF
If Sump_Lo OPEN Then ON
If Sump_Hi CLOSED Then OFF
If DT_Ph < 8.19 Then OFF
When On > 010:00 Then OFF
Defer 000:10 Then ON
Defer 000:04 Then OFF
Min Time 020:00 Then OFF
If Power Apex Off 002 Then OFF


Kalk_Pmup program:

Fallback OFF
Set OFF
If Sump_Lo OPEN Then ON
If Sump_Hi CLOSED Then OFF
If DT_Ph > 8.2 Then OFF
If DT_Ph > 8.5 Then OFF
When On > 010:00 Then OFF
Defer 000:10 Then ON
Defer 000:04 Then OFF
Min Time 020:00 Then OFF
If Power Apex Off 002 Then OFF

Email_Alarm program:
Add these 3 lines:

If DT_Ph > 8.49 Then On
If Error ATO_Pmup Then ON
If Error Kalk_Pump Then ON
 
This program runs without any virtual outlets. I added in a shutdown for the Kalk_Pmup If the pH rises over 8.5 as a safety to prevent an overdose. You can adjust the times to your preferences. Just keep in mind that you cannot have both pumps set to <>8.2 or they will both run if the pH is exactly 8.2 which will happen with this setup.

The last line is for power management on battery backup and can be removed if you are not monitoring your Apex power.

ATO_Pmup program:

Fallback OFF
Set OFF
If Sump_Lo OPEN Then ON
If Sump_Hi CLOSED Then OFF
If DT_Ph < 8.19 Then OFF
When On > 010:00 Then OFF
Defer 000:10 Then ON
Defer 000:04 Then OFF
Min Time 020:00 Then OFF
If Power Apex Off 002 Then OFF


Kalk_Pmup program:

Fallback OFF
Set OFF
If Sump_Lo OPEN Then ON
If Sump_Hi CLOSED Then OFF
If DT_Ph > 8.2 Then OFF
If DT_Ph > 8.5 Then OFF
When On > 010:00 Then OFF
Defer 000:10 Then ON
Defer 000:04 Then OFF
Min Time 020:00 Then OFF
If Power Apex Off 002 Then OFF

Email_Alarm program:
Add these 3 lines:

If DT_Ph > 8.49 Then On
If Error ATO_Pmup Then ON
If Error Kalk_Pump Then ON
Dude! Thank you so much! I really appreciate all of the time and effort that it took to put this together for me. Namaste.
 

TOP 10 Trending Threads

HOW DO YOU HANDLE HOLIDAY DECORATING AROUND YOUR REEF?

  • I decorate the tank or stand

    Votes: 1 5.3%
  • I decorate AROUND the tank or stand

    Votes: 3 15.8%
  • I add one small seasonal touch but keep it very basic

    Votes: 0 0.0%
  • I take a holiday photo, but don’t decorate the space

    Votes: 0 0.0%
  • I leave the reef area as it is

    Votes: 11 57.9%
  • We don’t decorate for the holidays

    Votes: 4 21.1%
  • Other (Post in the comments)

    Votes: 0 0.0%
Back
Top
Home
Post thread…
Market
What's new