DIY Reef Controller

nkd5024

New member
Hello Everyone,

I have been in the process of building a DIY reef controller that I have been working on pretty frequently over the past week or two. I have posted a thread on a local reef club page and didn't get to much interest, so as I am mainly posting my progress to get insight and ideas as well as to help anyone who wants to give this a go for themselves I have decided to post this in the general forums.

I would like to start out by saying that up to about 3 months ago I barely knew anything about electronics, although I did have some basic understanding of programming. So if you don't have any/much experience with electronics don't dismiss the idea if your interested.

So to start off with, my controller will be running off of an arduino mega 2560. I will be using a 3.2" Touch Screen LCD screen for the user interface.

As for the functions of the controller, I will be adding:
1) temp, ph, and ORP monitoring,
2) 5-channels of led dimming for a DIY led fixture
3) Moon phase cycle & rise/set across the tank using 4 moonlight leds,

4) Control over 8 SS Relay outlets and 8 TRIAC outlets
5) A Solid state ATO control (No floats of moving parts)
6) Basic alarm system
7) Incorporating of Reef Angels Vortech module so I can talk to mine Vortech.

I will also be use a Real Time Clock (DS_1307) for keeping time, even through power outages, a Micro SD card reading to store the data logging info for temp, pH, and ORP as well as to store settings, and images.

I am planning to make very sleek looking acrylic boxes to put the project into once I am done. I am hoping to make this look as nice as possible, by using headphone jacks and other common plugs for temp probes, ato, etc. I will also be learning how to print my own circuit boards at home for this project, so I don't have to use tons of wires everywhere.

As of right now, I have the mega 2560, sd card reader, RTC, and the touch screen up and running. I am using my own created images for buttons/icons for the display but am a bit limited because of the processor speed for updating the images. So I can't nicely add things like sliding buttons to unlock screen, depressed buttons, etc.

Here what I have so far,

IMG_2092.jpg


Lock Screen

IMG_2093.jpg


Sd card reader and RTC

IMG_2095.jpg




Nick D.
 
DIY Reef Controller

That is very nice. What coding are you using if you are using a sunrise/sunset program.

Also, what moonlight leds and dimmer are you using? And what coding do you use for that?
 
Hello!
I have a similar project using an LCD of 3.2 "Widescreen Iteadstudio.

The code can be found here: http://pastebin.com/u/FernandoGarcia

He already has integration with the Internet and the data can be viewed in real time here: https://cosm.com/feeds/69337.

Here is a picture of the home screen.

7823180592_465826618d_z.jpg


The project is still in development.

The menus are in Portuguese, but I hope it is helpful.

Hug.
Fernando Garcia

Sorry for the english I'm using Google translator.
 
moncapitane, I do plan on doing a sunrise/sunset program, I am writing all the code myself. I actually plan on having the sunrise and sunset start earlier or later depending on the time of year and the maximum brightness of each day will depend on some basic weather patterns. I have had this all planned for a while and actually can't find the notebook I had the ratios of cloudy days to sunny ones, etc. But, there will be about a 60% chance of full sun, 20% chance slightly cloudy (90-99% max), 20% chance for cloudy (75-90% of max) and 10% chance of a storm. (around 50% of max brightness) Half of storms will also have lightning, although as I have heard a lot of reports that it will freak out the fish it won't be super bright lightning.

These weather patterns will also last for varying amounts of time and proceed into new ones right afterwards. So in one day it could go from clear for 5 hours to cloudy for 2 hours, have a quick thunderstorm, and return to cloudy, before the sunset kicks in.

As for the Moonlights I have a rapid led 4 moonlight led kit running a single driver.

http://www.rapidled.com/4-led-moonlight-kit/

And as the driver can detect how many leds are on at once I can make a simple transistor circuit with the arduino output pins to turn on individual leds not just all on or all off. I also plan on running weather functions over night so the moonlight brightness will be affected by cloudy cover as well as the phases of the moon. ie. full moon no clouds = max brightness.

This is really going to test my programming knowledge considering I am by no means an expert and very frequently recode parts of the program because I learn so much as I keep going and think of better ways of doing things. As for dimming the leds its just pwm, that I am assuming will work fine with this application.

fefegarcia, is your controller also based off of the mega 2560? If not what are you using? I was debating adding internet functions and I may well in the future, but for now i'm going to leave that out.

Here is the Liquid Level sensor I will be using:
https://www.sparkfun.com/products/10221

