Okay. Sounds like you get to be this projects connection&communications chief officer (or you can make an even fancier title if you like)
On that note, should we try to formalize the who-does-what? Would making issues in Git work for you?
Okay. Sounds like you get to be this projects connection&communications chief officer (or you can make an even fancier title if you like)
On that note, should we try to formalize the who-does-what? Would making issues in Git work for you?
Putting everything in github would be good. A BOM, a wiring diagram. I was thinking of dping the wiring diagram tomorrow.
I have little experience with Github but I’m sure I could work it out.
Yes having a schematic would help to know which pins are being used. In the code I’m just putting in the pins I used. I don’t have your hardware. I don’t have any sort of water sensor.
I have 3 switches. A software reset switch as I don’t have external switch and 2 motor switches. I have set the motor switch to not run for more than 400s.
In the initial stages sometimes I couldn’t turn the pump off and it would pump out 20L before I got to it. I pump to 4 pots which have drainage holes.
60 seconds might be better for an individual pot. When you run the pump you will need to measure how much water it pumps in a given time. The normal watering time is controlled by MQTT via a script. Easier to adjust a script in HA than reflash the ESP. I am working on setting the water time on a slider bar on the frontend.
switch:
- platform: restart
name: "solarplantingwatering Restart"
# delay of 400000ms is a failsafe if mqtt fails to shut pump off
- platform: gpio
pin: 14
id: relay1
inverted: false
name: "Plant watering1"
icon: "mdi:watering-can"
#turn_on_action:
on_turn_on:
- delay: 400000ms
- switch.turn_off: relay1
My project will operate almost the same way. This is useful for me, I’ll probably mirror a lot of the logic.
I’ve tidied up and dropped some of my WIP ESPHome config here. Maybe some of it is reusable.
The main bits I’ve been working on is getting the deep sleep working how I want. It’s my first deep sleep project.
I went with the API rather than MQTT. I asked the question about which is better in 2022 and despite what you see online, one of the ESPHome devs suggest API is good as long as your mdns is working well.
I have been trying to decipher the schematic on the thingiverse page Smart, Self-watering Plant Pot Planter "Flaura" by Martin_McMaker - Thingiverse
The damn thing is hard to read. I will hopefully produce a scribbled pen and ink some time soonish. I am also endeavouring to use easyeda, but it is a learning curve.
I’ve added the flowchart I made previously to Git as well as a small todo-list.
I’m still working on some experiments regarding tightness (though nowhere nearly as fast as I’d like to) and I think @nickrout is working on documenting the PCB.
That means the rest of the coding is up for grabs. I think the next big chunk that would be nice to get sorted is getting the moisture sensor to work reliably. Anyone who’d like to get that bit working?
Was looking at the problem with water level sensor and think it might be less destructive to the electrodes if you made them capacitance touch sensor rather than binary sensors that eventually destroy the end of the leads.
esp32_touch:
setup_mode: true
sleep_duration: 436 milliseconds
binary_sensor:
- platform: esp32_touch
name: "ESP32 Touch Pad GPIO27"
pin: GPIO27
threshold: 1100
This was just a test but it could detect the water. I used aluminium foil to cover the tip of the lead. The setup mode is just to work out the threshold in my example. If you leave one lead in as ground it apparently makes it better. Might be able to just use one lead in a plastic cover that works by parasitic capacitance that can measure depth so little risk of electrode breakdown. I think most of the pins already chosen for depth sensor are able to be used as capacitance touch.
That is a great idea, though I’m not sure I agree with you as to why it is a great idea
If we just use a thick enough bolt, it won’t corrode before the sun burns out as long as we don’t measure continuously. Actually, it could even be galvanized or marine grade and it would proberbly last more or less forever. It’s still a great idea though, because the water level sensor gets us a hole in the bottom of the tank and the water pressure from the other side makes it a bit hard to get tight (as reported by almost everyone who made test-prints)
With capacitative detection, we can run the wires through the top of the tank eliminating the need for holes in the bottom. Turns out, it isn’t that hard to make one either: DIY Capacitive Water Level Sensor using ESP32 Touch Read function - YouTube
Yes , less holes in bottom less problem with water leak.
I’ve orderes some cobber tape on Amazon and plan to see if I can build a capacitor for water tank level detection. After giving it a bit of thought, I don’t think we can make a sensor that is cheaper and better than the one in the flower-part of the pot, but that one is to long to fit in the water-resevoir so we need to make our own for that. The tolerences are also much bigger for that one, so it may be we’ll be ok without voltage regulation and all the other fancy functions of the proper moisture sensor inside the pot.
Perhaps not cheaper but it depends what you mean by better. The sensor that you are using to determine when to water is just binary. Your new parasitic capacitance sensor may just
be as useful to help determine when to water and if it comes in at the top of the pot may also be better for reducing the leak problem. Hysteresis is a big factor in watering plants for both the plant health and battery savings. In general plants like to dry out between watering so air can get at the roots.(speaking as a green thumb. Can’t speak of hydroponics though.
Looking forward to see how your experiment with the new capacitance moisture sensor goes.
Well, we’ll see. I’ll keep you posted
How much room is there in the water resevoir? Would this fit?
There is about 90 mm of space, and this device is more than 13mm including the circuitry, so it wouldn’t fit if it is mounted with the connectors up. It could be mounted the other way - that would make it an almost perfect fit, but that would get us an even bigger hole to get tight.
I haven’t been keeping up on the full thread and not across all of your constraints, but did you consider using a ToF sensor for water level?
It’s what I’m using on my similar project (just uploaded a few new progress pics).
I also use this approach for my coffee machine reservoir.
Good morning folks, I am very pleased to have stumbled upon this thread. This is the perfect design for an automated irrigation system. I’ve been working on a project like this since last year, but this year, I wanted to upgrade it to have app support and to be able to track every aspect through a phone app, and think this is the place that this will be made possible.
Any updates on the status of the Flutter app/Arduino code? I’m leaning more toward an interactive app rather than HA controlling and tracking for my personal edition of this project.
Thank you in advance!