New user BLUES!!! HELP!!

Do you have a question on how to do something.
Ask in here.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

New user BLUES!!! HELP!!

Post by ICEMAN330824 »

I currently have been running a digital aquatics reef keeper setup. Just recently purchased this reef angel plus with wifi attachment and oh boy am i ready to slam this on the ground. Why so complicated? I just want to rename my ports to what they are so I can see them on the screen, and set them to what I want... example

port 1- rename to lights, on 9am & off 8pm time, off when over heat 81deg based off temp probe
port 2- rename to alk doising pump, on 9 times a day for 6 minutes every hour from 8pm, off based off ph probe of 8.45
port 3- rename to cal doising pump, on 9 times a day for 6 minutes every hour from 9am, off based off ph probe of 8.45
port 4- rename to fan, control based on temp probe from 78.7 up turn on with hysterisis of .004deg
port 5- rename to heater, turn on below 78 with hysterisis of .004deg
port 6- rename to powerheads, turn on all day except off for my auto feeder from 10:00-10:15am and 1:00-1:15pm and off for manual feeding
port 7- rename to night lights, on from 8pm to 10 am
port 8- rename to skimmer, on all the time

somthing like this, it was easy on the reef keeper. I tried to setup wifi attachment but more problems there, I get false on my readings after test, and blinking green light like it works, so who knows. If there is anyone one here in the houston area, ill come to you if you can help me program this thing and learn how in the process, I tried to find a step by step example but couldnt fine one. I saw some cheesy videos but they didnt show in depth setup. thanks in advance for your help.
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Try the Reef Angel Wizard.
Open Arduino and go to menu Tools->Reef Angel Wizard
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

rimai wrote:Try the Reef Angel Wizard.
Open Arduino and go to menu Tools->Reef Angel Wizard
This actually was a help, lol. However I still need help with setting up my dosing pump specific times i listed above because I like to dose alk at night to help stabilize ph, and cal during the day. Also I need to know how to put my power-heads on a timer setup for those specific times above as well to shut down when my auto feeder disperses. Also how to rename the ports? I wish someone were local to help me set all this up as well as this wifi module.
Image
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

Heres my code I made with the wizard below if you could help me fix it to do the above I desire.. all help is appreciated
#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 <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
    // Ports toggled in Feeding Mode
    ReefAngel.FeedingModePorts = Port6Bit;
    // 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 = Port1Bit | Port5Bit;
    // Use T1 probe as temperature and overheat functions
    ReefAngel.TempProbe = T1_PROBE;
    ReefAngel.OverheatProbe = T1_PROBE;
    // Set the Overheat temperature setting
    InternalMemory.OverheatTemp_write( 810 );


    // Ports that are always on
    ReefAngel.Relay.On( Port8 );

    ////// Place additional initialization code below here
    

    ////// Place additional initialization code above here
}

void loop()
{
    ReefAngel.StandardLights( Port1,9,0,20,0 );
    ReefAngel.DosingPumpRepeat( Port2,0,58,135 );
    ReefAngel.DosingPumpRepeat( Port3,3,58,135 );
    ReefAngel.StandardFan( Port4,785,786 );
    ReefAngel.StandardHeater( Port5,780,783 );
    ReefAngel.Wavemaker( Port6,0 );
    ReefAngel.StandardLights( Port7,20,0,10,0 );
    ////// Place your custom code below here
    

    ////// Place your custom code above here

    // This should always be the last line
    ReefAngel.Portal( "iceman330824" );
    ReefAngel.ShowInterface();
}

Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Best way is to do the dosers is to turn them every hour for 360s and use them only in the period that you want them to work

Code: Select all

  if ( hour() >=20 || hour() < 5)
    ReefAngel.DosingPumpRepeat( Port2,0,60,360 );
  else
    ReefAngel.Relay.Off( Port2 );

  if ( hour() >=9 && hour() <18) 
    ReefAngel.DosingPumpRepeat( Port3,0,60,360 );
  else
    ReefAngel.Relay.Off( Port3 );
Same concept for your powerheads:

