Re: Wave patterns
Posted: Fri Jun 19, 2015 2:37 pm
No problem.
Community discussion about Reef Angel Controllers and reefing related subjects
https://forum.reefangel.com/
Ok, that makes sense and also what I see although I thought I saw higher than 60 on one side. I'll add a if statement to get them to swap who is anti then.cosmith71 wrote:That's not how ReefCrest works. ReefCrest slowly meanders between the midline (50 in your case) by +/- the offset (10 here). When the sync goes up, the antisync goes down. So they both should be on constantly, going between 40 and 60.
--Colin
Code: Select all
#include <ReefAngel_Features.h>
#include <Globals.h>
#include <RA_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <InternalEEPROM.h>
#include <RA_NokiaLCD.h>
#include <RA_ATO.h>
#include <RA_Joystick.h>
#include <LED.h>
#include <RA_TempSensor.h>
#include <Relay.h>
#include <RA_PWM.h>
#include <Timer.h>
#include <Memory.h>
#include <InternalEEPROM.h>
#include <RA_Colors.h>
#include <RA_CustomColors.h>
#include <Salinity.h>
#include <RF.h>
#include <IO.h>
#include <ORP.h>
#include <AI.h>
#include <PH.h>
#include <WaterLevel.h>
#include <Humidity.h>
#include <DCPump.h>
#include <PAR.h>
#include <ReefAngel.h>
#include <Tide.h> // testing for tide control
////// Place global variable code below here
Tide tide; // testing for tide control
////// Place global variable code above here
void setup()
{
// This must be the first line
ReefAngel.Init(); //Initialize controller
ReefAngel.Use2014Screen(); // Let's use 2014 Screen
ReefAngel.AddPHExpansion(); // pH Expansion Module
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port1Bit | Port5Bit | Port6Bit | Port7Bit | Port8Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port5Bit | Port6Bit | Port7Bit | Port8Bit;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = Port2Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 869 );
// Feeeding and Water Change mode speed
ReefAngel.DCPump.FeedingSpeed=0;
ReefAngel.DCPump.WaterChangeSpeed=0;
// Ports that are always on
ReefAngel.Relay.On( Port1 ); // skimmer
// ReefAngel.Relay.On( Port4 ); // LED Fans
ReefAngel.Relay.On( Port5 ); // RW 4 left side facing tank
ReefAngel.Relay.On( Port6 ); // RW 4 right side facing tank
////// Place additional initialization code below here
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.StandardLights( Port2,9,0,21,0 ); // power to LED power supply
ReefAngel.StandardLights( Port4,9,0,21,0 ); // LED fans
// ReefAngel.WavemakerRandom( Port5,5,90 ); // Not sure what these are for now
// ReefAngel.WavemakerRandom( Port6,5,90 ); // Not sure what these are for now
// ReefAngel.StandardLights( Port7,9,0,21,0 );
// ReefAngel.StandardLights( Port8,9,0,21,0 );
// Channel 0 (1000mA max) - 5 Neutral White
// Channel 1 (1000mA max) - 6 Royal Blue + 5 Blue
// Channel 2 (700mA max) - 12 Lime
// Channel 3 (700mA max) - 5 Violet UV + 4 Deep Red (660nm)
ReefAngel.PWM.SetChannel( 0, PWMParabola(9,0,21,0,0,65,0) );
ReefAngel.PWM.SetChannel( 1, PWMParabola(9,0,21,0,0,75,0) );
ReefAngel.PWM.SetChannel( 2, PWMParabola(9,0,21,0,0,65,0) );
ReefAngel.PWM.SetChannel( 3, PWMParabola(9,0,21,0,0,65,0) );
ReefAngel.DCPump.UseMemory = false;
// ReefAngel.DCPump.SetMode( ReefCrest,55,10 );
// ReefAngel.DCPump.DaylightChannel = Sync;
// ReefAngel.DCPump.ActinicChannel = AntiSync;
// Testing tidal function
if (tide.isIncoming()) {
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
}
else {
ReefAngel.DCPump.DaylightChannel = AntiSync;
ReefAngel.DCPump.ActinicChannel = Sync;
}
// ReefAngel.DCPump.ExpansionChannel[0] = None;
// ReefAngel.DCPump.ExpansionChannel[1] = None;
// ReefAngel.DCPump.ExpansionChannel[2] = None;
// ReefAngel.DCPump.ExpansionChannel[3] = None;
// ReefAngel.DCPump.ExpansionChannel[4] = None;
// ReefAngel.DCPump.ExpansionChannel[5] = None;
////// Place your custom code below here
if (hour()>=21 || hour()<9)
{
// Sleep mode - slow things down
ReefAngel.DCPump.SetMode( ReefCrest,25,10 );
}
else
{
// Normal power
ReefAngel.DCPump.SetMode( ReefCrest,50,10 );
}
////// Place your custom code above here
// This should always be the last line
ReefAngel.Portal( "saf1" );
ReefAngel.DDNS( "saf1-dns.myreefangel.com" ); // Your DDNS is saf1-saf1-dns.myreefangel.com.myreefangel.com
ReefAngel.ShowInterface();
}
Cool, thanks for the information because that is what I'm actually looking for. I know I am only going to get "so" much out of the R4's in a 40 gallon breeder but it is more about learning how this works, the corals, and overall look. I like what they are doing with just this basic routine and imagine the rose bubble tips will love one I get some variation in there.lnevo wrote:Thats perfect! Now if you want to use the tide mode more you can set the parameters for the tide speed to fluctuate through the day and the variation would be based on the MoonPhase() so where you are calling SetMode and giving the ReefCrest speed you could get the speed from the tide class. Also the tide class kind of has a built in night mode at least how I have it set
Code: Select all
#include <ReefAngel_Features.h>
#include <Globals.h>
#include <RA_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <InternalEEPROM.h>
#include <RA_NokiaLCD.h>
#include <RA_ATO.h>
#include <RA_Joystick.h>
#include <LED.h>
#include <RA_TempSensor.h>
#include <Relay.h>
#include <RA_PWM.h>
#include <Timer.h>
#include <Memory.h>
#include <InternalEEPROM.h>
#include <RA_Colors.h>
#include <RA_CustomColors.h>
#include <Salinity.h>
#include <RF.h>
#include <IO.h>
#include <ORP.h>
#include <AI.h>
#include <PH.h>
#include <WaterLevel.h>
#include <Humidity.h>
#include <DCPump.h>
#include <PAR.h>
#include <ReefAngel.h>
#include <Tide.h> // testing for tide control
////// Place global variable code below here
Tide tide; // testing for tide control
////// Place global variable code above here
void setup()
{
// This must be the first line
ReefAngel.Init(); //Initialize controller
ReefAngel.Use2014Screen(); // Let's use 2014 Screen
ReefAngel.AddPHExpansion(); // pH Expansion Module
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port1Bit | Port5Bit | Port6Bit | Port7Bit | Port8Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port5Bit | Port6Bit | Port7Bit | Port8Bit;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = Port2Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 869 );
// Feeeding and Water Change mode speed
ReefAngel.DCPump.FeedingSpeed=0;
ReefAngel.DCPump.WaterChangeSpeed=0;
// Ports that are always on
ReefAngel.Relay.On( Port1 ); // skimmer
// ReefAngel.Relay.On( Port4 ); // LED Fans
ReefAngel.Relay.On( Port5 ); // RW 4 left side facing tank
ReefAngel.Relay.On( Port6 ); // RW 4 right side facing tank
////// Place additional initialization code below here
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.StandardLights( Port2,9,0,21,0 ); // power to LED power supply
ReefAngel.StandardLights( Port4,9,0,21,0 ); // LED fans
// ReefAngel.WavemakerRandom( Port5,5,90 ); // Not sure what these are for now
// ReefAngel.WavemakerRandom( Port6,5,90 ); // Not sure what these are for now
// ReefAngel.StandardLights( Port7,9,0,21,0 );
// ReefAngel.StandardLights( Port8,9,0,21,0 );
// Channel 0 (1000mA max) - 5 Neutral White
// Channel 1 (1000mA max) - 6 Royal Blue + 5 Blue
// Channel 2 (700mA max) - 12 Lime
// Channel 3 (700mA max) - 5 Violet UV + 4 Deep Red (660nm)
ReefAngel.PWM.SetChannel( 0, PWMParabola(9,0,21,0,0,65,0) );
ReefAngel.PWM.SetChannel( 1, PWMParabola(9,0,21,0,0,90,0) );
ReefAngel.PWM.SetChannel( 2, PWMParabola(9,0,21,0,0,55,0) );
ReefAngel.PWM.SetChannel( 3, PWMParabola(9,0,21,0,0,65,0) );
ReefAngel.DCPump.UseMemory = false;
// ReefAngel.DCPump.SetMode( ReefCrest,55,10 );
// ReefAngel.DCPump.DaylightChannel = Sync;
// ReefAngel.DCPump.ActinicChannel = AntiSync;
// Testing tidal function
if (tide.isIncoming()) {
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
}
else {
ReefAngel.DCPump.DaylightChannel = AntiSync;
ReefAngel.DCPump.ActinicChannel = Sync;
}
// ReefAngel.DCPump.ExpansionChannel[0] = None;
// ReefAngel.DCPump.ExpansionChannel[1] = None;
// ReefAngel.DCPump.ExpansionChannel[2] = None;
// ReefAngel.DCPump.ExpansionChannel[3] = None;
// ReefAngel.DCPump.ExpansionChannel[4] = None;
// ReefAngel.DCPump.ExpansionChannel[5] = None;
////// Place your custom code below here
if (hour()>=21 || hour()<9)
{
// Sleep mode - slow things down
ReefAngel.DCPump.SetMode( ReefCrest,25,10 );
}
else
{
// Full power to run during the day with lights on
// Start at 9 AM run through 9 PM
ReefAngel.DCPump.SetMode( TidalSwell,80,20 );
}
////// Place your custom code above here
// This should always be the last line
ReefAngel.Portal( "saf1" );
ReefAngel.DDNS( "saf1-dns.myreefangel.com" ); // Your DDNS is saf1-saf1-dns.myreefangel.com.myreefangel.com
ReefAngel.ShowInterface();
}