reef-pi :: An opensource reef tank controller based on Raspberry Pi.

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
Im using a pi zero w with @Michael Lane 's hat, and have not had a hardware problem at all, and with lighting, timers, macros, 8 relays, 3 temp sensors all in operation im only at 8 percent memory usage, and usually a fraction on 1 percent system usage, so I see no need for a Pi 3B. But in the future reef pi 3.0 may allow clustering of multiple reef pi installations, so a master pi 3b may be the way to go.

The rest of your questions ill defer to the people doing the development work.(and a fine job they do indeed!)
 

Mikeneedsahobby

Well-Known Member
View Badges
Joined
Sep 16, 2018
Messages
516
Reaction score
922
Rating - 0%
0   0   0
I going to have a hundred questions to ask and not sure what place is best to ask them, but for starters.. (coming from limited knowledge about this whole project)

1) Is there a particular reason why nobody seems to be using the PI-zero with the reef-pi pico board? Maybe I just missed that there are people using it. All I saw so far is people using ras-pi 3 B+.

2) I have my own ras-pi hat design based off the Tentacle T3 design you can get at Atlas. I Just have some additional customization I added to it like 1-wire headers and a power strip relay header. Will Atlas modules still be supported in the future?

3) I have a 4 pump doser design that works off the I2C bus via a micro Arduino clone board. I made it so works similar to the way the Atlas pumps work. It's a bit different in that it doesn't have built in calibration. You just tell it how many mS for a particular pump to run. How hard would this be to interface something like this to the reef-pi API? Also would calibration be possible?

4) I like to be able to add an atlas dissolved oxygen sensor because of some issues I had last time with my tank. How hard would that be to add to the reef-pi API?

Best place to get advice. = have a build thread. Teach us new things you create. Ask questions there for things that are you specific. Bring things that affect multiple people here. Like upgrade ideas, bugs. Etc.

1) I have a pi zero w with a pico baseboard. It works with no problems I can find.

2) no idea. I’m not smart enough to understand the question

3)no idea. See 2

4) ha. Ya see the other 2.

I don’t know if many others have atlas stuff. This may be something you teach the community. But everything is possible with the geniuses here.
 
Last edited:

theatrus

Valuable Member
View Badges
Joined
Mar 26, 2016
Messages
1,966
Reaction score
3,360
Location
Sacramento, CA area
Rating - 0%
0   0   0
I going to have a hundred questions to ask and not sure what place is best to ask them, but for starters.. (coming from limited knowledge about this whole project)

1) Is there a particular reason why nobody seems to be using the PI-zero with the reef-pi pico board? Maybe I just missed that there are people using it. All I saw so far is people using ras-pi 3 B+.

I can't speak for everyone, but a lot of people had a spare Pi sitting around and elected to just use that. I use only Zero Ws.
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
I going to have a hundred questions to ask and not sure what place is best to ask them, but for starters.. (coming from limited knowledge about this whole project)

1) Is there a particular reason why nobody seems to be using the PI-zero with the reef-pi pico board? Maybe I just missed that there are people using it. All I saw so far is people using ras-pi 3 B+.

2) I have my own ras-pi hat design based off the Tentacle T3 design you can get at Atlas. I Just have some additional customization I added to it like 1-wire headers and a power strip relay header. Will Atlas modules still be supported in the future?

3) I have a 4 pump doser design that works off the I2C bus via a micro Arduino clone board. I made it so works similar to the way the Atlas pumps work. It's a bit different in that it doesn't have built in calibration. You just tell it how many mS for a particular pump to run. How hard would this be to interface something like this to the reef-pi API? Also would calibration be possible?

4) I like to be able to add an atlas dissolved oxygen sensor because of some issues I had last time with my tank. How hard would that be to add to the reef-pi API?
I use almost exclusively pi zero. Most folks go with pi 3 because they are learning computer/beginners in electronics and want the GUI. Pi zero does not perform well with GUI.

Atlas ph board is already supported. I dont know when we'll support other probes. I am not too keen on using them, but I have no problem supporting them in reef-pi . i.e. if someone adds the code for it in reef-pi I 'll facilitate that effort. the openhardware/opensource ph board that we are testing/developing together can aleady be used for ORP. We are still hardening the codes for it. Its just the less important real life use of these probes that makes me not prioritize their development

We have recently added a hardware abstraction layer. If your board is opensource, I would love to add support for this board, I can help you write a driver for it in reef-pi, and that should allow you(and others) to reuse those hardware with reef-pi

Adding new hardware drivers should be very easy now.. with HAL in place. Its still under development, but if you are interested get into the slack channel and we'll help you out with test/build setup
godspeed
 

geekengineer

