good evening since Arduino takes a shorter code ho.problema to alternate the pumps every 6 hours, using the wizard mi.da or random or constant in seconds, but I have to do 6 hours and a stop and then the next 6 hours and a stop and so on
Inviato dal mio GT-I9300 utilizzando Tapatalk
Problem wavemaker
Re: Problem wavemaker
Up
Inviato dal mio GT-I9300 utilizzando Tapatalk
Inviato dal mio GT-I9300 utilizzando Tapatalk
Re: Problem wavemaker
Help me
Inviato dal mio GT-I9300 utilizzando Tapatalk
Inviato dal mio GT-I9300 utilizzando Tapatalk
Re: Problem wavemaker
Help me please
Inviato dal mio GT-I9300 utilizzando Tapatalk
Inviato dal mio GT-I9300 utilizzando Tapatalk
Re: Problem wavemaker
How long does it need to stop for. You want 6hrs on 6hrs off
Re: Problem wavemaker
Thanks for taking my call I do not know how to get them to say to the reef angel do go a pump 6 hours and then stop her and go do the other 6 hours and stop her and then resumes
Re: Problem wavemaker
ReefAngel.Relay.Set(Port5, now()%(12*SECS_PER_HOUR)<(6*SECS_PER_HOUR) );
ReefAngel.Relay.Set(Port6, now()%(12*SECS_PER_HOUR)>(6*SECS_PER_HOUR) );
now % (12 * SECS_PER_HOUR) means to divide the time by 12 hours and look at the remainder.. If it's less than 6 hours then one port will be on (Port 5). If it's greater than 6 hours the other port (Port 6)will be on.
ReefAngel.Relay.Set(Port6, now()%(12*SECS_PER_HOUR)>(6*SECS_PER_HOUR) );
now % (12 * SECS_PER_HOUR) means to divide the time by 12 hours and look at the remainder.. If it's less than 6 hours then one port will be on (Port 5). If it's greater than 6 hours the other port (Port 6)will be on.
Re: Problem wavemaker
#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 <ReefAngel.h>
////// Place global variable code below here
////// Place global variable code above here
void setup()
{
// This must be the first line
ReefAngel.AddDateTimeMenu();
ReefAngel.Init(); //Initialize controller
ReefAngel.SetTemperatureUnit( Celsius ); // set to Celsius Temperature
ReefAngel.AddStandardMenu(); // Add Standard Menu
ReefAngel.Use2014Screen(); // Let's use 2014 Screen
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port5Bit | Port6Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port5Bit | Port6Bit | Port7Bit;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = 0;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 273 );
// Ports that are always on
ReefAngel.Relay.On( Port5 );
ReefAngel.Relay.On( Port6 );
ReefAngel.Relay.On( Port8 );
////// Place additional initialization code below here
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.SingleATO( true,Port1,60,0 );
ReefAngel.StandardLights( Port2,8,0,17,0 );
ReefAngel.StandardHeater( Port3,251,261 );
ReefAngel.StandardFan( Port4,265,271 );
ReefAngel.Relay.Set(Port5, now()%(12*SECS_PER_HOUR)<(6*SECS_PER_HOUR) );
ReefAngel.Relay.Set(Port6, now()%(12*SECS_PER_HOUR)>(6*SECS_PER_HOUR) );
ReefAngel.Relay.DelayedOn( Port7,5 );
ReefAngel.PWM.SetDaylight( PWMSlope(8,0,17,0,5,15,60,5) );
ReefAngel.PWM.SetActinic( PWMSlope(8,0,17,0,5,70,60,5) );
////// Place your custom code below here
////// Place your custom code above here
// This should always be the last line
ReefAngel.ShowInterface();
}
not fuction error uploading
#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 <ReefAngel.h>
////// Place global variable code below here
////// Place global variable code above here
void setup()
{
// This must be the first line
ReefAngel.AddDateTimeMenu();
ReefAngel.Init(); //Initialize controller
ReefAngel.SetTemperatureUnit( Celsius ); // set to Celsius Temperature
ReefAngel.AddStandardMenu(); // Add Standard Menu
ReefAngel.Use2014Screen(); // Let's use 2014 Screen
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port5Bit | Port6Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port5Bit | Port6Bit | Port7Bit;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = 0;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 273 );
// Ports that are always on
ReefAngel.Relay.On( Port5 );
ReefAngel.Relay.On( Port6 );
ReefAngel.Relay.On( Port8 );
////// Place additional initialization code below here
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.SingleATO( true,Port1,60,0 );
ReefAngel.StandardLights( Port2,8,0,17,0 );
ReefAngel.StandardHeater( Port3,251,261 );
ReefAngel.StandardFan( Port4,265,271 );
ReefAngel.Relay.Set(Port5, now()%(12*SECS_PER_HOUR)<(6*SECS_PER_HOUR) );
ReefAngel.Relay.Set(Port6, now()%(12*SECS_PER_HOUR)>(6*SECS_PER_HOUR) );
ReefAngel.Relay.DelayedOn( Port7,5 );
ReefAngel.PWM.SetDaylight( PWMSlope(8,0,17,0,5,15,60,5) );
ReefAngel.PWM.SetActinic( PWMSlope(8,0,17,0,5,70,60,5) );
////// Place your custom code below here
////// Place your custom code above here
// This should always be the last line
ReefAngel.ShowInterface();
}
not fuction error uploading