Lunar hub and water level expansion

New members questions
Post Reply
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Lunar hub and water level expansion

Post by jack »

thanks guys for soo much detailed info for the RA and most importantly to RAwizard thats an amazing tool
but still i am stuck somewhere and i am sure you guys are here to help me out.... i may sound too silly but to be true i am not very friendly with the tech and what i want reef angel is not able to do it...

soo here it goes...


1) want to control jeabo wp40 at 40% and at night at 20% and for few hours just 10% for very easy flow as my tank is small for wp40

2) want to control lunar hub light at lower intensity according to my wish, like 40% - 50%

3) how to setup ATO with the help of water expansion hub ?? i also need guidline setting the water level expansion.
how to set the ATO i have bought ATO pump of RA pictorial reference pics ll help

4) not able to control reefangel on safari or browser or via iphone app outside the home network


thanks for the help in advance :) cheers !!!!
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

1. Jebao pumps can't run that low. They just stop. You will need to play with it, but I think the lowest it goes is about 20-25%.
2. Which channel is your lunar hub connected to?
3. Check the manual on how to setup the water level expansion, then check this thread: http://forum.reefangel.com/viewtopic.ph ... 55&p=29467
4. You must setup port forwarding on your router to be able to do that.
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

thanks roberto for the quick reply

1) ll play around with it
2) its connected to the next port where my jeabo wire is connected... one thing i tried to fix the wires in the holes given but everytime i do the wires just pops out of the hole... they are very loose is there a special way to fix it in ??
3) thanks for the link ll have to read in detail
4) reading another page hope that helps
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

2. Yes, push the orange tab if you are having difficulties making the wire catch. This will open the catch making it easier to push all the way in. We need to know which channel you have it connected. The wizard can create the code for the moon phase too :)
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

1) all done but still playing
2) thanks ll check once back from touring
3) not getting head and tail of what it says.... i am going for a weeks touring and no one to take care of the tank so have to get this thing running in a day else my tank ll crash badly.... :(


5) how can i get emails and sms of my tank stats ??
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

Did you setup the water level expansion according to manual?
And calibrated?
Is it reporting water level accordingly?
Use the portal to send email/sms
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

portal ??

yes i did calibrated according to the mannual......
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

Yes, the Portal. The link is on the top of the page, but here it is: http://forum.reefangel.com/portal.php
It will work if you have your wifi attachment setup and sending data to the server.
If you have the WL all ready to go, you can just add this to your loop() section of your code:

Code: Select all

ReefAngel.WaterLevelATO(Port1,60,32,35);
The code above will use port1 to control your ATO pump with 60 seconds timeout and will maintain the level between 32% and 35%.
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

ohkieee....

soo ll try that not getting the ATO stuff but will sole the wifi problem now....

i opened my router and added the port forwarding to it... soo its done i think soo
but i am still not able to access the iphone app with my ip adress and port in the app from my iphone....
nor i am able to access my webpage from the safari it opens and says reef angel web server but not showing any readings....
i also tried the safari on iphone but there also didnt able to open....
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

on the iphone app, make sure you use the ip address with the http:// in front of it.
It should be like http://xxx.xxx.xxx.xxx
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

did the same bro.... not working... its just working in my home network once i turn the wifi off its not working...
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

rimai wrote:Yes, the Portal. The link is on the top of the page, but here it is: http://forum.reefangel.com/portal.php
It will work if you have your wifi attachment setup and sending data to the server.
If you have the WL all ready to go, you can just add this to your loop() section of your code:

Code: Select all

ReefAngel.WaterLevelATO(Port1,60,32,35);
The code above will use port1 to control your ATO pump with 60 seconds timeout and will maintain the level between 32% and 35%.

this is my code that the RA generated soo now where do i feed the code that you gave ??

also i want it to be in port 7 not in port 1

thanks


#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 <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.SetTemperatureUnit( Celsius ); // set to Celsius Temperature

// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port3Bit | Port4Bit | Port6Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = Port1Bit | Port2Bit;
// 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( 280 );

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


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

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


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

void loop()
{
ReefAngel.StandardLights( Port1,17,0,21,0 );
ReefAngel.StandardLights( Port2,17,0,21,0 );
ReefAngel.PWM.SetDaylight( MoonPhase() );
ReefAngel.PWM.SetActinic( MoonPhase() );
ReefAngel.DCPump.UseMemory = false;
ReefAngel.DCPump.SetMode( ShortPulse,20,10 );
ReefAngel.DCPump.DaylightChannel = None;
ReefAngel.DCPump.ActinicChannel = None;
////// Place your custom code below here


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

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

void DrawCustomMain()
{
int x,y;
char text[10];
// Parameters
#if defined DisplayLEDPWM && ! defined RemoveAllLights
ReefAngel.LCD.DrawMonitor( 15, 14, ReefAngel.Params,
ReefAngel.PWM.GetDaylightValue(), ReefAngel.PWM.GetActinicValue() );
#else // defined DisplayLEDPWM && ! defined RemoveAllLights
ReefAngel.LCD.DrawMonitor( 15, 14, ReefAngel.Params );
#endif // defined DisplayLEDPWM && ! defined RemoveAllLights
pingSerial();

// Salinity
ReefAngel.LCD.DrawText( COLOR_DARKKHAKI,DefaultBGColor,49,54, "SAL:" );
ReefAngel.LCD.DrawSingleMonitor( ReefAngel.Params.Salinity,COLOR_DARKKHAKI,73,54, 10 );
pingSerial();

// Water Level
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,75,75, "WL:" );
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,99,75, ReefAngel.WaterLevel.GetLevel() );
pingSerial();