Active Member
View Badges
Joined
Feb 10, 2019
Messages
427
Reaction score
538
Location
South Aurora
Rating - 0%
0   0   0
I use almost exclusively pi zero. Most folks go with pi 3 because they are learning computer/beginners in electronics and want the GUI. Pi zero does not perform well with GUI.

Atlas ph board is already supported. I don't know when we'll support other probes. I am not too keen on using them, but I have no problem supporting them in reef-pi . i.e. if someone adds the code for it in reef-pi I 'll facilitate that effort. the openhardware/opensource ph board that we are testing/developing together can aleady be used for ORP. We are still hardening the codes for it. Its just the less important real life use of these probes that makes me not prioritize their development

We have recently added a hardware abstraction layer. If your board is opensource, I would love to add support for this board, I can help you write a driver for it in reef-pi, and that should allow you(and others) to reuse those hardware with reef-pi

Adding new hardware drivers should be very easy now.. with HAL in place. Its still under development, but if you are interested get into the slack channel and we'll help you out with test/build setup
godspeed

Cool that answers some of what I was looking for.

So is this open source PH board your talking about something different? or is that the pico board you are talking about?

Yeah I can't say that Altas is cheapest or best way to go all the time, but they do offer a flexible set of different probe interfaces which is handy in some situations.

I'm not sure if I would get in trouble making my board open source, since I sort of copied part of a different board that was out there? (it does say the T3 board I sort of borrowed from is open source) The board I have currently is meant for a hydroponics project that I didn't totally finish yet. I would of course adapt a new version to have more aquarium stuff to it. Also I am not sure how much time I could devote to making it really polished if it needs to be in order to be open source. Hopefully that wouldn't stop me from getting what I need for my project at least if I have to do it myself.

Below is the board that I sort of started out with as a concept and adapted it to my needs.

https://www.whiteboxes.ch/shop/tentacle-t3-for-raspberry-pi/?v=7516fd43adaa

They do state it is open source.. "The Tentacle T3 for Raspberry Pi is Open Source Hardware (OSHW). Its schematic and pcb layout are licensed under Creative Commons Attribution-ShareAlike 4.0 International. The CAD sources will be available on GitHub once we ship."

Here is my hydroponics board early on in testing..

20180302_205154.jpg
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Cool that answers some of what I was looking for.

So is this open source PH board your talking about something different? or is that the pico board you are talking about?

Yeah I can't say that Altas is cheapest or best way to go all the time, but they do offer a flexible set of different probe interfaces which is handy in some situations.

I'm not sure if I would get in trouble making my board open source, since I sort of copied part of a different board that was out there? (it does say the T3 board I sort of borrowed from is open source) The board I have currently is meant for a hydroponics project that I didn't totally finish yet. I would of course adapt a new version to have more aquarium stuff to it. Also I am not sure how much time I could devote to making it really polished if it needs to be in order to be open source. Hopefully that wouldn't stop me from getting what I need for my project at least if I have to do it myself.

Below is the board that I sort of started out with as a concept and adapted it to my needs.

https://www.whiteboxes.ch/shop/tentacle-t3-for-raspberry-pi/?v=7516fd43adaa

They do state it is open source.. "The Tentacle T3 for Raspberry Pi is Open Source Hardware (OSHW). Its schematic and pcb layout are licensed under Creative Commons Attribution-ShareAlike 4.0 International. The CAD sources will be available on GitHub once we ship."

Here is my hydroponics board early on in testing..

20180302_205154.jpg
Nice . I have a tentacle board as well, I’m not using it actively, onlybtested it. It’s opensource, but it relies on atlas scientific Ezo circuits which is closed source and patented .
Pico board (by @theatrus ) and ph board (by @Roberto_b ) are both opensource , built for reef-pi (no reason it can’t be used with other software ) by reef-pi community . Both of these will go through extensive field testing in coming days as there are bunch of other people who have built/purchased it. We are working on the software support right now
 

geekengineer

Active Member
View Badges
Joined
Feb 10, 2019
Messages
427
Reaction score
538
Location
South Aurora
Rating - 0%
0   0   0
If it weren't too complicated maybe I could make a standalone dissolved oxygen sensor circuit instead. Sounds like its just a 0 to 47mV voltage measurement but not sure yet how high the source impedance is.
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Any news on the PCA9685 pwm settings?
Nope. Melanie sent a patch to fix the pwm thing which I merged and tested, but that didn’t fix the issue. I didn’t get time after that. I am yet to test out the patch from theatres on pi pwm
 

Zan101

Community Member
View Badges
Joined
Nov 3, 2018
Messages
69
Reaction score
17
Rating - 0%
0   0   0
Welcome to the development thread of reef-pi, an open-source, affordable, modular DIY reef-tank controller based on Raspberry Pi.

aio.jpg

If you are trying to build a reef-pi controller, please check out the build guides linked below. You can use this thread to seek help and to stay updated with the latest development.

