Pages: 1 [2]   Go Down
Author Topic: // reeftank controller guidance plz  (Read 1723 times)
0 Members and 1 Guest are viewing this topic.
Atlanta
Offline Offline
Full Member
***
Karma: 4
Posts: 128
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

1.  "blink" your led
2.  decide on a clock and learn to drive it -> send to serial (blinking led as well)
3.  decide on a display + keypad and learn how to drive them (it)-> now to display (blinking led as well)
4.  debounce those keypresses AND keep things moving on the display (use rtc -> display -> blinking led as well)
5.  single I2C temperature reading-> display -> blinking led as well
6.  multiple I2C temperature reading -> display  -> blinking led as well
7.  Triggering of events for making something happen (clock time, temperature, keypad, state machine etc)  -> blinking led as well


You're going to have to figure physical drive for your led's - this is probably going to be your biggest issue!
Are you going to PWM drive your LED's to start them off dim so that they are effectively 0 at 7am and maybe 15 at 7:30 then start your 2nd column @ 0 ramping to 15 while your 1st row ramps from 15 to 30 etc etc? if so, sin(x); is your friend for this!

You might also want to think about full spectrum rather than just blue and white (red/green/uv/ir)

« Last Edit: February 03, 2013, 07:01:26 pm by abrookfield » Logged


Offline Offline
Newbie
*
Karma: 0
Posts: 20
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

here is what i think you mean by skeleton code. the keypad on the display isn't as necessary as the light timing, i can change the times and stuff with the coding, once i have it that is....
i don't want any one person to build the code for me, but if i can get a collective of people to help piece it together, i will be able to "learn as i go".
so... if someone has a portion that might help, my fishies will thank you smiley-wink
Quote
//start clock
//start display
//check temp
//diplay time and temp
//temp sensor in display tank for water temp display
//temp sensor on light fixture for fan control
//fans come on when lights are too warm
//the light fixture temp sensor doesn't need a display function
//lights are blue and white, two sets of each
//blues will be on with whites at all times and off at night
//sump lights are seperate
/*sequence is : 8 am first blue on, 
                9 am sump off and second blue on,
                10 am first white/blue on,
                11 am second white/blue on
                */
//all lights on for four hours
/*after four hour on time,
                3 pm the first set of whites go off,
                4 pm second set of whites go off,  
                6 pm the first blues go off, 
                7 pm the sump comes on, 
                7 pm the second blues go off.
*/
/*the lights are one hour intervals except for the all on time
starting at 8 am and the last set of blues*/


Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 20
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

to Atlanta: shortly after posting the skeleton sketch i noticed the second page of the posts and seen yours, great advice and i will work on it. but my original problem was getting the rtc, keypad display, and mega 2560 to talk together. so if you know a page where it shows how to do that, i might be able to take control from there, and i won't need to bother the forum any more except for showing the final product off.   lol
Logged

Atlanta
Offline Offline
Full Member
***
Karma: 4
Posts: 128
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The DFRbot display is a direct drop in and works flawlessly with the Mega 2560 - their sample code should get you giong easily ... look in the "LCD Keypad Library" for how to drive the dsplay, there's a good example in there http://www.dfrobot.com/index.php?route=product/product&path=53_130&product_id=51
The RTC - you show what it's supposed to physically look like but don't give interface specs or anything to it

Check out my "www.reeftopper.com" link below for more thoughts on aquarium lighting  smiley
« Last Edit: February 04, 2013, 11:02:56 am by abrookfield » Logged


Offline Offline
Newbie
*
Karma: 0
Posts: 20
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

interesting, informed.. i know i need to get more of a spectrum...
here are the lights i have right now..
http://www.aquatraders.com/EVO-Quad-60-LED-Reef-Bright-TR-p/56264.htm
i need to get the 72 inchers..
 but i might also just bite the bullet and just buy this..
