Automatic aquarium controller

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
Hello.

I'm making plans for a project I would like to start after new year celebrations and I need help.

I want to create an automatic aquarium controller and I've already found a similar project I could use for guidance. Here it is: https://www.pcbway.com/project/shareproject/Automatic_Aquarium_Controller_fc3b443e.html

Before starting any project, I like to know some things that could affect my project to avoid them and be able to resolve them if they eventually occur.

What are some potential challenges or considerations that I'm to address when implementing a microcontroller-based system for controlling and monitoring multiple parameters in an aquarium environment, such as temperature, pH, and water level? How can I approach addressing these challenges, and what tools or techniques can I use to ensure the system is reliable and accurate in its measurements and control actions?
 

PaulEE

Joined Dec 23, 2011
474
Hello

Either everybody is busy today, or everybody is afraid to even open this can of worms with you :)
This is quite an undertaking, and usually a forum is for support, not design. I know you know that already, so I'll answer your question

1. If you sit down to do a project and paralyze yourself trying to figure out every single thing that will go wrong first, you may as well forget starting the project...but I get it, I try to do that. Sometimes you don't know what you don't know, though.

2. If you have a lot of fish and the thing malfunctions, they die. This happens when the temperature is too high or low, pH to high or low, etc. So, to answer your question on the tail end of your initial query, I would say that the most important thing is to learn exactly how each of the sensors works that you intend on using, and make sure they measure accurately WHAT you need them to measure. Proper measurement of pH, for example, is, by itself, rather sophisticated and usually expensive. If you find a sensor that claims 1% accuracy for $3 on eBay, I guarantee you that your fish won't last long...as an example.

3. These parameters (well some) you list depend on one another to an extent. The pH may read differently at different temperatures, for example. Again, you have to write software that deals with all of these real-world circumstances...it has to know the "transfer functions" so-to-speak of the sensors...which themselves will vary sensor-to-sensor, even with the same part number.

4. After you have all that worked out, you need to program in the logic that will juggle it all and tweak each of these parameters. This may involve running heating or cooling elements, turning lights on and off, adjusting oxygen levels, a dosage pump for the pH goop...the list literally goes on and on.

5. I would seriously pick a different new year's project. To do this right is immensely complicated.

I don't mean to discourage you, but I just want you to understand what you're signing up for here.

Since you'll do it anyway, though, be sure to use a watchdog timer to reset the software when the microcontroller gets stuck in the aether somewhere (forever loop, unhandled exception situation, etc.) and make sure it directly handles ALL EVENTUALITIES, not just the convenient ones you think of off the top of your head. You should be thinking "what would break this, and will it ever happen?", and if you ever say "that won't happen" to yourself, DEFINITELY make sure you're covered for that, because it always does.

Paul
KI5VNH
 

camerart

Joined Feb 25, 2013
3,730
Hello.

I'm making plans for a project I would like to start after new year celebrations and I need help.

I want to create an automatic aquarium controller and I've already found a similar project I could use for guidance. Here it is: https://www.pcbway.com/project/shareproject/Automatic_Aquarium_Controller_fc3b443e.html

Before starting any project, I like to know some things that could affect my project to avoid them and be able to resolve them if they eventually occur.

What are some potential challenges or considerations that I'm to address when implementing a microcontroller-based system for controlling and monitoring multiple parameters in an aquarium environment, such as temperature, pH, and water level? How can I approach addressing these challenges, and what tools or techniques can I use to ensure the system is reliable and accurate in its measurements and control actions?
Hi A,
My last aquarium was an average house hold one, with only a heater and airpump, and they all lived happily till I wen on holiday, and let a mate of mine look after them in his tank, and they all died.

Anyway, your project looks good, but if your fish are valuable, then I would perhaps have a separate backup alarm circuit that monitors the first.
C.
 

Sensacell

Joined Jun 19, 2012
3,453
I see dead fish and wet floors in your future.

Long ago, I was managing a team of designers and one guy argued that he didn't need to worry about his lead screw mechanism going beyond the limits and smashing things to bits because "it was under computer control"

The moral of the story is that in developing stuff like this, everything will go wildly wrong hundreds of times before it ever works once the correct way.

Keep your fish out of harms way.
 

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
Hello

Either everybody is busy today, or everybody is afraid to even open this can of worms with you :)
This is quite an undertaking, and usually a forum is for support, not design. I know you know that already, so I'll answer your question

1. If you sit down to do a project and paralyze yourself trying to figure out every single thing that will go wrong first, you may as well forget starting the project...but I get it, I try to do that. Sometimes you don't know what you don't know, though.

