Hello Smart Home enthusiasts, I’m thrilled to share my recent project with you! Over the winter break, I successfully set up a control system for our pool, integrating it seamlessly into our Home Assistant setup. The PoolServant DIY Edition has been a fantastic addition, and I’d love to walk you through the process and share my experiences.The PoolServant DIY Edition is designed to handle several key functions, including controlling two 230V outlets for the sand filter system, managing a peristaltic pump for pH+ dosing, and operating a motorized ball valve for bypass control. Additionally, it measures water flow, monitors pool water level, tracks ambient temperature and humidity, and keeps an eye on power consumption. The setup involved a variety of components, from ESP32 Dev Kits to flow sensors and ultrasonic sensors, all neatly housed in an IP65 waterproof enclosure.Shopping List and Build Instructions:- Protoboard for layout and wiring- ESP32 Dev Kit as the brain of the system- 12V 4-channel relay module for controlling outlets- Voltage regulator (LM2596S DC-DC) to power the ESP32- Terminal block or screw terminals for secure connections- Resistors for pull-up and signal conditioning- 12V peristaltic pump for chemical dosing- Flow sensor (YF-DN40) for water flow monitoring- Motorized ball valve (12V DN40) for bypass control- 2 ultrasonic sensors (JSN-SR04T) for water level monitoring- Temperature and humidity sensor (DHT22) for ambient conditions- 12V power supply for reliable operation- Waterproof enclosure (IP65) for protection- Current sensor (ZMCT103C) for power monitoringThe build process was quite rewarding. I started by selecting the right-sized protoboard to ensure everything fit neatly. Power management was crucial, so I carefully set up the LM2596S to provide a stable 5V supply to the ESP32. Soldering the ESP32 onto the board was a highlight, and I made sure to double-check all GPIO connections for the relays, flow sensor, and ultrasonic sensors. The DHT22 temperature and humidity sensor was another key component, connected via a 10 kΩ pull-up resistor to ensure reliable data capture.One of the most challenging parts was ensuring that all safety mechanisms were in place. I implemented auto-restart and watchdog features to handle any unexpected issues, providing peace of mind that the system would recover gracefully if needed.**Integration with Home Assistant:The integration with Home Assistant was straightforward thanks to the ESPHome configuration. I defined the necessary sensors and actuators, ensuring that each component was correctly mapped to its respective GPIO pin. The result is a fully automated pool control system that I can monitor and control from the comfort of my home.GPIO Pin Assignment:- Peristaltic pump → GPIO12- Flow sensor → GPIO13- Pool heater → GPIO14- Sand filter → GPIO27- Ultrasonic sensor 1 (Trigger/Echo) → GPIO32/33- Ultrasonic sensor 2 (Trigger/Echo) → GPIO25/26- DHT22 → GPIO4- INTEG SWG → GPIO15- ZMCT103C → A0Safety and Reliability:**Safety was a top priority during the build. I implemented several layers of protection, including automatic shutdown mechanisms and a robust watchdog timer. These features ensure that the system remains reliable even under unexpected conditions, providing peace of mind for both the pool and the surrounding environment.**Future Plans:**Looking ahead, I’m excited about the potential to expand this system further. I plan to integrate additional sensors for water chemistry monitoring and explore the possibility of automating the pH+ dosing process based on real-time readings. The PoolServant DIY Edition is just the beginning, and I’m eager to see how this project evolves in the coming years.**Feedback and Suggestions:**I’d love to hear from anyone who has experience with similar projects or who can offer suggestions for improvements. Whether it’s about optimizing the current setup or exploring new features, your insights would be invaluable. Feel free to share your thoughts or ask questions—I’m happy to discuss any aspect of this project!Thank you for reading, and I hope this post inspires others to embark on their own smart home projects. Happy tinkering! ![]()