Code: Select all

  if (( hour()=10 && minute()<15) || (hour()=13 && minute()<15))
    ReefAngel.Relay.Off (Port6);
  else
    ReefAngel.Relay.On (Port6);
What do you mean as rename the ports?
They are not shown on the screen. Are you talking about in webbanners or in the Portal?
If so, simply visit the Portal and click Labels.
http://forum.reefangel.com/portal.php
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

Ok i really appreciate your patience and helping me with this but..... can you use what im asking for an example. I kinda understand what your saying but heres what I need

port 2- alk doising pump, on 9 times a day for 6 minutes every hour from 8pm, emergency shutoff based off ph probe of 8.45

8pm - 8:06 on and 54min off
9pm - 9:06 on and 54min off
10pm - 10:06 on and 54min off
11m - 11:06 on and 54min off
12pm - 12:06 on and 54min off
1am - 1:06 on and 54min off
2am - 2:06 on and 54min off
3am - 3:06 on and 54min off
4am - 4:06 on and 54min off

thats is a total of 9 times thru the night when my lights go out on alkalinty dosing, the rest of the time i want the pump off...and somthing simular for the calcium

port 3- cal doising pump, on 9 times a day for 6 minutes every hour from 9am, emergency shutoff based off ph probe of 8.45

port 6- powerheads, turn on all day except off for my auto feeder from 10:00-10:15am and 1:00-1:15pm and off for manual feeding

I need these on from 12am-10:00am and off from 10:00am-10:15 and on from 10:15 to 1:00 and off from 1:00pm-1:15pm and back on from 1:15pm to 12am

so im sure im interpreting what your saying wrong like what does the =20 and =9 mean for doising pumps and =10 for powerheads?
Last edited by ICEMAN330824 on Fri Jul 06, 2012 7:59 pm, edited 1 time in total.
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

That's what I did.
hour() >= 20 means hour greater than and equal to 20 hours.
We use military time.
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

rimai wrote:That's what I did.
hour() >= 20 means hour greater than and equal to 20 hours.
We use military time.

ok see my post above i edited to elaborate on what i mean. why 20hrs we have 24 hrs

so for what i need to happen

if 24hrs on
off from 04:00 to 20:00
---->>> then on 00:06min every 00:54min unil 04:00 which would give me my 9 times?
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

I think you didn't quite understand the code.
We use C++ programming language.
if ( hour() >=20 || hour() < 5) means if the hour of the day is greater than or equal to 20 or hour of the day is less than 5, will give you 9 hours.
So, if the above is true, the following line is executed
ReefAngel.DosingPumpRepeat( Port2,0,60,360 ) means dose every 60 minutes for 360 seconds
else means if the first check is not true execute the next line
ReefAngel.Relay.Off( Port2 ) means turn off the port, which for the check above, would make the port 2 off from 5 to 19 hours.
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

rimai wrote:I think you didn't quite understand the code.
We use C++ programming language.
if ( hour() >=20 || hour() < 5) means if the hour of the day is greater than or equal to 20 or hour of the day is less than 5, will give you 9 hours.
So, if the above is true, the following line is executed
ReefAngel.DosingPumpRepeat( Port2,0,60,360 ) means dose every 60 minutes for 360 seconds
else means if the first check is not true execute the next line
ReefAngel.Relay.Off( Port2 ) means turn off the port, which for the check above, would make the port 2 off from 5 to 19 hours.

Ok Roberto ..I finally think I understand sir, so you've written the code to my exact needs which I see now, lol...and truly appreciate, where do I cut and paste those 3 codes in mine above, can u copy and paste it into mine above we're I need to. Thanks again...your the man
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Yeah, simply delete the old ones you don't want anymore

Code: Select all

    ReefAngel.DosingPumpRepeat( Port2,0,58,135 );
    ReefAngel.DosingPumpRepeat( Port3,3,58,135 );
And

Code: Select all

    ReefAngel.Wavemaker( Port6,0 );
Then copy/paste the ones I posted above.
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

I tried that and it gives me a "lvalue required as left operand of assignment" in a orange line and wont upload the code below... this is the line it highlights