2. If you have a lot of fish and the thing malfunctions, they die. This happens when the temperature is too high or low, pH to high or low, etc. So, to answer your question on the tail end of your initial query, I would say that the most important thing is to learn exactly how each of the sensors works that you intend on using, and make sure they measure accurately WHAT you need them to measure. Proper measurement of pH, for example, is, by itself, rather sophisticated and usually expensive. If you find a sensor that claims 1% accuracy for $3 on eBay, I guarantee you that your fish won't last long...as an example.

3. These parameters (well some) you list depend on one another to an extent. The pH may read differently at different temperatures, for example. Again, you have to write software that deals with all of these real-world circumstances...it has to know the "transfer functions" so-to-speak of the sensors...which themselves will vary sensor-to-sensor, even with the same part number.

4. After you have all that worked out, you need to program in the logic that will juggle it all and tweak each of these parameters. This may involve running heating or cooling elements, turning lights on and off, adjusting oxygen levels, a dosage pump for the pH goop...the list literally goes on and on.

5. I would seriously pick a different new year's project. To do this right is immensely complicated.

I don't mean to discourage you, but I just want you to understand what you're signing up for here.

Since you'll do it anyway, though, be sure to use a watchdog timer to reset the software when the microcontroller gets stuck in the aether somewhere (forever loop, unhandled exception situation, etc.) and make sure it directly handles ALL EVENTUALITIES, not just the convenient ones you think of off the top of your head. You should be thinking "what would break this, and will it ever happen?", and if you ever say "that won't happen" to yourself, DEFINITELY make sure you're covered for that, because it always does.

Paul
KI5VNH
Wow Paul, thank you.

I guess I'm just an overthinker and a tad bit of a perfectionist. I don't like things going wrong and I sometimes fail to understand that it's normal when it comes to what we do.

I'll take note of everything you've said. I'm truly grateful.

Also, I guess you're right this might not be the best project to start the new year with. I'll just do something easy instead and work on this project once I'm done with that.
 

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
Hi A,
My last aquarium was an average house hold one, with only a heater and airpump, and they all lived happily till I wen on holiday, and let a mate of mine look after them in his tank, and they all died.

Anyway, your project looks good, but if your fish are valuable, then I would perhaps have a separate backup alarm circuit that monitors the first.
C.
Ouch! That's pretty sad.

Thank you. I'll add that as I have some valuable ones I wouldn't want to risk dying.
 

twohats

Joined Oct 28, 2015
447
I would suggest that you start small.
If you are not familiar with microcontrollers, get one, learn how to use it simply, to start with.
Then you can work on monitoring temperature & acidity etc.
When you are satisfied they are working OK, you can expand.
Lots of info on the 'net.
Lots of help on this forum.
Good luck.......
 

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
I see dead fish and wet floors in your future.

Long ago, I was managing a team of designers and one guy argued that he didn't need to worry about his lead screw mechanism going beyond the limits and smashing things to bits because "it was under computer control"

The moral of the story is that in developing stuff like this, everything will go wildly wrong hundreds of times before it ever works once the correct way.

Keep your fish out of harms way.

I guess this project idea was a terrible one then because I love my fishes so much.

Thank you for the advice.
 

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
I would suggest that you start small.
If you are not familiar with microcontrollers, get one, learn how to use it simply, to start with.
Then you can work on monitoring temperature & acidity etc.
When you are satisfied they are working OK, you can expand.
Lots of info on the 'net.
Lots of help on this forum.
Good luck.......
I'm familiar with microcontrollers. I guess I can be a skeptic sometimes. Just wanted to know the possible challenges I could face with this project. But thank you.
 

Janis59

Joined Aug 21, 2017
1,849
Temperature control, oxygen control, food add-in control, water level control, acidity/alkalinity control, etc etc, means the local automat is too complicated solution. Instead what You need is "Arduino compatible" for 0.99 USD per piece, and bunch of UIO what half are sensor bound and another half actuator bound.
 
Last edited:

GetDeviceInfo

Joined Jun 7, 2009
2,196
Hello.

I'm making plans for a project I would like to start after new year celebrations and I need help.

I want to create an automatic aquarium controller and I've already found a similar project I could use for guidance. Here it is: https://www.pcbway.com/project/shareproject/Automatic_Aquarium_Controller_fc3b443e.html

Before starting any project, I like to know some things that could affect my project to avoid them and be able to resolve them if they eventually occur.

