I copied Saochen's code and made some modifications, could yall look over and let me know if it looks like it will work and accomplish what is listed out in the comments?
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrest, Gyre, Lagoon, Constant, TidalSwell, LongPulse, Else, };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) { //does it go to this after a feeding mode??
// Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
} else if (now()%SECS_PER_DAY<75600 || now()%SECS_PER_DAY>=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=35;
} else if (now()%SECS_PER_DAY<32400 || now()%SECS_PER_DAY>=36000) { // 9am / 10am
// Transition to random from Night (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (now()%SECS_PER_DAY<68400 || now()%SECS_PER_DAY>=75600) { // 7pm / 9pm
// Transition From random to night mode (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=InternalMemory.DCPumpSpeed_read(); // Set speed from portal
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrestMode, SineMode, TidalSwellMode, LongPulseMode, ElseMode, };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) { //does it go to this after a feeding mode??
// Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
} else if (now()%SECS_PER_DAY>=75600 || now()%SECS_PER_DAY<=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=35;
} else if (now()%SECS_PER_DAY>=32400 || now()%SECS_PER_DAY<=36000) { // 9am / 10am
// Transition to random from Night (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (now()%SECS_PER_DAY>=68400 || now()%SECS_PER_DAY<=75600) { // 7pm / 9pm
// Transition From random to night mode (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=100;
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
#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>
////// 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.AddStandardMenu(); // Add Standard Menu
ReefAngel.Use2014Screen(); // Let's use 2014 Screen
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port2Bit | Port8Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port2Bit | Port8Bit;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = Port4Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 830 );
// Feeeding and Water Change mode speed
ReefAngel.DCPump.FeedingSpeed=0;
ReefAngel.DCPump.WaterChangeSpeed=0;
// Ports that are always on
ReefAngel.Relay.On( Port6 );
ReefAngel.Relay.On( Port7 );
////// Place additional initialization code below here
// Define labels for 2014 LCD screen
//box0
ReefAngel.CustomLabels[0]="T5HO";
ReefAngel.CustomLabels[1]="Skimmer";
ReefAngel.CustomLabels[2]="FugeLight";
ReefAngel.CustomLabels[3]="Heater";
ReefAngel.CustomLabels[4]="ScrubLight";
ReefAngel.CustomLabels[5]="Unused";
ReefAngel.CustomLabels[6]="Return";
ReefAngel.CustomLabels[7]="ATO_Pump";
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.MHLights( Port1,12,30,14,30,5 ); //t5ho
ReefAngel.MHLights( Port2,5,0,22,0,5 ); //skimmer
ReefAngel.StandardLights( Port3,18,0,10,0 ); //fugelight
ReefAngel.StandardHeater( Port4,780,788 ); //heater
ReefAngel.StandardLights( Port5,18,0,10,0 ); //scrubber light
ReefAngel.SingleATO( true,Port8,360,0 ); // ato
////// Place your custom code below here
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrestMode, SineMode, TidalSwellMode, LongPulseMode, ElseMode };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) { //does it go to this after a feeding mode??
// Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
} else if (now()%SECS_PER_DAY>=75600 || now()%SECS_PER_DAY<=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=35;
} else if (now()%SECS_PER_DAY>=32400 || now()%SECS_PER_DAY<=36000) { // 9am / 10am
// Transition to random from Night (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (now()%SECS_PER_DAY>=68400 || now()%SECS_PER_DAY<=75600) { // 7pm / 9pm
// Transition From random to night mode (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=100;
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
////// Place your custom code above here
// This should always be the last line
ReefAngel.ShowInterface();
}
Ok, added a couple things. Notices the pumps were running in sync, so added sync and anti sync in each profile and added duration for the modes that transition from and to night ( sine ) . seems to be working good so far. What unit of time is used for sine in the duration I set?
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrest, Sine, TidalSwell, LongPulse, Else, Sine, ReefCrest, Else };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) {
// after feed mode Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
} else if (now()%SECS_PER_DAY>=75600 || now()%SECS_PER_DAY<=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=Sine;
ReefAngel.DCPump.Speed=35;
ReefAngel.DCPump.Duration=600;
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
} else if (now()%SECS_PER_DAY>=32400 || now()%SECS_PER_DAY<=36000) { // 9am / 10am
// Transition to random from Night (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=Sine;
ReefAngel.DCPump.Speed=100;
ReefAngel.DCPump.Duration=400;
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
}else if (now()%SECS_PER_DAY>=68400 || now()%SECS_PER_DAY<=75600) { // 7pm / 9pm
// Transition From random to night mode (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=Sine;
ReefAngel.DCPump.Speed=100;
ReefAngel.DCPump.Duration=400;
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
}else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=100;
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
got ya. seems to be working. but has been coming up with reef crest everyday. should this work without connecting to it through the portal and set random everyday?
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrest, Sine, TidalSwell, LongPulse, Else, Sine, ReefCrest, Else };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) { //does it go to this after a feeding mode??
// Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
} else if (now()%SECS_PER_DAY>=75600 || now()%SECS_PER_DAY<=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=35;
} else if (now()%SECS_PER_DAY>=32400 || now()%SECS_PER_DAY<=36000) { // 9am / 10am
// Transition to random from Night (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (now()%SECS_PER_DAY>=68400 || now()%SECS_PER_DAY<=75600) { // 7pm / 9pm
// Transition From random to night mode (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=100;
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
in this code it goes to random, but im trying to figure out how you stated above to change change rate to every 6 hours
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrest, Sine, TidalSwell, LongPulse, Else, Sine, ReefCrest, Else };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) { //does it go to this after a feeding mode??
// Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
} else if (now()%SECS_PER_DAY>=75600 || now()%SECS_PER_DAY<=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=35;
} else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=100;
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { ReefCrest, Sine, TidalSwell, LongPulse, Else, Sine, ReefCrest, Else };
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<3600) { //does it go to this after a feeding mode??
// Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
} else if (now()%SECS_PER_DAY>=75600 || now()%SECS_PER_DAY<=32400) { // 9pm / 9am
// Night mode (go to 30%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=35;
} else if (now()%SECS_PER_DAY>=32400 || now()%SECS_PER_DAY<=36000) { // 9am / 10am
// Transition to random from Night (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (now()%SECS_PER_DAY>=68400 || now()%SECS_PER_DAY<=75600) { // 7pm / 9pm
// Transition From random to night mode (go to Tidal Swell 100%)
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=TidalSwell;
ReefAngel.DCPump.Speed=100;
}else if (InternalMemory.DCPumpMode_read()==11) {
// Custom Mode and nothing else going on
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=100;
} else {
ReefAngel.DCPump.UseMemory=true; // Will reset all values from memory
}
Well there's only a 1 in 4 chance of it and second, it's going to be the same all day. Did you add the randomseed function. You can take out the / seconds per day part and it should be more random. Also know that the portal only updates every 5 minutes
ok. I will keep an eye on it over the holidays and report back. heres the code im running. I change secs to hours. seems to be working right. Is this a reason for the time to be in seconds instead of hours?
// Add random mode if we set to Mode to Custom in portal
static int rmode;
static boolean changeMode=true;
// These are the modes we can cycle through. You can add more and even repeat...
byte modes[] = { TidalSwell, ReefCrest, TidalSwell, Lagoon, Else, ReefCrest, Else, Lagoon };
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
if (now()%SECS_PER_DAY==0 || changeMode==true) { // Change at midnight or if controller rebooted
rmode=random(100)%sizeof(modes); // Change the mode once per day to pick from our array
changeMode=false;
}
// Set timer when in feeding mode
static unsigned long feeding;
if (ReefAngel.DisplayedMenu==FEEDING_MODE) feeding=now();
if (now()-feeding<1800) {
// after feed mode Continue NTM for the 60 minutes
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=NutrientTransport;
}
else if (hour()>=7 && hour()<9){
//morning
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=300;
ReefAngel.DCPump.Mode=Sine;
ReefAngel.DCPump.Speed=100;
}
else if (hour()>=9 && hour()<19) {
//9am to 7pm
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=InternalMemory.DCPumpDuration_read();
ReefAngel.DCPump.Mode=modes[rmode]; // Put the mode to the random mode :)
ReefAngel.DCPump.Speed=95;
}
else if (hour()>=19 && hour()<21){
//7pm to 9pm
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=300;
ReefAngel.DCPump.Mode=Sine;
ReefAngel.DCPump.Speed=100;
}else { // 9pm / 9am
// Night mode
ReefAngel.DCPump.UseMemory=false;
ReefAngel.DCPump.Duration=500;
ReefAngel.DCPump.Mode=Sine;
ReefAngel.DCPump.Speed=40;
}
You realize you hve the schedule all setup at the end. From 7pm to 9am you are forcing sine mode. The only time you are using the random mode is between 9am and 7pm
yes sir. I think that's what I was trying to do. just not sure if I did it right
this is how im seeing it in my mind :
7am-9am - sine wave (ramping up to the random mode)
9am-7pm - RANDOM
7pm-9pm - sine wave (ramping down from the random mode)
rest of the night sine wave at 40%