if (( hour()=10 && minute()<15) || (hour()=13 && minute()<15))

.....................................................


#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 <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
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port6Bit;
// 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 = Port1Bit | Port5Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 810 );


// Ports that are always on
ReefAngel.Relay.On( Port8 );

////// Place additional initialization code below here


////// Place additional initialization code above here
}

void loop()
{
ReefAngel.StandardLights( Port1,9,0,20,0 );
if ( hour() >=20 || hour() < 5)
ReefAngel.DosingPumpRepeat( Port2,0,60,360 );
else
ReefAngel.Relay.Off( Port2 );

if ( hour() >=9 && hour() <18)
ReefAngel.DosingPumpRepeat( Port3,0,60,360 );
else
ReefAngel.Relay.Off( Port3 );
ReefAngel.StandardFan( Port4,785,786 );
ReefAngel.StandardHeater( Port5,780,783 );
if (( hour()=10 && minute()<15) || (hour()=13 && minute()<15))
ReefAngel.Relay.Off (Port6);
else
ReefAngel.Relay.On (Port6);
ReefAngel.StandardLights( Port7,20,0,10,0 );
////// Place your custom code below here


////// Place your custom code above here

// This should always be the last line
ReefAngel.Portal( "iceman330824" );
ReefAngel.ShowInterface();
}
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Sorry.. Typo.

Replace this:

Code: Select all

if (( hour()=10 && minute()<15) || (hour()=13 && minute()<15))
With this:

Code: Select all

  if (( hour()==10 && minute()<15) || (hour()==13 && minute()<15))
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

Great that let me upload it now to wait to see if it works, im sure it will... Roberto your the man, I think I can hook it up to my tank now. Just need to figure out the wifi attachment issue im having.

Is there anyway to customize the screen to stop showing error on the 2 temp ports im not using at this moment? or any custom coded screens out there that are pretty cool and simple.
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Nice :)
If you keep browsing the forums, you will find lots of custom screens from other users :)
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: New user BLUES!!! HELP!!

Post by binder »

ICEMAN330824 wrote:Is there anyway to customize the screen to stop showing error on the 2 temp ports im not using at this moment? or any custom coded screens out there that are pretty cool and simple.
Check this out.
http://forum.reefangel.com/viewtopic.php?f=14&t=109

It should at least give you a start. :)
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

Very cool Roberto & Curt..... is there one that has the following from top to bottom with no graph

personal name - located top

time
date

ph - located in middle
temperature

realy module- located bottom normal on off bar

this would be an awesome setup.....
also is one able to turn off the ports 1-8 with the reef angel head unit by like slecting one with the joystick then clicking off / on ?
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

I don't think there is one like that, but you could certainly create one :)
You can easily do the on/off with any of the smart phone apps or Dave's Client Suite.
If you don't have the wifi, I suggest Dave's Client Suite software. Download it here: http://www.reefangel.com/Download.ashx
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

rimai wrote:I don't think there is one like that, but you could certainly create one :)
You can easily do the on/off with any of the smart phone apps or Dave's Client Suite.
If you don't have the wifi, I suggest Dave's Client Suite software. Download it here: http://www.reefangel.com/Download.ashx

Ok cool, writing that code looks to be complicated perhaps I can pay you or somone to write it for me. Also I have finally got my wifi attachment semi working I guess, lol. I am able to display and turn off and on ports on the internet portal here. I can only view them on my droid cell phone as to what is on, but my device has to be on reefangel.com in order to view my ports but I cant turn them off and on like I can online thru the portal. I did add the port forwarding deal to my router but still doesnt connect that way. I guess I have to be using conrotroller device option to turn ports on and off on my cell and not reefangel.com. Also when I try to click update on the portal & input my port here at home it doesnt work. But when I leave the default port of 74.197.xxx.xxx:2000 (update) it does work. Odd. So some help with this would be appreciated, again I would be willing to pay you roberto or somone to make the code for that display setup I want, lmk. thanks
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