http://www.bulkreefsupply.com/reefkeeper-elite-w-net-digital-aquatics.html
that would let me control relays that i could wire in with this..
http://www.bulkreefsupply.com/reefkeeper-elite-w-net-digital-aquatics.html
its alot of money, but it would delay the headache of learning programming languages..
but i still wanna make this build so i can use it on my 55 gal in the bedroom
right now i am piecing together the rtc and board, then i'll put in the keypad/lcd shield
and i might just get some more red/purple,uv,ir leds for the corals..
can i use RGB leds and PWM for those?
Logged

Atlanta
Offline Offline
Full Member
***
Karma: 4
Posts: 128
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

OBVIOUSLY, as you've summized, a ReefKeeper or Apex would get your automation up and running faster, there's nothing wrong with that, it's what I did initially
The Apex actually has a better programming interface than the ReefKeeper in my mind but I still bought the ReefKeeper!

For basic control while you're building your own controller, you'll be able to save a whole lot of money by going with the RK-Lite packages (do you really need internet availability.. can be somewhat painful to implement)

An additional thing I did (My whole system was battery backed) - I put a 120V relay onto a separate plug outlet and fed the "Normally Open" contacts into a switch input... when house power was lost, an alarm condition was triggered, I turned off everything that was non-essential (lights / skimmer / return / excessive fans / dosing pumps) keeping flow running in the tank until power got restored.

If you post on any of the reef forums asking what is best, you're likely to get slammed with this is right, this is wrong - everyone has their own way of implementing their setup so take my input with a big grain of salt  smiley-grin

Additional:  If you do go ReefKeeper route, make sure you put the power bars and controller interfaces somewhere that doesn't get too much salt laden humidity.. those 6 way network type connectors they use are cheap and are susceptible to corrosion.  It's easy enough to swap them out if they do corrode, forewarned is forearmed!   I have no idea how susceptible the Apex etc is to corrosion as I don't own one
« Last Edit: February 04, 2013, 12:25:36 pm by abrookfield » Logged


Offline Offline
Newbie
*
Karma: 0
Posts: 20
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

yes i do kinda need(want) the net interface, we are planning a outta state trip in june, = the need for the automation...
i too was thinking about the possibilities of power outages.. im gonna put a battery operated air pump normally closed on a relay to pump a jet of air into my siphon drain in the event of a PO. and if i have the Reef Keeper that can send alerts like that, i can call my neighbor to come and restart my system... the 120v relay is a must...i am also getting the...
http://www.drsfostersmith.com/product/prod_display.cfm?c=3578+4395+12093&pcatid=12093
...the 50 gpd 4-stage RO/DI...and the float valve..
it's a big project, i know...but a reef tank is worse than crack or meth...not that i'd know, just sayin..
Logged

Atlanta
Offline Offline
Full Member
***
Karma: 4
Posts: 128
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Get yourself registered on ReefCentral.com lots of good resources on there for configuring / information on saltwater automation.
Remember that once you've disabled the siphon by blowing air, your return pump better not be pumping any more water from sump into main tank until the siphon is re-primed or a couple of things might happen...
1.  Sump is going to run dry on you and you'll need a new sump pump
2.  You might overflow your display tank

Talking about RODI etc - If there's a local reef-club, get yourself logged in, see if anyone is getting out of the hobby. First rule of reefing - BUY USED if you can

We can trade tank design scenario's etc on ReefCentral (I'm "BigFloppy" over there).

Lets keep this thread on track with your arduino buildout.  The people in this forum can and will help guide you through the programming mire.
« Last Edit: February 04, 2013, 01:39:14 pm by abrookfield » Logged


Offline Offline
Newbie
*
Karma: 0
Posts: 20
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

yes, i would need another pump to draw suction on the siphon once power was restored, but that again is where the more advanced arduino programming comes in... and about the reef central, it says registration has been disabled by administrator....
Logged

Pages: 1 [2]   Go Up
Jump to: