EntropySink

Entertainment & Artistry => Sports/Outdoors & Manpoon => Topic started by: Mike on May 20, 2020, 10:17:04 AM

Title: Monitoring my hydroponics
Post by: Mike on May 20, 2020, 10:17:04 AM
Decided to geek out this year and keep data on my hydroponics.  Since the beginning I've been measuring how much water and nutrients I've been adding.  I've also set it up to track the harvest weights of the tomatoes (which hasn't started yet).

Due to some power loss during the rain storms in April I hooked up a Raspberry PI to log every 5 minutes and put it on the same circuit.  That way if the power went out I'd know (by it not being responsive) and when (because of the log).

Last week I decided to step it up and add some sensors.  Ended up buying some water proof temperature probes and building a simple circuit to have them read by the Raspberry PI.  I've got a humidity sensor as well but it is causing a major voltage drop that kills the Pi so am waiting for the new Raspberry PI 4 to arrive and will try again with that.   I've also got a pH probe coming that I'll put in the tomato set up.

I have a simple webserver running on the Pi that serves up the data as a HTML table for the last 100 readings and a CSV export of all of them.  I then set up port forwarding on my router so that I can use the IMPORTDATA function in Google Sheet to load and graph the sensor data.

Interesting thing is that the tower has 20 plants (mostly herbs but some flowers) and the box has two tomato plants.  The tomatoes are out drinking the tower by a lot.

Title: Re: Monitoring my hydroponics
Post by: Mike on May 22, 2020, 11:59:59 AM
I think I need to put my air probe in a protected case as it is kind of swingy and I think it is because it does get some sun.
Title: Re: Monitoring my hydroponics
Post by: Mike on May 24, 2020, 09:33:07 PM
Added a pH sensor to the tomato box today.  After letting it settle it was reading 7.5 which is higher than I want it.  So added some acid the the thing swung around for a couple of hours as it got mixed in.  Settling in just over 6.5 so will probably add a bit more later.  I'll add a graph in a few days once I have more readings on it.

I was going to take some pictures of the setup by I'm honestly a little embarrassed in how much my (limited) soldering skills have degraded.  And, I'm not quite happy with the setup.  I have jumpers going to a solder breadboard.  I think the next thing I'll do is make a HAT for the Raspberry Pi and get a different enclosure (the current one is really tight).  And made some surface solder mats for some of the cables so I can attach cable connectors.
Title: Re: Monitoring my hydroponics
Post by: KnuckleBuckett on May 25, 2020, 09:40:57 AM
I find the modern solders and fluxes to be pretty awful.
Title: Re: Monitoring my hydroponics
Post by: Mike on May 26, 2020, 01:17:32 PM
I'm pretty confident when I say that the quality of the solder is not to blame.
Title: Re: Monitoring my hydroponics
Post by: KnuckleBuckett on May 27, 2020, 06:02:22 AM
HA!  I have enough old school supplies to keep me in business personally for decades to come.  Heck. I really don't solder much anymore and it is a skill that needs practice.
Title: Re: Monitoring my hydroponics
Post by: Mike on May 27, 2020, 10:11:22 AM
Well, then maybe I'll send you the PCBs for soldering once I get them printed ;)
Title: Re: Monitoring my hydroponics
Post by: Mike on May 27, 2020, 10:14:07 AM
So, going through a heat wave right now.  And every time I add water it raises the pH (while water is neutral pH I have a feeling my water might be a bit basic [/snap]) so it has been a struggle to keep the pH where I want it.  But, it also reduces the water temperature which is good.
Title: Re: Monitoring my hydroponics
Post by: Mike on May 29, 2020, 08:29:22 PM
Getting a lot of water loss from my tomato box now.  The water is being sprayed on the lid and traveling along it to drip out.  Getting an air pump and air stone and going to replace the pump with that.

One the PCB front I'm debating whether to get the current board printed or go to version 2.

