Cloud/moon and strom for newbie
Posted: Wed Apr 25, 2012 11:05 am
Hello to all I am a French who has recently acquired a reef angel and I have a hard program it was and I would like some help.
I would like to integrate the effects of clouds and storms and a moon phase in my angel reef program knowing that an extension pwm drivers 3 and 6 for blue LEDs and 3 for white.
Here are my current program:
#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 <ReefAngel.h>
////// Place global variable code below here
////// Place global variable code above here
void setup()
{
// This must be the first line
ReefAngel.Init(); //Initialize controller
ReefAngel.SetTemperatureUnit(1); // set to Celsius Temperature
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port4Bit | Port5Bit | Port6Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port3Bit | Port4Bit | Port5Bit | Port6Bit;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports that are always on
ReefAngel.Relay.On(Port3);
ReefAngel.Relay.On(Port4);
ReefAngel.Relay.On(Port8);
////// Place additional initialization code below here
ReefAngel.TempProbe=T1_PROBE;
////// Place additional initialization code above here
}
void loop()
{
// Specific functions that use Internal Memory values
ReefAngel.StandardHeater(Port1);
ReefAngel.StandardFan(Port2);
ReefAngel.Wavemaker1(Port5);
ReefAngel.Wavemaker2(Port6);
ReefAngel.StandardLights(Port7);
// PWMSlope based on Internal Memory values for Standard Lights
ReefAngel.PWM.ActinicPWMSlope();
ReefAngel.PWM.DaylightPWMSlope();
////// Place your custom code below here
ReefAngel.PWM.SetChannel(0,PWMSlope(10,0,20,15,15,100,60,15));
ReefAngel.PWM.SetChannel(1,PWMSlope(10,05,20,20,15,100,60,15));
ReefAngel.PWM.SetChannel(2,PWMSlope(10,10,20,25,15,100,60,15));
ReefAngel.PWM.SetChannel(3,PWMSlope(10,10,20,00,15,100,60,15));
ReefAngel.PWM.SetChannel(4,PWMSlope(10,15,20,10,15,100,60,15));
ReefAngel.PWM.SetChannel(5,PWMSlope(10,20,20,15,15,100,60,15));
////// Place your custom code above here
// This should always be the last line
ReefAngel.ShowInterface();
}
Thank you in advance for your help.
The rest of the program is right for me
ps sorry translated with google.
jerome.
I would like to integrate the effects of clouds and storms and a moon phase in my angel reef program knowing that an extension pwm drivers 3 and 6 for blue LEDs and 3 for white.
Here are my current program:
#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 <ReefAngel.h>
////// Place global variable code below here
////// Place global variable code above here
void setup()
{
// This must be the first line
ReefAngel.Init(); //Initialize controller
ReefAngel.SetTemperatureUnit(1); // set to Celsius Temperature
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port4Bit | Port5Bit | Port6Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port3Bit | Port4Bit | Port5Bit | Port6Bit;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports that are always on
ReefAngel.Relay.On(Port3);
ReefAngel.Relay.On(Port4);
ReefAngel.Relay.On(Port8);
////// Place additional initialization code below here
ReefAngel.TempProbe=T1_PROBE;
////// Place additional initialization code above here
}
void loop()
{
// Specific functions that use Internal Memory values
ReefAngel.StandardHeater(Port1);
ReefAngel.StandardFan(Port2);
ReefAngel.Wavemaker1(Port5);
ReefAngel.Wavemaker2(Port6);
ReefAngel.StandardLights(Port7);
// PWMSlope based on Internal Memory values for Standard Lights
ReefAngel.PWM.ActinicPWMSlope();
ReefAngel.PWM.DaylightPWMSlope();
////// Place your custom code below here
ReefAngel.PWM.SetChannel(0,PWMSlope(10,0,20,15,15,100,60,15));
ReefAngel.PWM.SetChannel(1,PWMSlope(10,05,20,20,15,100,60,15));
ReefAngel.PWM.SetChannel(2,PWMSlope(10,10,20,25,15,100,60,15));
ReefAngel.PWM.SetChannel(3,PWMSlope(10,10,20,00,15,100,60,15));
ReefAngel.PWM.SetChannel(4,PWMSlope(10,15,20,10,15,100,60,15));
ReefAngel.PWM.SetChannel(5,PWMSlope(10,20,20,15,15,100,60,15));
////// Place your custom code above here
// This should always be the last line
ReefAngel.ShowInterface();
}
Thank you in advance for your help.
The rest of the program is right for me
ps sorry translated with google.
jerome.