A Reef-Pi that can run up to 8 dosing pumps

Jhollowell41

New Member
View Badges
Joined
Oct 31, 2018
Messages
18
Reaction score
34
Location
North Carolina
What state or country do you live in
North Carolina
Rating - 0%
0   0   0
I’ve been following Reef-Pi since late October 2018 when I started my planted freshwater tank. I had been looking for a controller system and luckily found Reef-Pi. I have no coding experience and very limited knowledge of electronics. I spent last winter season “dabbling” with Raspberry Pi’s and getting into home automation so this project was right up my alley!!

This post gives a very brief explanation of my main controller build but you can skip to my second post to see how I build a separate “Dosing-Pi” to control up to 8 different pumps with one system.

After accumulating the basic parts, I completed my initial build in early December 2018. It has been running flawlessly. I am currently running a Pi3b+ and on Reef-Pi version 2.2.

I followed the build guides for the basic set up along with the power controller and temperature controller. I kept the power controller build simple by using the recommended SRP8 power strip which I use to control my lights (simple on and off), CO2, and heater control. I also have my filter connected to the SRP8 as I have built a Macro that shuts things down for water changes and another that turns everything back on.

I have 2 temperature probes, one for the aquarium temperature and the other for ambient room temperature monitoring. The temp probe for the aquarium was coated with liquid electrical tape (black) mostly to disguise the probe against my black background. I used 3-prong aviation connectors for the temp probes like these and have worked well.

I currently have not built the pH probe portion but is in my plans.

I have been investigating dosing pumps. The current build guide for dosing pumps only allows for 2 pumps for each Reef-Pi build. With my plans, I would need 5 pumps to dose 5 different fertilizer components separately, that would mean I would have to build 3 different systems to do this. I started by building 2 separate systems (controlling 4 pumps) to play with but also started to investigate how to utilize the PCA9685 board to have the ability to control more than just 2 pumps with one Reef-Pi build, however I was not able to accomplish this. I then had an idea at 3:00am last week of an alternative way which I will outline in the next post.
 
As an eBay Associate we earn from qualifying purchases.
I started my dosing system build by following the dosing controller guideby Ranjib. Other than adding a few pins for connections (which I explain below), I followed his guide to the letter. I am currently using a Pi 3b+ but plan to convert to one of my Pi Zero W’s once I finish my testing and determine how I am going to house it.

I used an 8-channel relay I had on hand. I soldered pins to GPIOs (circled in red in pic), I only needed to solder in 8 but ended up with one extra. You may notice that I also have pins soldered in the SDA and SCL spots, I was using this board to try to get the PCA9685 to do the job but could not, you will not need these pins for this build. I also added some pins to the 5v power section (circled in orange)

upload_2019-2-28_20-23-56.jpeg
 
Last edited:
I use the left terminal on channel 8 (far left relay in pic above) to connect to the right pin on the proto board that is normally used to connect to a pump (below).
upload_2019-2-28_20-28-53.jpeg
 
The orange and green wires (above) are connected to the GND and VCC pins on the relay board and 5v and GND on the proto board. Below you will see grey and white wires connected to the 5v and GND pins on the proto board and to the GND and JD-VCC pins on the relay board. I am not sure if this is needed, I have done this with other home automation projects following other people’s guides and this was required, all I can say is it works with this build and I have not tried it without these connections. Someone else can probably provide an explanation.
upload_2019-2-28_20-30-40.jpeg
 
Back to the relay board. Connect the center terminal (yellow arrow below) for each of the channels you are using to the (+) terminal on each pump.
upload_2019-2-28_20-31-15.jpeg
 
The (-) terminal on each of the pumps will be connected to one of the pins below (circled in green). I only have 4 connected in the pic, I have a 5thpump on the way and will be connecting it as soon as I receive it. Notice the pin with the green arrow below isn’t connected, with the way I constructed the extra wiring and pins, I did not use this pin (but you could).
upload_2019-2-28_20-31-55.png
 
