Page 1 of 1

Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 10:31 am
by cgonser
Here is what I am trying to achieve and dont seem to be able to get it right....
First I want to keep my tank between 78-81 degrees, when I tried to set that up, my heater wont turn on at all.
Second, I want my daylights (my whites and blues are on same channel) to come on at 7am and off at 10pm, and I want my refugium to be opposite. Any help would be great!

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 = 0;
    // Ports toggled in Water Change Mode
    ReefAngel.WaterChangePorts = 0;
    // 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;

    // Feeeding and Water Change mode speed
    ReefAngel.DCPump.FeedingSpeed=0;
    ReefAngel.DCPump.WaterChangeSpeed=0;


    // Ports that are always on
    ReefAngel.Relay.On( Port4 );
    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.SingleATOLow( Port1 );
    ReefAngel.MoonLights( Port2 );
    ReefAngel.StandardHeater( Port3 );
    ReefAngel.DayLights( 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] = AntiSync;
    ReefAngel.DCPump.ExpansionChannel[2] = None;
    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( "cgonser" );
    ReefAngel.ShowInterface();
}


Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 10:56 am
by rimai
I would recommend using the wizard and choosing hard coded settings.

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 11:20 am
by cgonser
That was with the wizard.

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 12:09 pm
by rimai
yes, but choose hard coded instead of internal memory.
It may be that your settings in the internal memory are not what you think and we can't troubleshoot if the settings are not hard coded.

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 5:19 pm
by cgonser
Ok, I did it the other way and not internal....my lights just shut off... HELP Please

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 = 0;
    // Ports toggled in Water Change Mode
    ReefAngel.WaterChangePorts = 0;
    // 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( 840 );

    // Feeeding and Water Change mode speed
    ReefAngel.DCPump.FeedingSpeed=0;
    ReefAngel.DCPump.WaterChangeSpeed=0;


    // Ports that are always on
    ReefAngel.Relay.On( Port4 );
    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,1200,0 );
    ReefAngel.StandardLights( Port2,9,0,19,0 );
    ReefAngel.StandardHeater( Port3,778,803 );
    ReefAngel.StandardLights( Port7,9,0,19,0 );
    ReefAngel.PWM.SetDaylight( PWMParabola(9,0,20,0,5,80,5) );
    ReefAngel.PWM.SetActinic( PWMParabola(9,0,20,0,5,80,5) );
    ReefAngel.DCPump.UseMemory = false;
    ReefAngel.DCPump.SetMode( LongPulse,100,10 );
    ReefAngel.DCPump.DaylightChannel = None;
    ReefAngel.DCPump.ActinicChannel = None;
    ReefAngel.DCPump.ExpansionChannel[0] = Sync;
    ReefAngel.DCPump.ExpansionChannel[1] = AntiSync;
    ReefAngel.DCPump.ExpansionChannel[2] = None;
    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( "cgonser" );
    ReefAngel.ShowInterface();
}


Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 5:40 pm
by rimai
What time is your controller showing?

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 5:46 pm
by cgonser
Its actually showing an hour fast, but thats still not lights out time
I went back to "internal" changed nothing else and lights are back on schedule

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 5:46 pm
by rimai
What time is it showing on the screen?

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 6:08 pm
by cgonser
right now 9:07pm

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 6:13 pm
by rimai
Well, according to your code, your lights go off at 7pm.

Code: Select all

    ReefAngel.StandardLights( Port7,9,0,19,0 );

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 6:16 pm
by cgonser
How do I fix it, thats not the times I set the wizard up as

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 6:23 pm
by cgonser
Also, my lights aren't ran off port 7

Re: Doesnt seem to be doing what I want! HELP?

Posted: Sat Jan 24, 2015 6:43 pm
by rimai
Make sure to go through the wizard and set the correct ports.
It seems you are choosing the wrong ones.