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

ColoredRock

Well-Known Member
View Badges
Joined
Aug 9, 2021
Messages
856
Reaction score
976
Location
Murrieta, CA (North of San Diego)
Rating - 0%
0   0   0

IronRising

New Member
View Badges
Joined
Jan 8, 2024
Messages
8
Reaction score
10
Location
Edmonton
Rating - 0%
0   0   0
Thanks guys, I had done most of what's on the Pi Hut list, but I just disabled my 5GHz band. It was named something else but couldn't hurt.

I also had my WIFI channel set to auto but changed to channel six. I updated the Raspbian watchdog to look out for internet drop outs and restart wlan0 if it detects nothing for 5 min. Hopefully these combos help without taking up to much CPU on the PI Zero.

Hopefully tomorrow morning the Pi is still on the network.
 

BenB

Active Member
View Badges
Joined
Jun 11, 2019
Messages
118
Reaction score
152
Rating - 0%
0   0   0
Hi All! I'm trying to setup a macro which turn off my main ATO when it detects that there's no water in the refill tank.
I've setup 2 ATO:
- Sump level check -> controls ATO pump
- ATO tank check -> controls a macro that turn on or off the Sump Level Check ATO

When I try to run a system like that the ATO freezes up and they don't do anything... I can't even turn on or off the ATO with the switches... What can it be?
Thank you!

Screenshot 2024-01-09 230925.jpg Screenshot 2024-01-09 230954.jpg
Somehow the macro gets triggered not just ones but all the time, so it gets in a loop, therefor it freezes. In the ato there is a field `one shot` that has been made for this situation. Maybe you will have to restart to make it work.
 

Simonv92

Active Member
View Badges
Joined
Oct 21, 2014
Messages
161
Reaction score
104
Location
Italy
Rating - 0%
0   0   0
Somehow the macro gets triggered not just ones but all the time, so it gets in a loop, therefor it freezes. In the ato there is a field `one shot` that has been made for this situation. Maybe you will have to restart to make it work.
Thank you! I'll give it a try! One shot mean that even if I set the macro as reversible I have to re-enable the ATO manually after the macro run right?

Edit: even if I set to one shot it doesn't work. Controller freeze...
 
Last edited:

Cpc83

Active Member
View Badges
Joined
Jun 9, 2021
Messages
176
Reaction score
182
Location
Willis
Rating - 50%
0   1   1
New to this not to the automation side of things though. I'm thinking of ditching my apex to go reefpi.

Can I monitor ph,temp, salinity and orp with reefpi?

Will reefpi test alk with a ph probe and dosing pumps like a hydros will?

What can I control as far as pumps and lights? Will it send 0-10v signals ?
 

BenB

Active Member
View Badges
Joined
Jun 11, 2019
Messages
118
Reaction score
152
Rating - 0%
0   0   0
Thank you! I'll give it a try! One shot mean that even if I set the macro as reversible I have to re-enable the ATO manually after the macro run right?

Edit: even if I set to one shot it doesn't work. Controller freeze...
Interesting, when I use an ATO to trigger a macro that triggers 2 types of equipment it works. Only you need to reset manually. And if I add an ATO in the macro and trigger the first ato, it freezes... Just like you experience. It can be a bug...
In an ATO you can not select an other ATO to controll either, only equipment, it looks like it is not setup for it. Maybe it can be added.
 

tedfisher496

Active Member
View Badges
Joined
Aug 29, 2023
Messages
264
Reaction score
117
Location
Belle Vernon
Rating - 0%
0   0   0
Part 2: Building the housing

reef-pi controller housings that I have built till now, is intended to provide an enclosure for the electronics, electrical outlets/inlets and a display for dashboards. I am really a novice at wood work, but this is the best I could think of during the first build..