Screen Shot 2018-11-04 at 8.38.50 PM.png



reef-pi provides following functionalities:
  • Equipment control or automated power strip (including digital timers to switch on/off equipment at periodic intervals)
  • LED light control (24 hour cycle), diurnal cycle, fixed dimmig
  • Auto Top Off (based on photoelectric water level sensor or float switch)
  • Temperature monitoring and control (switch on/off heater & chiller)
  • pH monitoring
  • Dosing automation
  • Macro (feed mode etc)
  • And several other features like camera controls (periodic image capture and upload on google drive), telemetry (dashboard and alerting based on sensor values using adafruit.io), mobile friendly UI etc.
A beginner friendly list of reef-pi build guides are available on adafruit.io, if you are planning to build a reef-pi controller start with them.
  1. Setup and installation
  2. Power controller
  3. Temperature controller
  4. Auto Top Off
  5. Light controller
  6. pH monitor
Since reef-pi is modular and customizable, the cost of individual builds varies. In our experience reef-pi controller are almost always cheaper than the commercial alternatives and costs anywhere between 100 to 550 USD. An example bill of materials can be found here as amazon list. If you are building a reef-pi controller, I highly encorage you start a build thread and tag it with #reefpi to seek help with your build


--------------------------- Original thread start ---------------------
Hello friends,
I am starting a master thread for a DIY reef tank controller that is based on all opensource software and hardware. I had started with this project with following goals:
- Build an opensource software and hardware based reeftank controller that anyone can use and hack
- Keep the controller well tested against a set of standard equipment I use, while make it possible for other equipment to be used
- Maintain my own tank build threads and their evolution, backed by this controller.
- Learn electronics and reef keeping along the way (I am biologist by education & software engineer by occupation)

Following are the details of what I have developed & tested till now:
Controller software:
- The main controller software is called reef-pi. It is written in go, its fast and performant. It used embd for hardware communication. It also runs a little web server which provides the UI for the controller. UI is written in React , and can be accessed from anything that has web browser. As of now, the reef-pi supports following things:
- AC 110/220 V socket on/off (uses optocoupled relays underneath). This is used to remotely switch on/off return pump, LED bulb, heater etc.
- 0-20 Volt DC PWM. This is used to control things like dimmable LEDs, DC pumps. I use it to control my Kessil A80, A360. As well as a 5V DC pump (i use it as wave maker in one of my pico with SPS). PWM is done using PCA9685 breakout board from adafruit. This board supports 16 channels. I am using only 5 at max, as of now.
- Analog sensor support using MCP3008 analog to digital converter. This supports 8 channels. i.e. I can use up to 8 sensors/probes. As of now, I have only tested temperature sensor with it.
Other than the following basic hardware/equipment support, the controller software provides following additional features:
- Setting up daily/weekly/monthly scheduled jobs. Like turning on/off certain equipment. I use this feature to run my AC20 HOB filter nightly.
- Setting up dusk-to-dawn like lighting using PWM. The UI gives 12 vertical slider based 0-24 hours (each slider representing 2 hours gaps). I combine two of these two control the kessil LEDs.
- Authentication using Google OAuth. Since the whole controller runs on raspberry pi and provides an web frontend, security of one of my concern. To mitigate this, I have added google authentication support, which when configured will allow only certain users to log in (email specified in the configuration value).

This is the summary of the core controller software and what features it has as of now. I am constantly writing/improving things around it. As of now, I have two reef tank powered by this. I 'll have seperate threads on the individual builds that will include the housing and ancillary hardware in nano-reef.com, as my tank build threads are there, but I'll share all the controller specific common bits here, including UI screen shots, and tank pics :)

20161115_081550.jpg
Great and helpful post. I've been thinking of doing this.
 

geekengineer

Active Member
View Badges
Joined
Feb 10, 2019
Messages
427
Reaction score
538
Location
South Aurora
Rating - 0%
0   0   0
I do have this thing I made to measure distance so in theory can use as a rough water level meter. It also has a ATtiny board on it so I can reliably calculate the distance and I convert it to a I2C interface. Only down side is I think I had to slow down the I2C bus for the ATiny to work as a slave properly. Anyways. Just thought I mention if its something nobody done before already and if you want to add something like this in the future to the software.

20180303_215807.jpg
 

dmolavi

Well-Known Member
View Badges
Joined
Jan 3, 2015
Messages
509
Reaction score
644
Location
United States
Rating - 0%
0   0   0
I do have this thing I made to measure distance so in theory can use as a rough water level meter. It also has a ATtiny board on it so I can reliably calculate the distance and I convert it to a I2C interface. Only down side is I think I had to slow down the I2C bus for the ATiny to work as a slave properly. Anyways. Just thought I mention if its something nobody done before already and if you want to add something like this in the future to the software.

20180303_215807.jpg

