Page 1 of 1

Re: RA Wizard - No Night Mode?

Posted: Sat Jan 11, 2014 11:04 am
by ReEfnWrX
http://forum.reefangel.com/viewtopic.php?f=14&t=3353

There is a post where someone took some basic Wizard generated code and explained it bit by bit. That is a good start, after that I would say look at threads where people ask how to do code... Will take time...

Re: RA Wizard - No Night Mode?

Posted: Sat Jan 11, 2014 11:26 am
by AnesthDoc
Great help!
I am taking my first step today. Thanks for helping me start.

Re: RA Wizard - No Night Mode?

Posted: Sat Jan 11, 2014 11:31 am
by ReEfnWrX
Only returning the favor, I just started in december... I am amazed at what you can accomplish with the RA

Re: RA Wizard - No Night Mode?

Posted: Thu Jan 16, 2014 11:10 am
by AnesthDoc
I am looking at this post for the Wave Pattern Modes and have a question.
http://forum.reefangel.com/viewtopic.php?f=7&t=2844

I click "Select All" next to the CODE then click copy.
Where in the main code do I paste this code?
Do I need to alter anything for the code to work and what if I wanted to tweak the variables, i.e time/duration etc.

Thanks in advance!!

Re: RA Wizard - No Night Mode?

Posted: Fri Jan 17, 2014 6:33 am
by ReEfnWrX
Now all of those patterns have been implemented into the DCPump classes which you are currently using. So if you want to continue using the DC pump mode you do not need to copy and paste that code.

If you want to see the code used for each of those in DC pump mode. Just launch the wizard and select a different wave pattern and select your speed and duration setting if applicable then generate the code and look for the line similar to this but with the different mode.

Code: Select all

ReefAngel.DCPump.SetMode( LongPulse,100,60 );
One of the benefits to not using the DCPump class and using the custom code from that thread is you have more control over the wave pattern.. example you can set minimum speed.

Now all of those custom codes have been implemented into the libraries so you do not need to copy and paste those. You just need to call them.

Code: Select all

ReefAngel.PWM.SetDaylight( ReefCrestMode(70,20,true) );
To do this you would place this code into the area inbetween

Code: Select all

////// place your custom code below here
and remove your DCPump.Setmode code.


Also, the values after the mode ( ReefCrestMode(70,20,true)

On that page Where you see it says ReefCrest then WaveSpeed Wave Offset Pulsync on different lines those are the values you need to define in ( ) after ReefCrestMode

so Nutrient Transport would be

Code: Select all

Reefangel.PWM.SetDaylight( NutrientTransportMode(30,80,20,true) );

Re: RA Wizard - No Night Mode?

Posted: Fri Jan 17, 2014 6:50 am
by lnevo
ReEfnWrX wrote:

Code: Select all

ReefAngel.DCPump.SetMode( LongPulse,100,60 );
That code is not correct. You could do

Code: Select all

ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.SetMode( Constant );
ReefAngel.DCPump.Speed=LongPulseMode(100,60,false );
The problem with that is you wont get Sync/AntiSync behavior.

You could set the mode to Custom and then set each channel manually as well.

Re: RA Wizard - No Night Mode?

Posted: Fri Jan 17, 2014 9:41 am
by ReEfnWrX
The code I listed is based off of DC pump codes the wizard has generated, and I did not mention the other DCPump lines because eh was already using the DCPump class and they should be there.

You seem to be using a different method than what the wizard generates

Re: RA Wizard - No Night Mode?

Posted: Fri Jan 17, 2014 9:57 am
by lnevo
Maybe you meant Speed instead of Mode...speed can be set as a value from the LongPulse function but Mode would just get screwed up and keep changing modes and most would be invalid...check your output from the wizard and what you posted again...

Re: RA Wizard - No Night Mode?

Posted: Fri Jan 17, 2014 9:58 am
by lnevo
I'm sorry just reread the code...using the SetMode function...my bad. You were correct sir.

Re: RA Wizard - No Night Mode?

Posted: Sat Jan 18, 2014 5:37 am
by AnesthDoc
Appreciate the replies, I will be tweaking the modes today.