First, calculate the minimum required dimension of housing. For my very first build, it was almost 1foot wide, 6" height, and 3" thick. I wanted ample place to play with different adapters & circuits inside. It was also due to 6 home electrical sockets, bolted in the bottom of the housing. Once you have the dimension sorted (you can go for much smaller housing if choose relay with less channel/ less electrical socket, as well as no display (they are 7" wide), cut the main sides. I choose to keep AC 100V outlets on bottom, BNC and 3.5 mm female connector mounted on right-bottom side. Couple of peristaltic pumps mounted on right-top side. Left side of the housing only has through hole, to pass the main AC input power supply. The front panel has only LCD screen mounted.
All of the electrical sockets are screwed in straight on the plywood. BNC connector and 3.5 mm female audio is mounted directly, they have groves already, I used a tap/drill tool to create the holes.
I used dremel rotary tool (3000) to cut out the spaces necessary to fit electrical outlets on the bottom, and peristaltic pumps on the right side.
Raspberry pi and pca9685 board is screwed on the back side of the front panel, with stand-offs in between. I have a small breadboard which holds the MCP3008 & L293D ICs, which is hot glued straight next to the pca9645 board. Couple of DC power adapters (5V for pi, and 10V for LED light) are directly screwed in (or ziptied) inside the housing.
Here are some reference images.
Front view of the housing.
20170215_203047.jpg

Electrical sockets in the bottom (6 of them)
20170215_203136.jpg

These sockets come in pairs, with hot & neutral ends connected in every pair. I break the hot end junction so that each socket can be controlled independently (I am pretty sure there is an elegant solution for this).
Wiring electrical sockets:
20170215_203131.jpg

Peristaltic pumps & 3.5mm female audio jack on right side of the controller
20170215_203154.jpg


Electronics, inside a fully functional reef-pi controller
20170215_203125.jpg

Notice the two DC power adapters, one one top left corner, another right next to the peristaltic pumps (right side).

Tools:
- Soldering iron
- Dremel saw and rotary tool (you can use anything you prefer to work with wood)
- Plyer
- Hot glue gun,
- Tap/drill set (to fix BNC connector, 3.5 mm female audio jacks)
20170212_201748.jpg


Bill of Materials
- Plywood
- standoffs
- 3.5 mm female audio jacks
- Female BNC connectors
- AC 110V Electrical sockets
- 14 gauge wires (green, black, white ) for AC 110V electrical sockets
- 16/18 gauge wires for DC 5v, 10v PWM (LED control, DC pump control)
- 20 gauge wires to connect sensors with MCP2008 (BNC connectors based sensors)
Is it possible to monitor current of each receptacle?
 

Simonv92

Active Member
View Badges
Joined
Oct 21, 2014
Messages
161
Reaction score
104
Location
Italy
Rating - 0%
0   0   0
Interesting, when I use an ATO to trigger a macro that triggers 2 types of equipment it works. Only you need to reset manually. And if I add an ATO in the macro and trigger the first ato, it freezes... Just like you experience. It can be a bug...
In an ATO you can not select an other ATO to controll either, only equipment, it looks like it is not setup for it. Maybe it can be added.
Thank you Ben for tour feedback. I'm also thinking about a bug. I know I can't control an ATO directly from another ATO. I was thinking I can do that with a macro.
It's the combination ATO which controls a macro which set an ATO ON or OFF that freeze the controller, if I control any equipment everything works just fine.
Maybe we can ask to @Ranjib if it's a bug or it's suppose to work like that..
Thank you!
 

IronRising

New Member
View Badges
Joined
Jan 8, 2024
Messages
8
Reaction score
10
Location
Edmonton
Rating - 0%
0   0   0
Hi All,

Looks like all 3 of the issues are fixed. Ill leave the solutions below in case it will help anyone else.

I am now able to access the Reef-Pi using Mixedreef.local after installing Apples mDNS. I used the Bonjour print service to install it. https://support.apple.com/kb/DL999?locale=en_US . So both the IP and the Local name works great.

Turning off my 5Ghz network and just running the 2.4Ghz now lets me access the Reef-Pi from any device. The Wifi's were named different things but i guess it was still causing issues.

The Pi did not lose connection last night for the first time after installing the Watchdog. Hopefully this keeps up. Set up of watchdog below. You can also have the watchdog monitor for Pi lock ups and force reboot. I have not set that up yet.

#Install and configure watchdog.

sudo apt-get install watchdog

# access watchdog conf file.

sudo nano /etc/watchdog.conf

# The below settings will set up Watchdog to monitor the internet for connection and restart the wireless if it detects no connection. These should be all be in the conf file and should just need to be uncommented. But these can be added anywhere.

interface = wlan0 # use interface wlan0 if Wifi and eth0 if lan
ping-count = 3 # how many times you want it to ping. I picked 3
ping = 192.168.***.*** # Pick which IP you want to ping. I picked my router.
interval = 300 # how many second in-between checks. I set mine to 300 which is 5 minutes

Hope this can help if needed.
 

Simonv92

Active Member
View Badges
Joined
Oct 21, 2014
Messages
161
Reaction score
104
Location
Italy
Rating - 0%
0   0   0
Another probably stupid question, in the ATO the Alert After is calculated in the hour (if in the hour it exceed the max second of use it will disable) or every single time the sensor trigger?
Thank you!
 

Sral

Valuable Member
View Badges
Joined
May 2, 2022
Messages
1,015
Reaction score
943
Location
Germany
Rating - 0%
0   0   0
Another probably stupid question, in the ATO the Alert After is calculated in the hour (if in the hour it exceed the max second of use it will disable) or every single time the sensor trigger?
Thank you!
It's not stupid at all, I fell over that as well ^^

It is cumulative and I think it only resets one re-enabling the ATO. So if the limit is 600s (e.g. you know your pump empties your ATO container in 600s), the alert triggers after 6 days when the ATO runs 100s every day.
 

Sral

Valuable Member
View Badges
Joined
May 2, 2022
Messages
1,015
Reaction score
943
Location
Germany
Rating - 0%
0   0   0
New to this not to the automation side of things though. I'm thinking of ditching my apex to go reefpi.

Can I monitor ph,temp, salinity and orp with reefpi?

Will reefpi test alk with a ph probe and dosing pumps like a hydros will?

What can I control as far as pumps and lights? Will it send 0-10v signals ?
Hi and welcome to this part of the forum !

You can absolutely monitor pH, Conductivity and ORP.
ORP is less common, but works no problem. you can even measure it with a pH board when you connect an ORP probe to it and transform the „pH“ value back to the measured voltage.

Alkalinity is a bit more difficult, but should work in principle as well. Do you by any chance know how that works ?
I’m thinking that it measures the pH drop after dosing specific chemicals and calculates the alkalinity from that ?

Control is a clear: yes. If you build for it you can output any signal, but 0-10V is a standard due to kessil interfaces, etc.

You can have a look at a more pre-build design at Robo-Tank (Canadian).
BTW @robsworld78, how is the sensor coming along ? :p
 

ColoredRock

Well-Known Member
View Badges
Joined
Aug 9, 2021
Messages
856
Reaction score
976
Location
Murrieta, CA (North of San Diego)
Rating - 0%
0   0   0
Last edited:

Sral

Valuable Member
View Badges
Joined
May 2, 2022
Messages
1,015
Reaction score
943
Location
Germany
Rating - 0%
0   0   0
Okay, thanks a lot !
Weirdly, the trident mentions that it doesn’t have a pH probe that requires calibration, so I guess it does have a colorating test liquid.
 

ColoredRock

Well-Known Member
View Badges
Joined
Aug 9, 2021
Messages
856
Reaction score
976
Location
Murrieta, CA (North of San Diego)
Rating - 0%
0   0   0
Okay, thanks a lot !
Weirdly, the trident mentions that it doesn’t have a pH probe that requires calibration, so I guess it does have a colorating test liquid.
Yes trident uses a colorimeter /titration method.. here is some info on the topic of dyes used.

 

ColoredRock

Well-Known Member
View Badges
Joined
Aug 9, 2021
Messages
856
Reaction score
976
Location
Murrieta, CA (North of San Diego)
Rating - 0%
0   0   0

DIY Raspberry Pi Colorimeter

 

Hugo_Fish

Active Member
View Badges
Joined
Oct 4, 2023
Messages
191
Reaction score
121
Location
Greensboro
Rating - 0%
0   0   0
I do not know if it was stated in the guide or the past, or blessed to some.. but what I'm telling you is from God, to me, to you ... If you are using the PH EZO board and the light on the top left is not Blue (if it is Green or changing from Green to Teal) then you are in UART. There is a way to change this in software or you can get a Switcher?(forgot what they call it..) but why waste money... when you can just short the board and sweat bullets you know what I mean? what is life without living once, I lived once .. and it was terrifying... To change this manually you will need to short the board. to do this, you will need to,

1. Put the EZO on one of the training Bread boards..forgot what they are called..
2. Plug ground into ground
3. Plug PGND to TX (from one side to the other.)
4. Supply 3.3v or 5v to the board.
5. When the light turns to Blue ground (pull the lever Kronk, WRONG LEVER!!)

take off the wire you are using to short PGND and TX and plug the ground back in. It should now stay Blue.

Congratulations, you are now in I2C.

The software should be able to see the EZO.. or you can be like me and forget to plug back in the SDA and the SCL.. -.-

By the way, the Hex will be set to a Default of 99. so when you set up the driver, most likely this is the address.

https://www.instructables.com/UART-AND-I2C-MODE-SWITCHING-FOR-ATLAS-SCIENTIFIC-E/ <--- other instructions

<--- This is a youtube reel if you want to see it in action.
 
Last edited:

Simonv92

Active Member
View Badges
Joined
Oct 21, 2014
Messages
161
Reaction score
104
Location
Italy
Rating - 0%
0   0   0
Hi, which sensor are you using to monitor your sump level? I've tryed the DFRobot SEN0205
but I'm having problems since the probes are not waterproof and when the return pump turn off the sensor will be fully underwater...
 

TOP 10 Trending Threads

Back
Top