Page 1 of 1

2 different size jebao pumps

Posted: Thu Dec 22, 2016 1:13 pm
by Reefology
I assume the following line of code is to offset water volume of different pumps but not exactly sure?

ReefAngel.DCPump.AntiSyncOffset=85;

how would I use this and where would I put it in my code?

thanks

Code: Select all

void loop()
{
    ReefAngel.ActinicLights( Port1 );
    ReefAngel.DayLights( Port2 );
    ReefAngel.StandardHeater( Port3 );
    ReefAngel.StandardLights( Port4, 19,0,7,0); //Skimmer, Reactor 7pm-7am
    ReefAngel.StandardLights( Port5 );
    ReefAngel.DosingPumpRepeat1( Port6 );
    ReefAngel.DosingPumpRepeat2( Port7 );
    ReefAngel.DosingPumpRepeat3( Port8 );
    ReefAngel.PWM.DaylightPWMParabola();
    ReefAngel.PWM.ActinicPWMParabola();
    ReefAngel.DCPump.UseMemory = true;
    ReefAngel.DCPump.LowATOChannel = Sync; // WP40 
    ReefAngel.DCPump.HighATOChannel = AntiSync; // SW 8 
    
    ////// Place your custom code below here
    
    // DC pumps
    // To run this code must choose Custom in portal
    static int rmode;
    static boolean changeMode=true;

    // These are the modes we can cycle through. You can add more and even repeat...
    byte modes[] = { ReefCrest, Lagoon, TidalSwell, ShortPulse, Sine, LongPulse, Else, Gyre, NutrientTransport };

    if (now()%600==0 || changeMode==true) { // Change every 10 mins (600seconds) or controller reboot
    rmode=random(100)%sizeof(modes); // Change the mode by picking from our array
    changeMode=false;
    }

    // Set timer when in feeding mode
    static unsigned long feeding;
    if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
    // Continue NutrientTranspot Mode for 30 minutes after feeding
    if (now()-feeding<1800) {
    ReefAngel.DCPump.UseMemory=false;
    ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
    ReefAngel.DCPump.Mode=NutrientTransport;
    // Night mode (go to 30%)
    } else if (now()%SECS_PER_DAY<39600 || now()%SECS_PER_DAY>=82800) { // 11am / 11pm
    ReefAngel.DCPump.UseMemory=false;
    ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
    ReefAngel.DCPump.Mode=Gyre;
    ReefAngel.DCPump.Speed=30;
    } else if (InternalMemory.DCPumpMode_read()==11) {
    // Custom Mode and nothing else going on
    ReefAngel.DCPump.UseMemory=false;
    ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
    ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
    ReefAngel.DCPump.Speed=InternalMemory.DCPumpSpeed_read(); // Set speed from portal
    } else {
    ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
    }

    ////// Place your custom code above here

Re: 2 different size jebao pumps

Posted: Thu Dec 22, 2016 1:56 pm
by lnevo
You can run it in loop or in setup and it will set the percentage for the pump you set as AntiSync. So that one will go at 85% of the speed of the primary.

Re: 2 different size jebao pumps

Posted: Thu Dec 22, 2016 3:31 pm
by Reefology
thanks for the reply Lee. can I change it to

ReefAngel.DCPump.SyncOffset=85;

if the primary is the bigger pump? Or

ReefAngel.DCPump.AntiSyncOffset=115; ?

Re: 2 different size jebao pumps

Posted: Thu Dec 22, 2016 8:25 pm
by Reefology
thanks Lee, found the thread

http://forum.reefangel.com/viewtopic.ph ... SyncOffset

will link it here for others.

thanks

Re: 2 different size jebao pumps

Posted: Sat Dec 24, 2016 6:43 pm
by lnevo
Reefology wrote:thanks for the reply Lee. can I change it to

ReefAngel.DCPump.SyncOffset=85;

if the primary is the bigger pump? Or

ReefAngel.DCPump.AntiSyncOffset=115; ?
I think you can do that as well. It just makes that a percentage and multiplies it against the sync pump's speed.