I have 2 X Jebao RW-8's connected by 2 speed-cables to Daylight and Actinic channel dimming ports.
This is what I was attempting to do:
1. Set custom port labels
2. Set a day wave pattern to reef crest min @30% and max @60%
one set to sync and the other to anti-sync on @14:00 and off @20:30
Set night to lagoon @30%
one set to sync and the other to anti-sync on @20:31 and off @13:59
3. Setup app control for wave-makers
I would like to change settings "intensity, mode, timer" for my wave-makers from the app or at least through the head-unit.
I will post my code hopefully someone can spot what I did wrong...
Code: Select all
#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 = Port1Bit | Port2Bit | Port5Bit | Port7Bit | Port8Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = Port1Bit | Port2Bit | Port5Bit | Port6Bit | Port7Bit | Port8Bit;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = Port3Bit | Port7Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 820 );
// Feeeding and Water Change mode speed
ReefAngel.DCPump.FeedingSpeed=0;
ReefAngel.DCPump.WaterChangeSpeed=0;
// Ports that are always on
ReefAngel.Relay.On( Port1 );
ReefAngel.Relay.On( Port2 );
ReefAngel.Relay.On( Port3 );
ReefAngel.Relay.On( Port4 );
ReefAngel.Relay.On( Port5 );
ReefAngel.Relay.On( Port6 );
ReefAngel.Relay.On( Port7 );
ReefAngel.Relay.On( Port8 );
////// Place additional initialization code below here
//Define labels for 2014 LCD screen
#define ATO 8
#define Reactor 7
#define WM2 6
#define WM1 5
#define UVL 4
#define Heater 3
#define Skimmer 2
#define Return 1
////// Place additional initialization code above here
}
void loop()
{
/*
ReefAngel.StandardHeater( Port3,751,791 );
ReefAngel.WavemakerRandom( Port5,30,60 );
ReefAngel.WavemakerRandom( Port6,30,60 );
ReefAngel.StandardATO( Port8,60 );
ReefAngel.PWM.SetDaylight( PWMSlope(14,0,20,30,30,60,15,30) );
ReefAngel.PWM.SetActinic( PWMSlope(14,0,21,0,30,60,15,30) );
ReefAngel.DCPump.UseMemory = true;
ReefAngel.DCPump.SetMode( ReefCrest,60,10 );
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
ReefAngel.PWM.SetDaylight( PWMSlope(20,31,13,59,30) );
ReefAngel.PWM.SetActinic( PWMSlope(20,31,13,59,30) );
ReefAngel.DCPump.UseMemory = true;
ReefAngel.DCPump.SetMode( Lagoon,30,10 );
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = AntiSync;
*/
////// Place your custom code below here
////// Place your custom code above here
// This should always be the last line
ReefAngel.Portal( "raythesaint" );
ReefAngel.ShowInterface();
}