Project_Tracker¶
Access to safe and clean drinking water remains a major challenge in Kenya, where millions of people still lack reliable water services. In cities like Kisumu and many rural areas, communities depend on pump-based systems and natural water sources that are often not monitored, leading to water contamination with suspended particles, heavy metals, and other harmful substances, which increases health risks and inequality in access to safe water.
This project addresses the problem by developing a portable, modular water purification and control system that can be added to existing water sources without major infrastructure changes. It combines electrocoagulation, physical filtration, and real-time monitoring using turbidity and flow sensors, all controlled by a microcontroller, to ensure water only flows when it meets safety standards, while automated valves regulate distribution and a dashboard provides users with clear insights into water quality and system performance.
Hand Sketches¶

I used chatgp to generate the sketch:
Flow Chart

Physical Components
Pump

The project requires a 24 V DC self-priming diaphragm pump because the system needs to draw water from a tank without being submerged and still maintain consistent pressure for controlled delivery. The pump operates at about 50–60 PSI, which is sufficient to meet the solenoid valve’s minimum opening pressure requirement of about 3 PSI (0.02 MPa), ensuring the valve can open and close reliably, and it can handle flow rates within the YF-S201 flow sensor range of 1–30 L/min, allowing accurate measurement of water flow through pulse signals. The pump is also selected with 1/2 inch inlet and outlet ports to match the system piping, ensuring proper compatibility, reducing pressure loss, and allowing smooth water transfer without the need for adapters or flow restriction, making it efficient for the entire system.
NC Solenoid valve

The project uses a 24 V DC solenoid valve with 1/2 inch ports that remains normally closed and only opens when 24 V is applied. It is chosen to match the 1/2 inch piping system, ensuring smooth integration without flow restriction, and it operates effectively with the pump’s 50–60 PSI pressure to allow controlled water movement through the system. The valve is controlled based on sensor inputs such as turbidity and flow rate from the YF-S201 sensor (1–30 L/min), allowing it to open or close depending on water quality or abnormal conditions, and it provides a safe fail-state by automatically closing and stopping water flow in case of power loss or system failure.
Exsiting filters
Filtration Module
My filtration module uses 1/2 inch inlets and oultets pvc pipes and PVC pipe 3” as the main catriege
V = π r² h
r = d / 2 = 0.04445 m
h = 400 mm = 0.4 m
V ≈ 0.00248 m³
Litres
V = 0.00248 × 1000
V ≈ 2.48 Liters
To ensure proper fitting and sealing of the components, heat shrink tubing was used to secure and slightly reduce the diameter of the 3-inch plugs, allowing them to fit correctly into the designated connectors. This method also improves grip and provides a tighter, more reliable seal
To achieve a proper fit within the system, the longer leg of the connector was cut using a hacksaw. This modification was necessary to reduce the length of the connector so that it could fit inside the designated pipe and align correctly with the rest of the assembly. By shortening the connector, it ensured a better fit, improved alignment, and allowed for a more compact and efficient installation within the system.
After assembling and modifying the connector, a clamp was used to hold the joint firmly in place while it hardened. This ensured that the connection remained tightly secured and properly aligned during the curing process. The use of the clamp improved the strength of the joint, reduced the risk of leaks, and resulted in a more stable and durable connection within the system.
The pipe connections were then assembled using a PPR (Polypropylene Random) welding machine, which was used to heat and fuse the connectors to the male adapters. This process ensures a strong, leak-proof joint that can withstand pressure within the system.

Sensors

The project uses the LGZD Sensor V1.1 turbidity sensor, powered at 5 V DC with a current consumption of up to 30 mA, making it suitable for direct connection to a microcontroller system. It measures water clarity by providing either an analog output (0–4.5 V) or a digital signal (0–5 V), with a fast response time of less than 500 ms, allowing the system to quickly detect changes in water quality. This sensor is chosen because it enables real-time monitoring of turbidity levels, so the system can automatically trigger actions such as activating the solenoid valve to stop or allow flow and controlling the pump, ensuring only clean water passes through the system while maintaining reliable and responsive automated operation.
Circuit Design and Programming Draft circuit
Am going to use Xiao ESP32C3 as my MCU, and to ensure I dont connet my pump directly to the controller i decided to use relays,