Also use the Reef-Pi Controller build guide for configuration and testing. In addition to the build guide I did the following.

I added an “Outlet” for each of the relays that I am using on the 8-Channel relay board. In the pic below, I only used 5 channels. I also completed the GPIO pin assignment and you have to check “reverse” in the set up in order for the “equipment” switch to work properly
upload_2019-2-28_20-33-10.png
 
I then configured the “Dosing Pumps” so that all pumps would use Jack J0 and Pin 0 and created a different name for each instance per day that each would be dosed. In my case, I am only going to dose each once per day. Even though I am using the same “Jack” for each of the pumps, I can calibrate each differently as needed to deliver the dose I want. See pic below.
upload_2019-2-28_20-34-25.jpeg
 
The settings above for duration and speed I am only using for testing purposes. I will do proper calibration once I have completed the housing process and the final set-up.

Now to explain how it all works. For each pump: You have to create a “Timer” to turn on each of the relays at different times, you cannot have 2 relays “on” at the same time. You then would have the same corresponding “Dosing Pump” to come on during the time that the relay is on. I also set the “Timer” to be a little longer than the actual pump run time before the relay shuts off. For example, If I set a “Timer” for the “Nitrogen Pump” to come on at 20:30 (8:30pm), I then have it set to turn off after 30 seconds (for testing purposes) but will change the off time after I have completed the calibration process and determine how long the pump needs to run for proper dose. The off time for the “Timer” will be a litter longer than the proper dose time.
upload_2019-2-28_20-35-6.png
 
Next, I set the “Dosing Pump” for nitrogen to start 5 seconds after the “Timer” for the nitrogen pump. The duration and speed in the pic below are just for testing but the duration should end before the “Timer” for the nitrogen pump shuts off the relay.
upload_2019-2-28_20-35-40.jpeg
 
I then allow for a brief pause before I set the next “Timer” to turn on a different relay and then repeat the process for each pump. The key thing to remember is to not allow for more than one relay switch to be “on” at the same time.

Because I am using the original proto board design, I have the capability to control each pump by calibration as well as reversing the direction if I need.

My initial plans for the housing will be to have 4 pumps in 2 different enclosures with each enclosure just large enough to hold the 4 pumps (2 boxes with 4 pumps each). I will have a 3rdenclosure that will house the electronics. I plan to use 8-pin aviation connectors like theseto connect the electronics to the pumps. I am having a problem finding an enclosure for the pumps that would meet my specifications as I would like to be able to have it hang on the back of the tank. It would need to be approximately 12”x4”x2.5”.

I sure hope this was explained simple enough for everyone. By the time I finished this build I realized you could probably use the PCA9685 instead of using the GPIO pins but what I have works and I will let someone else investigate that.
 
As an eBay Associate we earn from qualifying purchases.
@Jhollowell41 - explained very well and thanks for supplying the pics too!

Looking forward to how your finished project will look!

Oh, there are a number of Reefers that are also FW people too. I include myself in that statement. :)
Can you post some pics of your FW tank and equipment?
 
Very nice.. this is awesome. This is pretty much the dosing tab, but implemented via relay's and timers. I like this. What the dosing tab allows (variable voltage) can be achieved here as well by adjusting the lm2586 (assuming the relays are controlling dc pumps)

Thank you for sharing #reefpi
 
IMG_1647.JPG

54 gal corner bow front. Still cycling.

IMG_1649.JPG

Nice set up! Which regulator you running? And lights? Always interested in the lights! Lol
BTW - you plan on mounting the reef-pi to the wall so as to get if off the base/floor?
 

IF YOU HAD TO TAKE A REEFING EXAM, WOULD YOU PASS?

  • Yes!

    Votes: 32 45.7%
  • Not yet, but I have one that I want to buy in mind!

    Votes: 9 12.9%
  • No.

    Votes: 26 37.1%
  • Other (please explain).

    Votes: 3 4.3%
Back
Top