Jebao Custom programming help
Posted: Tue Feb 28, 2017 11:54 am
I need help programming my Jebaos. I have 3 and currently I have them on reefcrest mode.
I need help adding the following:
1. Turning off the Jeabos on Dimming Channel 0 and Channel 2 during feed mode
2. Jeabo on Dimming channel 1 to go into nutrient transport mode
3. I want each Jeabo to randomly select a different mode randomly every hour from 3pm to Midnight with random times where they aren't running for about 10 minutes.
4. The Jebaos from Midnight - 3pm to go to 10% and randomly turn off for 5 minutes
Below is my current code. I have it in the memory so I can change things from my phone. I only have a few items that I changed because I wanted my moonlights to only be on until 3am. Not opposite of the of the daylights. Also I wanted my fans to turn on a bit before my lights and after the moonlights.
Thank you
#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.Use2014Screen(); // Let's use 2014 Screen
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = 0;
ReefAngel.FeedingModePortsE[0] = Port2Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port6Bit;
ReefAngel.WaterChangePortsE[0] = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = Port1Bit | Port2Bit | Port4Bit;
ReefAngel.LightsOnPortsE[0] = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = Port1Bit | Port2Bit | Port3Bit | Port4Bit | Port6Bit;
ReefAngel.OverheatShutoffPortsE[0] = Port3Bit | Port4Bit | Port5Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// 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( Box1_Port1 );
ReefAngel.Relay.On( Box1_Port2 );
ReefAngel.Relay.On( Box1_Port8 );
////// Place additional initialization code below here
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.ActinicLights( Port1 );
ReefAngel.DayLights( Port2 );
ReefAngel.StandardLights( Port3,23,55,3,0 );
ReefAngel.StandardHeater( Port4 );
ReefAngel.StandardLights( Port7,14,55,3,0 );
ReefAngel.StandardHeater( Box1_Port3 );
ReefAngel.StandardHeater( Box1_Port5 );
ReefAngel.StandardATO( Box1_Port6 );
ReefAngel.MoonLights( Box1_Port7 );
ReefAngel.PWM.DaylightPWMParabola();
ReefAngel.PWM.ActinicPWMParabola();
ReefAngel.DCPump.UseMemory = true;
ReefAngel.DCPump.DaylightChannel = None;
ReefAngel.DCPump.ActinicChannel = None;
ReefAngel.DCPump.ExpansionChannel[0] = Sync;
ReefAngel.DCPump.ExpansionChannel[1] = Sync;
ReefAngel.DCPump.ExpansionChannel[2] = AntiSync;
ReefAngel.DCPump.ExpansionChannel[3] = None;
ReefAngel.DCPump.ExpansionChannel[4] = None;
ReefAngel.DCPump.ExpansionChannel[5] = None;
////// Place your custom code below here
////// Place your custom code above here
// This should always be the last line
ReefAngel.Portal( "XXX" );
ReefAngel.DDNS( "XXX" ); // Your DDNS is XXX-XXX.myreefangel.com
ReefAngel.ShowInterface();
}
I need help adding the following:
1. Turning off the Jeabos on Dimming Channel 0 and Channel 2 during feed mode
2. Jeabo on Dimming channel 1 to go into nutrient transport mode
3. I want each Jeabo to randomly select a different mode randomly every hour from 3pm to Midnight with random times where they aren't running for about 10 minutes.
4. The Jebaos from Midnight - 3pm to go to 10% and randomly turn off for 5 minutes
Below is my current code. I have it in the memory so I can change things from my phone. I only have a few items that I changed because I wanted my moonlights to only be on until 3am. Not opposite of the of the daylights. Also I wanted my fans to turn on a bit before my lights and after the moonlights.
Thank you
#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.Use2014Screen(); // Let's use 2014 Screen
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = 0;
ReefAngel.FeedingModePortsE[0] = Port2Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port6Bit;
ReefAngel.WaterChangePortsE[0] = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = Port1Bit | Port2Bit | Port4Bit;
ReefAngel.LightsOnPortsE[0] = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = Port1Bit | Port2Bit | Port3Bit | Port4Bit | Port6Bit;
ReefAngel.OverheatShutoffPortsE[0] = Port3Bit | Port4Bit | Port5Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// 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( Box1_Port1 );
ReefAngel.Relay.On( Box1_Port2 );
ReefAngel.Relay.On( Box1_Port8 );
////// Place additional initialization code below here
////// Place additional initialization code above here
}
void loop()
{
ReefAngel.ActinicLights( Port1 );
ReefAngel.DayLights( Port2 );
ReefAngel.StandardLights( Port3,23,55,3,0 );
ReefAngel.StandardHeater( Port4 );
ReefAngel.StandardLights( Port7,14,55,3,0 );
ReefAngel.StandardHeater( Box1_Port3 );
ReefAngel.StandardHeater( Box1_Port5 );
ReefAngel.StandardATO( Box1_Port6 );
ReefAngel.MoonLights( Box1_Port7 );
ReefAngel.PWM.DaylightPWMParabola();
ReefAngel.PWM.ActinicPWMParabola();
ReefAngel.DCPump.UseMemory = true;
ReefAngel.DCPump.DaylightChannel = None;
ReefAngel.DCPump.ActinicChannel = None;
ReefAngel.DCPump.ExpansionChannel[0] = Sync;
ReefAngel.DCPump.ExpansionChannel[1] = Sync;
ReefAngel.DCPump.ExpansionChannel[2] = AntiSync;
ReefAngel.DCPump.ExpansionChannel[3] = None;
ReefAngel.DCPump.ExpansionChannel[4] = None;
ReefAngel.DCPump.ExpansionChannel[5] = None;
////// Place your custom code below here
////// Place your custom code above here
// This should always be the last line
ReefAngel.Portal( "XXX" );
ReefAngel.DDNS( "XXX" ); // Your DDNS is XXX-XXX.myreefangel.com
ReefAngel.ShowInterface();
}