Below is the complete program that I am running in my AC3 controller.
Feel free to reference it, copy it or use it in any manner that you
wish. I have separated the code into 2 sections;
Timers and
Program.
ADD&-P04 // Add water (refug float)
ALM&-A06 // Alarm
AL2&-P06 // Alarm 2 (chimes 1 per hour during the day only, off at
night)
CLN#-B04 // Skimmer cleaner
CO2&-A03 // CO2 for CA Reactor
DAY&-N01 // Daytime
//FED&-N02 // Feed Cycle Active
LOW&-P05 // Refug water too low
MHD$-B01 // MhD
MHF&-A05 // MhD Fan
MON$-D01 // LunarSim
OVR&-P03 // Refug water level too high
PO4%-A01 // P04 reactor pump
REF$-A04 // Refugium light
ROB&-P02 // RO/DI makeup out of water
ROT&-P01 // RO/DI reserve getting low
RTN#-A02 // Main return pump
SKM#-B03 // Skimmer
STR#-A08 // Kalk reactor stir
VHO$-B02 // VHO lights
WTR#-A07 // Topoff (LM3)
WV1#-E01 // AquaSurf pump 1&2 (left side)
WV2#-E02 // AquaSurf pump 3&4 (right side)
WV3#-E03 // AquaSurf pump 5 (left rear)
WV4#-E04 // AquaSurf pump 6 (right rear)
// Alarm (ALM) triggers an email, any time of the day
If Time > 00:00 Then ALM OFF
If Timer AL2 = ON Then ALM ON
If Timer ROB = ON Then ALM ON
If Timer LOW = ON Then ALM ON
If Timer DAY = OFF Then ALM OFF
// AL2 is a warning, chimes once per hour for 1 minute
OSC 001/060 ON/OFF Then AL2 ON
If Timer DAY = OFF Then AL2 OFF
If Timer ROT = OFF Then AL2 OFF
If pHA1 < 07.00 Then AL2 OFF
// P04 reactor pump (always on)
If Time > 00:00 Then PO4 ON
// Return pump, always on, except if water level too low in sump
If Time > 00:00 Then RTN ON
If FeedA 000 Then RTN OFF
If FeedC 000 Then RTN OFF
If Timer LOW = ON Then RTN OFF
Max Change 005 M Then RTN OFF
// Skimmer, always on
If Time > 00:00 Then SKM ON
If FeedD 000 Then SKM OFF
// Timer to manage daytime vs night (warning alarm only on during the
day)
If Time > 00:00 Then DAY OFF
If Timer VHO = ON Then DAY ON
If Timer MHD = ON Then DAY ON
// Clean the skimmer 1 min per day (really 10 seconds)
If Time > 09:00 Then CLN ON
If Time > 09:01 Then CLN OFF
// RO bucket getting low
If SwitchA1 Open Then ROT OFF
If SwitchA1 Closed Then ROT ON
// RO bucket is empty
If SwitchA2 Open Then ROB OFF
If SwitchA2 Closed Then ROB ON
// Water level in sump is too high
If SwitchA3 Open Then OVR OFF
If SwitchA3 Closed Then OVR ON
If FeedA 002 Then OVR OFF
If FeedC 002 Then OVR OFF
If Power 002 Then OVR OFF
If Timer RTN = OFF Then OVR OFF
// Need top-off
If SwitchA4 Open Then ADD OFF
If SwitchA4 Closed Then ADD ON
// Sump water level is low
If SwitchA5 Open Then LOW OFF
If SwitchA5 Closed Then LOW ON
OSC 005/240 ON/OFF Then STR ON
If Sun 000/000 Then VHO ON
Max Change 001 M Then VHO OFF
If Power 001 Then VHO OFF
If Timer VHO = ON Then REF ON
If Timer VHO = OFF Then REF OFF
If Power 001 Then REF OFF
If Sun 060/-060 Then MHD ON
Max Change 015 M Then MHD OFF
If Power 015 Then MHD OFF
If Timer MHD = OFF Then MHF OFF
If Timer MHD = ON Then MHF ON
If Moon 000/000 Then MON ON
If Timer VHO = ON Then MON OFF
If Timer MHD = ON Then MON OFF
If pHA1 > 06.25 Then CO2 ON
If pHA1 < 06.20 Then CO2 OFF
Max Change 005 M Then CO2 OFF
If Power 005 Then CO2 OFF
If Timer VHO = ON Then WV1 PF1
If Timer MHD = ON Then WV1 PF3
If Timer VHO = OFF Then WV1 PF5
If FeedB 000 Then WV1 OFF
If FeedC 000 Then WV1 OFF
If Timer VHO = ON Then WV2 PF2
If Timer MHD = ON Then WV2 PF4
If Timer VHO = OFF Then WV2 PF6
If FeedB 000 Then WV2 OFF
If FeedC 000 Then WV2 OFF
Pmp MODE sD for PF1
Pmp Int 030/075 for PF1
Pmp OSC 04/08/00 for PF1
Pmp MODE SD for PF2
Pmp Int 030/075 for PF2
Pmp OSC 00/08/04 for PF2
Pmp MODE sD for PF3
Pmp Int 030/100 for PF3
Pmp OSC 04/08/00 for PF3
Pmp MODE SD for PF4
Pmp Int 030/100 for PF4
Pmp OSC 00/08/04 for PF4
Pmp MODE sD for PF5
Pmp Int 030/050 for PF5
Pmp OSC 04/08/00 for PF5
Pmp MODE SD for PF6
Pmp Int 030/050 for PF6
Pmp OSC 00/08/04 for PF6
If FeedA 005 Then WTR OFF
If FeedC 005 Then WTR OFF
Max Change 005 M Then WTR ON
If Timer ADD = ON Then WTR ON
If Timer ADD = OFF Then WTR OFF
If Timer RTN = OFF Then WTR OFF
If Timer ROB = ON Then WTR OFF
If Timer OVR = ON Then WTR OFF
If pH > 08.50 Then WTR OFF
If Timer RTN = ON Then CHL ON
If Timer RTN = OFF Then CHL OFF