// Main Relay Box
byte TempRelay = ReefAngel.Relay.RelayData;
TempRelay &= ReefAngel.Relay.RelayMaskOff;
TempRelay |= ReefAngel.Relay.RelayMaskOn;
ReefAngel.LCD.DrawOutletBox( 12, 95, TempRelay );
pingSerial();

// Date and Time
ReefAngel.LCD.DrawDate( 6, 122 );
pingSerial();
}

void DrawCustomGraph()
{
}
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

Ahh... if you are trying to make it work on 3G, you need to use the IP address that your internet provider assigns to you.
I thought it wasn't working at all.
So you do need to make sure you have the port forwarding correctly setup.
http://www.yougetsignal.com/tools/open-ports/
When you check for port 2000, it must say open.
The remote address shown in that page is the IP address that your ISP assigned to you.
It may change frequently though and every time it changes, you will not be able to connect.
To solve that, you either call your ISP and ask for static ip address or you will need to use other tools such as dynamic DNS.
Roberto.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

Or you can use the portal.
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

as of now better use portal.....

not ATO please
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lunar hub and water level expansion

Post by rimai »

Add the code I posted between these lines:
////// Place your custom code below here


////// Place your custom code above here
Roberto.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

but it ll switch on in port 1 right ?? i want it in port 7....

now the portal says

Only available with valid wifi address. Please make sure your controller is sending data to the Portal web server.

what is this now :( i am tired ;/
User avatar
lnevo
Posts: 5422
Joined: Fri Jul 20, 2012 9:42 am

Re: Lunar hub and water level expansion

Post by lnevo »

There are two aspects to the wifi. Every 5 minutes your controller sends out data to the portal which logs it for historical purposes. The IP is also recorded so if your ISP changes it on you then the portal always has the correct data. This connection is outgoing from your home and therefore does not rely on the port forwarding to be setup.

When you log into the portal it shows you this cached data, but then tries to refresh once per minute and directly connect to your RA. This connection is from the internet into your home network and requires that port forwarding is setup and working. Otherwise this traffic is blocked.
User avatar
lnevo
Posts: 5422
Joined: Fri Jul 20, 2012 9:42 am

Re: Lunar hub and water level expansion

Post by lnevo »

jack wrote:but it ll switch on in port 1 right ?? i want it in port 7....

now the portal says

Only available with valid wifi address. Please make sure your controller is sending data to the Portal web server.

what is this now :( i am tired ;/
Change the port and the settings. The code Roberto gave was a template you can use for your configuration.
User avatar
lnevo
Posts: 5422
Joined: Fri Jul 20, 2012 9:42 am

Re: Lunar hub and water level expansion

Post by lnevo »

rimai wrote:Yes, the Portal. The link is on the top of the page, but here it is: http://forum.reefangel.com/portal.php
It will work if you have your wifi attachment setup and sending data to the server.
If you have the WL all ready to go, you can just add this to your loop() section of your code:

Code: Select all

ReefAngel.WaterLevelATO(Port1,60,32,35);
The code above will use port1 to control your ATO pump with 60 seconds timeout and will maintain the level between 32% and 35%.
So based on the above, if you wanted Port 7 and you wanted a 50 second timeout and you wanted the water level between 40 and 45% you woudl modify the line to look like this:

Code: Select all

ReefAngel.WaterLevelATO(Port7,50,40,45);
The function takes the arguments like this ReefAngel.WaterLevelATO(Port, Timeout, MinLevel, MaxLevel);

Hope this clears some things up. Most of the functions take arguments like that. Once you learn the syntax a little, it should make more sense.
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

ohkie thanks got it....

i use reef angel wizard and on port 7 i have chosen always off soo do i need to get it always on ? or do i need to select ATO ??

sorry this must be too silly questions but i am new to this stuff....

thanks for the help

have a look at the code i think i have written the code at the right place...


#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 <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.SetTemperatureUnit( Celsius ); // set to Celsius Temperature

// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = Port3Bit | Port4Bit | Port6Bit;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = Port1Bit | Port2Bit;
// 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( 280 );

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


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

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


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

void loop()
{
ReefAngel.StandardLights( Port1,17,0,21,0 );
ReefAngel.StandardLights( Port2,17,0,21,0 );
ReefAngel.PWM.SetDaylight( MoonPhase() );
ReefAngel.PWM.SetActinic( MoonPhase() );
ReefAngel.PWM.SetChannel( 0, MoonPhase() );
ReefAngel.PWM.SetChannel( 1, MoonPhase() );
ReefAngel.PWM.SetChannel( 2, MoonPhase() );
ReefAngel.DCPump.UseMemory = false;
ReefAngel.DCPump.SetMode( ShortPulse,20,10 );
ReefAngel.DCPump.DaylightChannel = Sync;
ReefAngel.DCPump.ActinicChannel = Sync;
ReefAngel.DCPump.ExpansionChannel[0] = Sync;
ReefAngel.DCPump.ExpansionChannel[1] = Sync;
ReefAngel.DCPump.ExpansionChannel[2] = Sync;
ReefAngel.DCPump.ExpansionChannel[3] = None;
ReefAngel.DCPump.ExpansionChannel[4] = None;
ReefAngel.DCPump.ExpansionChannel[5] = None;
////// Place your custom code below here
ReefAngel.WaterLevelATO(Port7,50,90,95);

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

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

void DrawCustomMain()
{
int x,y;
char text[10];
// Dimming Expansion
x = 15;
y = 2;
for ( int a=0;a<6;a++ )
{
if ( a>2 ) x = 75;
if ( a==3 ) y = 2;
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,x,y,"Ch :" );
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,x+12,y,a );
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,x+24,y,ReefAngel.PWM.GetChannelValue(a) );
y += 10;
}
pingSerial();

// Parameters
#if defined DisplayLEDPWM && ! defined RemoveAllLights
ReefAngel.LCD.DrawMonitor( 15, 35, ReefAngel.Params,
ReefAngel.PWM.GetDaylightValue(), ReefAngel.PWM.GetActinicValue() );
#else // defined DisplayLEDPWM && ! defined RemoveAllLights
ReefAngel.LCD.DrawMonitor( 15, 35, ReefAngel.Params );
#endif // defined DisplayLEDPWM && ! defined RemoveAllLights
pingSerial();

// Salinity
ReefAngel.LCD.DrawText( COLOR_DARKKHAKI,DefaultBGColor,49,68, "SAL:" );
ReefAngel.LCD.DrawSingleMonitor( ReefAngel.Params.Salinity,COLOR_DARKKHAKI,73,68, 10 );
pingSerial();

// Water Level
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,75,82, "WL:" );
ReefAngel.LCD.DrawText( COLOR_DARKGOLDENROD,DefaultBGColor,99,82, ReefAngel.WaterLevel.GetLevel() );
pingSerial();