I was looking at doing one of these ultrasonic sensors, but backed off for a few reasons:
1. I have dogs. Don't need to be driving them insane
2. Accuracy at close range can be meh. I've seen some that claim to be accurate as close as a few inches, buuuuut I haven't seen any independent verification of that, and as an engineer, that's important to me.
3. Do I really need to know the level is 5 1/2 inches vs 6 inches? If not, I'm thinking a low level float switch is best for this. Or even a mid-level one to let me know it's "getting low".

@theatrus was working on a level sensor using differential pressure sensors. I like that idea the best of all...
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
I do have this thing I made to measure distance so in theory can use as a rough water level meter. It also has a ATtiny board on it so I can reliably calculate the distance and I convert it to a I2C interface. Only down side is I think I had to slow down the I2C bus for the ATiny to work as a slave properly. Anyways. Just thought I mention if its something nobody done before already and if you want to add something like this in the future to the software.

20180303_215807.jpg
I am very interested in adding support for this in reef-pi. I think this can be very helpful across ato or even dosing containers to validate the evaporation rate or dosing rate. We have to discuss as a community and settle on how best to leverage this (ui/ux)
 

geekengineer

Active Member
View Badges
Joined
Feb 10, 2019
Messages
427
Reaction score
538
Location
South Aurora
Rating - 0%
0   0   0
I was looking at doing one of these ultrasonic sensors, but backed off for a few reasons:
1. I have dogs. Don't need to be driving them insane
2. Accuracy at close range can be meh. I've seen some that claim to be accurate as close as a few inches, buuuuut I haven't seen any independent verification of that, and as an engineer, that's important to me.
3. Do I really need to know the level is 5 1/2 inches vs 6 inches? If not, I'm thinking a low level float switch is best for this. Or even a mid-level one to let me know it's "getting low".

@theatrus was working on a level sensor using differential pressure sensors. I like that idea the best of all...

Yeah it was just for a rough idea of how full/empty a supply tank is. I don't think it is not meant to be exact. The pressure sensor idea would be better if you have pets. I have cat's and they didn't seem to be bothered by the one I was using with @doughboy 's controller. So maybe Cats don't hear ultrasounds? or maybe it isn't loud enough? I have to post the design someplace if anyone is still interested. I think it might be easier to use a 3.3V version of the sensor, but I have to look at it again. I made a extra circuit that did the voltage translation to from 5V version I had.
 

dmolavi

Well-Known Member
View Badges
Joined
Jan 3, 2015
Messages
509
Reaction score
644
Location
United States
Rating - 0%
0   0   0
I am very interested in adding support for this in reef-pi. I think this can be very helpful across ato or even dosing containers to validate the evaporation rate or dosing rate. We have to discuss as a community and settle on how best to leverage this (ui/ux)

@Ranjib - Like I said, these ultrasonic sensors don't always have the best accuracy at close range (the ones that do are typically $$$). e-tape may be a better option, while more spendy than the lower-cost ultrasonic sensors, still less than the ones that are highly reliable at close range. My other concern with the ultrasonic ones is the exposure to moisture - condensation from the water evap, etc. ETape is also very low profile and can fit into almost any container...
 

bigcheese

Active Member
View Badges
Joined
Jan 31, 2019
Messages
161
Reaction score
314
Location
Saratoga Springs
Rating - 0%
0   0   0
e-tape may be a better option, while more spendy than the lower-cost ultrasonic sensors, still less than the ones that are highly reliable at close range. My other concern with the ultrasonic ones is the exposure to moisture - condensation from the water evap, etc. ETape is also very low profile and can fit into almost any container...
+1.
I just ordered that exact one from Adafruit yesterday. I took a couple of notes from an Aussie reefing forum, they've been using these for a while. The general consensus is it needs to be installed in a 1" pipe to keep flowing water from causing some unintended fluctuations.
 

crusso1993

7500 Club Member
View Badges
Joined
Oct 21, 2018
Messages
8,671
Reaction score
44,649
Location
SW, FL, USA
Rating - 0%
0   0   0
+1.
I just ordered that exact one from Adafruit yesterday. I took a couple of notes from an Aussie reefing forum, they've been using these for a while. The general consensus is it needs to be installed in a 1" pipe to keep flowing water from causing some unintended fluctuations.

Cool!
 

Just grow it: Have you ever added CO2 to your reef tank?

  • I currently use a CO2 with my reef tank.

    Votes: 8 6.0%
  • I don’t currently use CO2 with my reef tank, but I have in the past.

    Votes: 5 3.7%
  • I have never used CO2 with my reef tank, but I plan to in the future.

    Votes: 7 5.2%
  • I have never used CO2 with my reef tank and have no plans to in the future.

    Votes: 108 80.6%
  • Other.

    Votes: 6 4.5%
Back
Top