Pump Schedule for WP-25

Do you have a question on how to do something.
Ask in here.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Pump Schedule for WP-25

Post by lnevo »

So what happened was because your time check for the Constant mode was invalid, you would never enter that mode, so by exiting Custom mode and going back into it, you put the DCPump back to some setting and then disabled it again leaving it at whatever speed it got. In this case 39.
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

lnevo wrote:So what happened was because your time check for the Constant mode was invalid, you would never enter that mode, so by exiting Custom mode and going back into it, you put the DCPump back to some setting and then disabled it again leaving it at whatever speed it got. In this case 39.
I see, that makes sense.

I just uploaded the updated code. Everything seems fine. I will wait until 9:30pm for the first schedule to start.

Thanks Lee!
Jack
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

Still playing around w/ my wp-25 schedule. I've updated this part of the code to include an additional time frame. Did I do this right by adding the "else if" statement for the middle (the new one) schedule?

Code: Select all

 if (ReefAngel.DCPump.Mode==Custom)
            {
              if ( (now()%SECS_PER_DAY >= 77400) || (now()%SECS_PER_DAY<= 34200) )
              {
                ReefAngel.PWM.SetActinic(30); // Constant at 30% on sync mode
              }
              else if ( (now()%SECS_PER_DAY >= 34200) || (now()%SECS_PER_DAY<= 48600) )
              {
                ReefAngel.PWM.SetActinic(33); // Constant at 33% on sync mode
              }
              else if ( (now()%SECS_PER_DAY >= 48600) && (now()%SECS_PER_DAY<= 77400) )
              {
                ReefAngel.PWM.SetActinic( ElseMode(37,7,true));   // Else on sync mode, 37 +/- 7%
              }
            }  
Thanks in advance!
Jack
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Pump Schedule for WP-25

Post by lnevo »

Yep worked great. Keep in mind the ifs if will choose the first match.
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

Ok, something must be messed up w/ the code I uploaded. The pump did not go into else mode at 1:30pm. Does this have to do w/ your comment above? If so, how do I solve that? Thanks.
Jack
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

I think I've narrowed it down to whether the last 2 "ifs" need "&&" or "||"....My first guess is that the middle "if" should have "&&" as opposed to what is there now, "||".

Am I close?
Jack
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Pump Schedule for WP-25

Post by lnevo »

Yes, the second one should be &&.

And yes, what I said about the first match applies. Since the second if is an OR statement and the time is greater than 34200 then the second condition is matching. It should an an AND since you want it between those bounds.
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

Ok, thanks! I finally understand. I will adjust and re-upload tonight.
Jack
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Pump Schedule for WP-25

Post by lnevo »

Isn't it great that you have the option of picking reefcrest or another mode and setting your speed manually through the portal until you get home to reupload :)
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

Haha. You're right! It's so great that I totally forgot I had that option. I was going to just let it run until I got home. I just switched to reef crest, which I guess is the closest to else mode.

Love it!
Jack
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Pump Schedule for WP-25

Post by lnevo »

Yeah ReefCrest is pretty close. I'm not really sure the difference to tell the truth, but ElseMode is definitely more successful in the turbulence department :)
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

Well..speaking of reef crest mode. I set it w/ a avg speed of 36 and a duration of 6. Even w/ that, the portal (and reeftronics) is telling me that the pump is going (or has gone) over 50%....Something's not right there. My impression is that is should run in the range between 30 and 42%....back to constant mode to be safe... :?
Jack
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Pump Schedule for WP-25

Post by lnevo »

Jack,

The Duration value is not used in ReefCrestMode. The +/- on ReefCrestMode is hard coded to 20% +/-
Lagoon Mode seems to be a bit gentler and will be the DCPump.Speed +/- 10% instead of the 20%.

Just so things make sense...
howaboutme
Posts: 245
Joined: Tue Jan 28, 2014 11:10 am
Location: Northern VA

Re: Pump Schedule for WP-25

Post by howaboutme »

Oh! Didn't realize that. Thank you.
Jack
Post Reply