Nick D.
 
fefegarcia, is your controller also based off of the mega 2560? If not what are you using? I was debating adding internet functions and I may well in the future, but for now i'm going to leave that out.

Nick D.

Hello!

Yes, I'm using the Mega 2560.

Best regards.

Fernando Garcia
 
Holy crap, that's awesome. Definitely subscribed for sheer nerd-coolness factor. My buddy does stuff like this but his specialty is carputers. Basically a micro-PC that does everything (GPS, cell, web, music, etc.), but inside your dash. I don't have the patience, unless I gave up my other hobbies, lol. Good luck!
 
DIY Reef Controller

And as the driver can detect how many leds are on at once I can make a simple transistor circuit with the arduino output pins to turn on individual leds not just all on or all off. I also plan on running weather functions over night so the moonlight brightness will be affected by cloudy cover as well as the phases of the moon. ie. full moon no clouds = max brightness.

This is really going to test my programming knowledge considering I am by no means an expert and very frequently recode parts of the program because I learn so much as I keep going and think of better ways of doing things. As for dimming the leds its just pwm, that I am assuming will work fine with this application.

Which driver are you using that can detect how many leds are on at one? I would love to be able to do my sunrise/sunset from left to right or right to left on each of the drivers instead of all on/off at the same time?
 
This will look good, what size tank is it going over? Finishing up a DIY makersled heat build myself over my 90g mix reef.
 
What version of the arduino IDE is your coding designed for? I noticed it is a few months old and I know they released 1.0 and 1.0.1 after the date on the coding you provided in the pastebin.

Hello!

The code is not very old but the comments at the beginning were a little messy.
Now packed and also did an update to version 2.3.7
Some libraries are not compatible with versions of IDE above 23 but I modified them to make them work.
The IDE 1.0.1 along with the required libraries can be found here: https://skydrive.live.com/redir?resid=4F0958C6A216EC!401

Hug.
Fernando Garcia
 
So its been a few days and i've been working pretty hard on getting the basic layout done. So I have a bunch of pictures of what I have so far. I am planning on completing the display programming in a week or two, at which point I can start buying the remaining hardware to add into the design. (ph, ORP, etape for ATO, etc)

So are are a few pictures of whats running now.


Home Screen:

228832_10151074173117635_185501644_n.jpg


Led Home Screen (from led dock icon):

548855_10151074173197635_1060929955_n.jpg


Manually Change max Brightness Screen (from clocking on led channel buttons in the previous photo):

564438_10151074173142635_50770093_n.jpg


Temp Home Screen (from dock thermometer), their are status icons next to the three temp channels to show whether its to hot, cold, or within range.

399578_10151074173167635_1999768952_n.jpg


This is the temperature graphing screen (selected from any of the three temp channels on last photo. One channel for tank temp, Left and Right led fixture)

536158_10151074173372635_543149972_n.jpg


This screen controls the max/min temperatures for a single one of the temp channels as well as the outlets controlling heating and cooling for that channel. (selected by the top tab)

253112_10151074173247635_1347559593_n.jpg


This is the pH screen, outlet will control the sump light and turn it on early if the pH dips below min for some reason. (selected from dock beaker icon):

199342_10151074173297635_1986007892_n.jpg


pH graph:

photo.php


Settings Screen, I still have to make all the screens for the 10 settings plus one to change the password that I forgot about.

314246_10151074173337635_1795380282_n.jpg


I still have to make a screen for the clock icon that will be able to change the time and date of the RTC plus change from 12 to 24 hour for the display clock.

So that is what I have so far, once I have the whole display and everything done I will most likely just make a quick video showing the selections, etc.

Let me know what you think so far and any suggestions.

Nick D.
 
Looking awesome!!! I can't wait to see the whole thing running. I love the background on the screen btw. Have you noticed any difference in anything with the sunrise/sunset? (corals not opening or closing early anything like that)
 
Thanks, I was inspired my the mac osx, haha. I am also adding a few nice shots of some sps, etc. so i can change the background if I get tired of it.

As far as differences since adding sunrise/set to my tank, I didn't noticed to much as of yet although its only been a couple months. I'll try and remember to watch the corals during the sunrise/set and see.
 
Have you considered adding I2C support?

Not sure about APEX but that is what Reefkeeper uses and it might be an easy way to add off the shelf Power outlet modules. That is assuming they have not encrypted their I2C packets.

Dennis
 
Back
Top