I'm sorry, man.
I can't take your money. :(
But I can accept you bragging about your RA with other reefers :)
Try this code below. I used framework designed by psyrob and just moved stuff around.

Code: Select all

void DrawCustomMain()
{
  // the graph is drawn/updated when we exit the main menu &
  // when the parameters are saved
  ReefAngel.LCD.DrawDate(6, 64);
  ReefAngel.LCD.DrawLargeText(COLOR_DARKTURQUOISE, COLOR_WHITE, 19, 4 , "ICEMAN330824");
  ReefAngel.LCD.Clear(COLOR_MAROON, 1, 13, 132, 13);
  ReefAngel.LCD.Clear(COLOR_MAROON, 10, 75, 119, 75);
  ReefAngel.LCD.Clear(COLOR_MAROON, 10, 59, 119, 59);
  pingSerial();


  ReefAngel.LCD.DrawLargeText(COLOR_GOLDENROD, COLOR_WHITE, 33, 15, "Tank Water");
  char text[7];
  ConvertNumToString(text, ReefAngel.Params.Temp[T1_PROBE], 10);
  pingSerial();
  ReefAngel.LCD.DrawHugeText(COLOR_GOLDENROD, DefaultBGColor, 38, 26, text);

  ReefAngel.LCD.DrawLargeText(COLOR_MEDIUMSEAGREEN, COLOR_WHITE, 60, 42, "pH");
  ConvertNumToString(text, ReefAngel.Params.PH, 100);

  ReefAngel.LCD.DrawLargeText(PHColor, DefaultBGColor, 53, 50, text);
  pingSerial();

  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,84,"DayLts");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,94,"Alk");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,104,"Calcium");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,114,"Fan");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,84,"Heater");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,94,"PwrHead");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,104,"NghtLts");
  ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,114,"Skimmer");
  byte TempRelay = ReefAngel.Relay.RelayData;
  TempRelay &= ReefAngel.Relay.RelayMaskOff;
  TempRelay |= ReefAngel.Relay.RelayMaskOn;
  ReefAngel.LCD.DrawCircleOutletBox(60, 86, TempRelay, true);
}

void DrawCustomGraph()
{

}
Just add this piece of code just above void setup()

Let me know if it works for you :)
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

Wow great Roberto ill give it a try and let you know. an I will definatly be bragging about your awesomeness already from helping me.

Do I need to do the following to get this code to work,

"First, you need to open RAGen. Once opened, click on the Features tab. Scroll down the window until you see the option for “Custom Main Screen”. You need to check the box next to it. Once checked, you need to click the “Save” button and you are ready to go."

and I attached my exact placement of your code so you could tell me if i put it in the right spot for it to work. lmk thanks again
.....

#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 <ReefAngel.h>

////// Place global variable code below here


////// Place global variable code above here

void DrawCustomMain()
{
// the graph is drawn/updated when we exit the main menu &
// when the parameters are saved
ReefAngel.LCD.DrawDate(6, 64);
ReefAngel.LCD.DrawLargeText(COLOR_DARKTURQUOISE, COLOR_WHITE, 19, 4 , "ICEMAN330824");
ReefAngel.LCD.Clear(COLOR_MAROON, 1, 13, 132, 13);
ReefAngel.LCD.Clear(COLOR_MAROON, 10, 75, 119, 75);
ReefAngel.LCD.Clear(COLOR_MAROON, 10, 59, 119, 59);
pingSerial();


ReefAngel.LCD.DrawLargeText(COLOR_GOLDENROD, COLOR_WHITE, 33, 15, "Tank Water");
char text[7];
ConvertNumToString(text, ReefAngel.Params.Temp[T1_PROBE], 10);
pingSerial();
ReefAngel.LCD.DrawHugeText(COLOR_GOLDENROD, DefaultBGColor, 38, 26, text);

ReefAngel.LCD.DrawLargeText(COLOR_MEDIUMSEAGREEN, COLOR_WHITE, 60, 42, "pH");
ConvertNumToString(text, ReefAngel.Params.PH, 100);

ReefAngel.LCD.DrawLargeText(PHColor, DefaultBGColor, 53, 50, text);
pingSerial();

ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,84,"DayLts");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,94,"Alk");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,104,"Calcium");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,10,114,"Fan");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,84,"Heater");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,94,"PwrHead");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,104,"NghtLts");
ReefAngel.LCD.DrawText(COLOR_MEDIUMSEAGREEN,DefaultBGColor,80,114,"Skimmer");
byte TempRelay = ReefAngel.Relay.RelayData;
TempRelay &= ReefAngel.Relay.RelayMaskOff;
TempRelay |= ReefAngel.Relay.RelayMaskOn;
ReefAngel.LCD.DrawCircleOutletBox(60, 86, TempRelay, true);
}

void DrawCustomGraph()
{

}

void setup()
{
// This must be the first line
ReefAngel.Init(); //Initialize controller
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port6Bit;
// 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 = Port1Bit | Port5Bit;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 810 );


// Ports that are always on
ReefAngel.Relay.On( Port8 );

////// Place additional initialization code below here


////// Place additional initialization code above here
}

void loop()
{
ReefAngel.StandardLights( Port1,9,0,20,0 );
if ( hour() >=20 || hour() < 5)
ReefAngel.DosingPumpRepeat( Port2,0,60,360 );
else
ReefAngel.Relay.Off( Port2 );

if ( hour() >=9 && hour() <18)
ReefAngel.DosingPumpRepeat( Port3,0,60,360 );
else
ReefAngel.Relay.Off( Port3 );
ReefAngel.StandardFan( Port4,785,786 );
ReefAngel.StandardHeater( Port5,780,783 );
if (( hour()==10 && minute()<15) || (hour()==13 && minute()<15))
ReefAngel.Relay.Off (Port6);
else
ReefAngel.Relay.On (Port6);
ReefAngel.StandardLights( Port7,20,0,10,0 );
////// Place your custom code below here


////// Place your custom code above here

// This should always be the last line
ReefAngel.Portal( "iceman330824" );
ReefAngel.ShowInterface();
}
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Everything looks good. Have you tried it yet?
Roberto.
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

rimai wrote:Everything looks good. Have you tried it yet?
Waaa Laaaaaa!!!!Your the man it worked awesome, i just had to rename some ports but no biggie. Yes :D

Image
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Nice :)
Roberto.
astralmind
Posts: 98
Joined: Fri Apr 01, 2011 10:53 am

Re: New user BLUES!!! HELP!!

Post by astralmind »

Very cool! I wonder if it could somehow make sense to developp a custom screen wizard, maybe an extra step to the existing wizard? Could start off with pre-made templates and eventually give some customization options?

Then again, I wonder how many people actually use their RA screen for anything else than debugging and setup with the kick ass portal and mobile apps we've got :)
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

Dave started on a custom screen app, but never finished :(
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: New user BLUES!!! HELP!!

Post by binder »

rimai wrote:Dave started on a custom screen app, but never finished :(
Ive got some ideas on doing this. I need to revisit this app idea. :)
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

glad I could spark all this convo on it, I agree we need a quick guide options of some sort. Very cool indeed
Image
ICEMAN330824
Posts: 26
Joined: Fri Jul 06, 2012 5:22 pm

Re: New user BLUES!!! HELP!!

Post by ICEMAN330824 »

Hey Roberto or anyone. How do I get my lights to have a delay if turned off or power failure...

heres my code below....but you can see all of it a few post above

void loop()
{
ReefAngel.StandardLights( Port1,9,0,20,0 );

here's what I thought would work for a 15minute delay but doesnt

void loop()
{
ReefAngel.StandardLights( Port1,9,0,20,0,15 );
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: New user BLUES!!! HELP!!

Post by rimai »

I just noticed the wizard is not generating the correct code.
Thanks for helping identify the bug.
I put it in the list of issues: https://github.com/reefangel/Wizard/issues/4
So, to answer your question, you need to use this:

Code: Select all

ReefAngel.MHLights( Port1,9,0,20,0,15 );
Roberto.
Post Reply