(https://i.imgur.com/IYgr2nh.png)

Looking to put another EZO port on there so I can either hook up a second pH probe or a different type of probe.  And going surface mount for some things.
Title: Re: Monitoring my hydroponics
Post by: KnuckleBuckett on May 30, 2020, 08:21:32 AM
What else would you like to add?
Title: Re: Monitoring my hydroponics
Post by: Mike on May 30, 2020, 10:33:23 AM
The nice thing about those EZO boards is that you can put a bunch of different probes and control boards on them and they are still the same interface.  Also learning how much hydroponics is a engineers dream. So much you can measure and account for if you want.

So for future expansion I'd add another of those.  I've already got additional 1-wire connections.

Priced it out and a 2 layer board is insanely cheap.  So may just get this one printed and work on V2 later.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 01, 2020, 08:58:39 PM
Well, now I've bought a EC probe.  But, didn't do the fully isolated daughter board.  And I think I'll go with that for both in the future.  Saves a lot of room.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 01, 2020, 08:59:35 PM
And all that I just found this: https://www.atlas-scientific.com/kits/wi-fi-hydroponics-kit/

Not cheap but probably cheaper than what I've spent so far.  Oh well, need some hobby I guess
Title: Re: Monitoring my hydroponics
Post by: Mike on June 04, 2020, 12:02:09 AM
I'm finishing up version two.  Going with a 4 layer board to make life easier.  I put version 1 p for review on reddit and got some feedback to add some decoupling capacitors to the EEPROM but I honestly have no idea how to size those and I don't feel like doing a ton of math for this hobby project.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 05, 2020, 12:12:04 AM
Going with the 4 layer version 2 using through-hole only.  The surface mount stuff was hurting my brain too much.

Order placed to print it.  $7 for 5 boards (only need 1 but min order is 5) and then like $30 for the shipping.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 08, 2020, 10:53:15 AM
It is interesting what you learn when you start monitoring things.  So, the pH has been slowly and steadily falling for the last 5 days.  It might adjust up when I add water and nutrients but there is definitely a trend.  Well, reading up on it it sounds like I have too much nutrients in the water and the plants are taking up more water than nutrients so the concentration of nutrients (which are acidic) is increasing and driving the pH down.  Took my fancy new conductivity probe out there and sure enough it is too high.  So, this morning added just water.  Will be interesting to see what happens.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 10, 2020, 03:32:19 PM
Caught a squirrel eating one of my unripe tomatoes.  None of them have ripened yet so he got it before I got any.

Cheeky bastard is lucky I like squirrels!
Title: Re: Monitoring my hydroponics
Post by: Mike on June 17, 2020, 02:55:53 PM
The first generation of the PCBs are here.  Got most of it set up.  Just need to disassemble the current setup and desolder it.  For the PCB I'm doing things are headers and connectors so hopefully no more desoldering.  Really glad I got 5 boards as the first one I fucked up by soldering the header on upside down (it is the only component with the solder side on the top).

More importantly, the first tomatoes are here!

(https://lh3.googleusercontent.com/Lp1vz4HsY512oTeVcy7R4CTKQVY5BOCz34Kxk4mFhBhUkmOm2H-sHVXq2sxAs1N1mLTlsfOJUs4p_3USgELzMHqhf8OgIFlzTpNOwtAI30y-Lwm7MwtmRrzFLF0m_Nj5ADh6SgeH2_Q=w640)
Title: Re: Monitoring my hydroponics
Post by: Jake on June 17, 2020, 03:57:35 PM
The first generation of the PCBs are here.  Got most of it set up.  Just need to disassemble the current setup and desolder it.  For the PCB I'm doing things are headers and connectors so hopefully no more desoldering.  Really glad I got 5 boards as the first one I fucked up by soldering the header on upside down (it is the only component with the solder side on the top).

More importantly, the first tomatoes are here!

(https://lh3.googleusercontent.com/Lp1vz4HsY512oTeVcy7R4CTKQVY5BOCz34Kxk4mFhBhUkmOm2H-sHVXq2sxAs1N1mLTlsfOJUs4p_3USgELzMHqhf8OgIFlzTpNOwtAI30y-Lwm7MwtmRrzFLF0m_Nj5ADh6SgeH2_Q=w640)

they look delicious - what variety is it?
Title: Re: Monitoring my hydroponics
Post by: Mike on June 17, 2020, 04:19:28 PM
Sweet 100 (https://bonnieplants.com/product/super-sweet-100-tomato/)

We also have some some Cherry Red Tomato (https://bonnieplants.com/product/husky-cherry-red-tomato/) just about ready (they are red but didn't want to come off the vine yet).
Title: Re: Monitoring my hydroponics
Post by: Mike on June 18, 2020, 02:14:21 PM
I'm really being drawn towards https://www.atlas-scientific.com/peristaltic/ezo-pmp/. Could (in theory at least) use it to pump water, nutrients, and even pH buffer in as needed.

https://www.youtube.com/watch?v=7zcp5zvE7EA&feature=emb_logo

Title: Re: Monitoring my hydroponics
Post by: KnuckleBuckett on June 18, 2020, 09:29:03 PM
Peristaltics are a pain in the ass to calibrate because as the tubing ages the calibration varies.  Until failure.  Though not used as calibrated devices I deal with quite a few of them.  We replace maybe 40 a year and retube 3x that.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 18, 2020, 11:23:07 PM
What are you using them for?  At $80 a pop I would like them to last more than a year.
Title: Re: Monitoring my hydroponics
Post by: KnuckleBuckett on June 19, 2020, 06:03:03 AM
Water removal from drying systems.  Ours are $400 each. 
Title: Re: Monitoring my hydroponics
Post by: Mike on June 19, 2020, 11:51:48 AM
Hmmm, maybe I'll just get one to start with then.  I'm not too concerned with precise amounts every time.  Though, the nutrients are a two solution mix so it'd be nice of they both dispensed the same amount.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 19, 2020, 04:54:39 PM
Here is this morning's haul with the second type of tomatoes

(https://lh3.googleusercontent.com/71mTTkrBYSzioH1NJHpqn_Y1reSqixfMAgArdy5_MyVT2iVObZ4bITpdFbciHzJTmQalZCJXCbsiK2b0uD-ZdUIqdqahXixbwrB0tT6lhBs5LH8QIkZesTMbZMvZwWoOEAr4AM-igsI=w640)
Title: Re: Monitoring my hydroponics
Post by: Mike on June 21, 2020, 12:37:50 AM
So, was all excited to convert the setup to the new PCB and connectors.  Pulled the old setup down, took everything part, unsoldered headers, resoldered new ones, converted direct soldered wires to crimped connectors, etc.  Get everything done, connect it to the Raspberry Pi 4 and the thing won't boot up.  Pull things off, and undo all the new stuff and no luck.  Going through the troubleshooting and it is pointing to the SD card being bad.  Which means I'm losing all the data I had (I hadn't gotten to remote backing it up :mad:)  And of course everything is closed.  So, ordering a new card for pickup tomorrow.  Hopefully it'll work.  Still hoping that I might be able to pull data off the old card but not in high hopes
Title: Re: Monitoring my hydroponics
Post by: Mike on June 21, 2020, 02:00:27 PM
Got a new card, put the OS on it, and the PI booted right up.  Which is good but probably does mean the old card is shot.  Might see if I can't mount it or use a repair utility.

Gonna set up a Windows share and have it dump the database to it as a backup.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 21, 2020, 03:50:22 PM
Well, it looks like my soldering skills aren't that great.  The daughter board that I pulled the existing headers off of and put new headers are has a short between Vcc and ground.  Likely, I already had a replacement on its way.  But it won't be here until Friday.  So, probably just going to put it back together with the existing components and then next weekend add the new sensor.
Title: Re: Monitoring my hydroponics
Post by: Mike on June 28, 2020, 10:04:54 AM
Made an album of the change over work.  https://photos.app.goo.gl/NaPJyipcycshSo366

Some lessons so far:

At this stage my frustration level is at an all time high.  After adding the new isolation board all three of the temperature probes came loose and after getting them back on two are reporting max temperature.  Debating pulling everything out and just doing this next season in a new set up.  Thinking about a system where the maintenance area is set away from the main basin with something to keep the roots out.  Then having some probe areas there so they are clean and easy to access.