pwm slope
Posted: Tue Feb 21, 2012 9:33 pm
I wanna setup times and % for leds I do not have the pwm module so i was womdering
so can anyone tell me if this code would work?
Sent from Yahoo! Mail on
// Autogenerated file by RAGen (v1.2.0.152), (02/19/2012 20:15)
// RA_021912_2015.ino
//
// This version designed for v0.9.0 or later
/* The following features are enabled for this File:
#define VersionMenu
#define DisplayLEDPWM
#define wifi
#define WDT
#define SIMPLE_MENU
*/
#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>
void setup()
{
ReefAngel.Init(); //Initialize controller
// Ports that are always on
ReefAngel.Relay.On(Port2);
ReefAngel.Relay.On(Port8);
}
void loop()
{
// Specific functions
ReefAngel.SingleATOLow(Port1);
ReefAngel.DosingPump2(Port3);
ReefAngel.DosingPump1(Port4);
ReefAngel.MHLights(Port5);
ReefAngel.MHLights(Port6);
ReefAngel.StandardHeater(Port7);
ReefAngel.Portal("Govertical19");
//Setup the sunrise slopes for actinic and daylight LEDs ReefAngel.PWM.SetActinic(PWMSlope(11,00,13,30,15,85)); //PWM slopes starts a 15% at 11:00 a.m and ends 85% at 1:00pm ReefAngel.PWM.SetDaylight(PWMSlope(12,00,13,30,15,75)); //PWM slopes starts a 15% at 1:30pm and ends 75% at 1:30pm
//Setup the sunset slopes for actinic and daylight LEDs ReefAngel.PWM.SetDaylight(PWMSlope(20,30,22,00,75,0)); //PWM slopes starts a 75% at 8:30pm and ends 0% at 10:00pm int moonPhase = (int)MoonlightPWM;
ReefAngel.PWM.SetActinic(PWMSlope(20,30,23,00,85,15)); //PWM slopes starts a 85% at 8:30pm and ends 15% at 11:00pm
ReefAngel.ShowInterface();
}
so can anyone tell me if this code would work?
Sent from Yahoo! Mail on
// Autogenerated file by RAGen (v1.2.0.152), (02/19/2012 20:15)
// RA_021912_2015.ino
//
// This version designed for v0.9.0 or later
/* The following features are enabled for this File:
#define VersionMenu
#define DisplayLEDPWM
#define wifi
#define WDT
#define SIMPLE_MENU
*/
#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>
void setup()
{
ReefAngel.Init(); //Initialize controller
// Ports that are always on
ReefAngel.Relay.On(Port2);
ReefAngel.Relay.On(Port8);
}
void loop()
{
// Specific functions
ReefAngel.SingleATOLow(Port1);
ReefAngel.DosingPump2(Port3);
ReefAngel.DosingPump1(Port4);
ReefAngel.MHLights(Port5);
ReefAngel.MHLights(Port6);
ReefAngel.StandardHeater(Port7);
ReefAngel.Portal("Govertical19");
//Setup the sunrise slopes for actinic and daylight LEDs ReefAngel.PWM.SetActinic(PWMSlope(11,00,13,30,15,85)); //PWM slopes starts a 15% at 11:00 a.m and ends 85% at 1:00pm ReefAngel.PWM.SetDaylight(PWMSlope(12,00,13,30,15,75)); //PWM slopes starts a 15% at 1:30pm and ends 75% at 1:30pm
//Setup the sunset slopes for actinic and daylight LEDs ReefAngel.PWM.SetDaylight(PWMSlope(20,30,22,00,75,0)); //PWM slopes starts a 75% at 8:30pm and ends 0% at 10:00pm int moonPhase = (int)MoonlightPWM;
ReefAngel.PWM.SetActinic(PWMSlope(20,30,23,00,85,15)); //PWM slopes starts a 85% at 8:30pm and ends 15% at 11:00pm
ReefAngel.ShowInterface();
}