Code: Select all
static unsigned long feeding = 0;
if ((now()%SECS_PER_DAY==64800)) //if it is 6 pm
{
ReefAngel.FeedingModeStart(); //START FEEDING MODE
}
if (ReefAngel.DisplayedMenu==FEEDING_MODE)
{
if ( feeding == 0 ) {
feeding = now(); //set the time of the start of feeding to variable feeding
}
if ((now()-feeding>=60) && (now()-feeding<=61)) //if between 60 and 61 seconds has past
{
ReefAngel.Relay.On(Feeder); //TURN FEEDER RELAY ON
}
else
{
ReefAngel.Relay.Off(Feeder); //TURN FEEDER RELAY OFF
}
} else {
if ( feeding > 0 ) {
feeding = 0;
}
}
Code: Select all
// Define Relay Ports by Name
#define Actinic_Lights 1
#define Day_Lights 2
#define Unused 3
#define Pumps 4
#define Sump_Fan 5
#define DeNit_Doser 6
#define DeNit_Pump 7
#define Unused 8
#define ATO_Pump Box1_Port1
#define Moon_Lights Box1_Port2
#define Feeder Box1_Port3
#define Unused Box1_Port4
#define Unused Box1_Port5
#define Unused Box1_Port6
#define Unused Box1_Port7
#define Dummy Box1_Port8
Does this look good?
It looks like this will drop the power on the Jebao pumps like turning on Feeding Mode from the head unit or the Andriod App. Is that correct?
Will it work with the NTM that is set up to run after a feeding?
Will this work if I wanted to do a manual feeding from the RA head unit or the Andriod App?
If not I guess I could always do a manual trigger on the Feeder Port.
Am I asking to many questions, just tell me to shut up .