What are some potential challenges or considerations that I'm to address when implementing a microcontroller-based system for controlling and monitoring multiple parameters in an aquarium environment, such as temperature, pH, and water level? How can I approach addressing these challenges, and what tools or techniques can I use to ensure the system is reliable and accurate in its measurements and control actions?
Initially, I would begin such a project with monitoring functions, learning what and where fluctuations occur through normal tank maintenance.
Consider the difference between two designs to see what could go wrong.
Scenario 1 - a water change system consists of a separate tank that provides overflow to drain, a solenoid supply over float valve. Temperature control, ph sensor, air agitator, chemical dosing pump, anti siphon discharge pump. Water is filled, air agitated and brought to temp (day 1). Ph incrementally adjusted (day2 &3). Seasoned water pumped to aquarium with overflow capability.
Scenario 2 - water solenoid valve with inline ph dosing to tank with siphon discharge.

A well planned aquarium has ‘buffering’ capacity, which reduces shock and harmful conditions. Monitoring to understand, out ways controls which suggest the operator can forgo responsibility.

Plants are not that different in there complexity of needs. The cannibis industry is a healthy consumer of controllers. Maybe look there.
 

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
Initially, I would begin such a project with monitoring functions, learning what and where fluctuations occur through normal tank maintenance.
Consider the difference between two designs to see what could go wrong.
Scenario 1 - a water change system consists of a separate tank that provides overflow to drain, a solenoid supply over float valve. Temperature control, ph sensor, air agitator, chemical dosing pump, anti siphon discharge pump. Water is filled, air agitated and brought to temp (day 1). Ph incrementally adjusted (day2 &3). Seasoned water pumped to aquarium with overflow capability.
Scenario 2 - water solenoid valve with inline ph dosing to tank with siphon discharge.

A well planned aquarium has ‘buffering’ capacity, which reduces shock and harmful conditions. Monitoring to understand, out ways controls which suggest the operator can forgo responsibility.

Plants are not that different in there complexity of needs. The cannibis industry is a healthy consumer of controllers. Maybe look there.
I'm truly grateful for this.
 

Thread Starter

AmeliaGrey

Joined Dec 30, 2022
19
Temperature control, oxygen control, food add-in control, water level control, acidity/alkalinity control, etc etc, means the local automat is too complicated solution. Instead what You need is "Arduino compatible" for 0.99 USD per piece, and bunch of UIO what half are sensor bound and another half actuator bound.
Thank you!

bunch of UIO what half are sensor bound and another half actuator bound.
Where can I get them?
 

Tonyr1084

Joined Sep 24, 2015
7,905
Monitoring water conditions in an aquarium (or pond like I have) doesn't need to be done constantly. My pond - I check the chemistry levels three times a year. After winter when I start feeding them again, mid summer, and just before the next winter. The best fix for all my problems is fresh water. I usually end up pulling the stones out of the pond and pressure washing them to get rid of the algae that has grown due to sunlight. I DO put an algicide in once or twice a year but my filter has three different screens which need to be cleaned monthly. Then there's biota (bacteria living on ceramic cylinders) inside the filter. The final part of the filtration is ultraviolet light. That does an excellent job of maintaining proper chemistry. Unfortunately I learned the importance of monitoring chemistry a few years ago when my fish began acting erratically, crashing into things deliberately. They were in ammonia distress. The UV had failed and I wasn't monitoring the water condition. I lost two fish. One goldfish that had been in the pond for five years and was the big boss of the pond. A newcomer, a coy also perished. Fortunately I got the rest of them out of the pond and did a complete restore, draining the pond, pressure washing everything and starting over with fresh water.

My tap water is laden with hardness. I could get a water softener to remove a lot of the minerals, but that's a big expense. Especially when simply vacuuming the gravel at the bottom of the pond will remove a lot of the waste materials that lead to these negative issues. Of course vacuuming means drawing water out of the pond, but then replacing that water with fresh tap water (or rain water if I ever get my rain barrels hooked up) make caring for the whole pond a lot easier.

As for your aquarium - changing 1/3 of the water monthly will usually keep everything well within acceptable ranges for your fish. Your aquarium will thrive. A simple chemistry kit will help you monitor the conditions and let you know when you've waited too long to address the health of the water.

You don't say how big your tank is, nor did I see any mention of what kind of fish you have. My pond is 105 gallons at present and I have plans for a much larger pond in the near future. Hopefully this spring. However, I have other projects that need to be addressed before I embark on a frivolous pond project. But it's one I'd like to get to. The filtration system will have to be bigger, and the UV system will need to be more robust as well. I've given that some thought but haven't made any serious plans. But the circulating pump will have options for recirculating and filtering the pond water OR ejecting water to make room for fresh water.

I wish you well with your project. For now I like the "KISS" principle. Though some say it "Keep It Simple Stupid" I prefer the "Keep It Stupidly Simple" version. More friendly and less degrading.
 
Top