Skimmer Code Help

Do you have a question on how to do something.
Ask in here.

Posts: 34
Joined: Tue Aug 22, 2017 8:00 pm
PostPosted: Fri Aug 25, 2017 3:59 pm
Can someone please help me combine these statements

ReefAngel.Relay.DelayedOn( Box1_Port3,0 ); //Skimmer
// if ( ReefAngel.HighATO.IsActive() == 0 ) ReefAngel.Relay.Off( Box1_Port3 );
if ( ReefAngel.Relay.Status( Port6 ) ) ReefAngel.Relay.Off( Box1_Port3 );


when this code is used... the skimmer never turns on.... (I've toggled between 1 and 0 on the isactive () command)

any help would be great. trying to setup a multi layered condition where if the return pump is off or ATO High is triggered (skim bucket) then skimmer is off else on. Also on all restarts it waits 2 mins to kick on (I have it set to 0 for testing)

Posts: 34
Joined: Tue Aug 22, 2017 8:00 pm
PostPosted: Fri Sep 01, 2017 9:35 am
Bump

Posts: 12188
Joined: Fri Mar 18, 2011 6:47 pm
PostPosted: Fri Sep 01, 2017 9:53 am
Probably because port 6 is on and it is turning off box1_port.
If you do two statements, the last one will always overwrite any previous condition. You need to make it into one statement.
Roberto.
User avatar
Posts: 5342
Joined: Fri Jul 20, 2012 9:42 am
PostPosted: Fri Sep 01, 2017 1:50 pm
Code: Select all
if ( ReefAngel.HighATO.IsActive() == 0 || !ReefAngel.Relay.Status(Port6) ) {
  ReefAngel.Relay.Off( Box1_Port3 );
} else {
  ReefAngel.Relay.DelayedOn( Box1_Port3,0 ); //Skimmer
}

Posts: 95
Joined: Wed Sep 02, 2015 4:39 pm
PostPosted: Tue Feb 27, 2018 9:04 am
10pm on till 4pm off worked for me
Image

Return to How do I code ...

Who is online

Users browsing this forum: No registered users and 3 guests