Page 1 of 1

DCPump vs. PWM.SetDaylight

Posted: Mon Jul 08, 2013 6:02 pm
by clw143
Can someone explain why the DCPump settings only uses speed and duration where PWM.SetDaylight uses more fields like min speed, max speed, wave speed, duration, offset?

Are the rest of the values just hard coded and used for calculations for the rest?

Re: DCPump vs. PWM.SetDaylight

Posted: Mon Jul 08, 2013 6:18 pm
by rimai
Correct.
The other settings are hard coded for simplicity of use.
It was created so the Wizard would be able to generate codes easily and integrate with the Portal seamlessly.
Now, if you prefer to really dial down to the way you want, you might as well not use the DCPump class and hard code it with the PWM channel directly.

Re: DCPump vs. PWM.SetDaylight

Posted: Mon Jul 08, 2013 6:37 pm
by clw143
Ok, So if I have a pump mode selected by time in my code and I have memory enabled for the DCPump, and change it on the portal, how do I get the memory to give up being the leader? Or is it just set by portal/memory until the next time change comes?

Re: DCPump vs. PWM.SetDaylight

Posted: Mon Jul 08, 2013 6:46 pm
by rimai
If you are using the DCPump class, you use this to enable memory:

Code: Select all

ReefAngel.DCPump.UseMemory=true;
An this to disable and use your own hard code mode:

Code: Select all

  ReefAngel.DCPump.UseMemory=false;
  ReefAngel.DCPump.SetMode(ShortPulse,80,10);