// Main Relay Box
byte TempRelay = ReefAngel.Relay.RelayData;
TempRelay &= ReefAngel.Relay.RelayMaskOff;
TempRelay |= ReefAngel.Relay.RelayMaskOn;
ReefAngel.LCD.DrawOutletBox( 12, 95, TempRelay );
pingSerial();

// Date and Time
ReefAngel.LCD.DrawDate( 6, 122 );
pingSerial();
}

void DrawCustomGraph()
{
}
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

yeahhh its working .... thanks roberto and inevo for answering my silly questions :p

soo here comes one more question

i think i am not able to control my Jeabo and moonlights
reason
1) jeabo overflowing the tank with waves soo thinking its running 100%
2) moonlights are not getting off in the morning ... are they suppose to ?

soo here is the pic i have attached where i have pluged the Jeabo and moon light cables...

Image

the first from the left is the dimming modules wire
and the second is jeabo.... the one in middle, next to computer cable

i hope this helps

thanks :)
User avatar
lnevo
Posts: 5422
Joined: Fri Jul 20, 2012 9:42 am

Re: Lunar hub and water level expansion

Post by lnevo »

Do you have a dimming expansion? All your ports are set to MoonPhase()

That could be interfering. Is your wifi module setup? What does the portal show for your DCPump settings (under Internal memory...)
jack
Posts: 47
Joined: Wed Aug 21, 2013 12:37 am

Re: Lunar hub and water level expansion

Post by jack »

My reefangelid:
jack
Connection Status:
Unreachable Address

Last Update:
20 September 2013 5:46:36 PM GMT+05:30
Displaying data from:
Webbanner database


this is what my portal says now... :( i am not able to connect... daam
User avatar
lnevo
Posts: 5422
Joined: Fri Jul 20, 2012 9:42 am

Re: Lunar hub and water level expansion

Post by lnevo »

Ok, well don't panic...

20 September 2013 5:46:36 PM GMT+05:30

Since the portal received an update from your controller at This means your wifi is working and it's sending data to the portal.

What you need to focus on now is setting up port forwarding. You will need to go into your router configuration and set port 2000 to forward to the IP address of your RA Wifi. This is the address you should have gotten during the setup.

There's a lot of threads on troubleshooting the port forwarding on the forum and on google, but obviously post back here for specific questions.
Post Reply