Skip to main content

Design and assembly of a domestic water temperature, pH and turbidity monitoring system



The aim of this study was to design a domestic water temperature, pH and turbidity monitoring system that could constantly log temperature, pH and turbidity of water and give alerts in case the parameters are outside the acceptable limits for potable water.


The system was designed, assembled and performed as expected. The study indicates that the proposed and designed system outperforms the existing manual monitoring system as it can constantly track and store changes in water quality. This could be used to prepare better treatment processes as well as identify problems in the water distribution system early enough.


Availability of clean and safe water is a necessity for life on planet earth and the fuel for sustainable development [1,2,3,4]. However, declining water quality has become a global problem [5, 6]. Sub-Saharan Africa is one of the regions of the world with limited access to clean and safe water [7, 8]. Uganda is among the most hit countries in the Sub-Sahara with water scarcity problem [9]. Yearly, more than 1000 Ugandans die of water borne diseases [10]. The Ugandan government through Ministry of Environment and other private companies has tried to deliver safe water but only 71% of the urban population access piped water [11]. This implies that the rest of the population uses unsafe water which makes them highly susceptible to water-borne diseases like cholera, diarrhoea and typhoid.

Water distribution networks are designed with minimum levels of risk of contamination but factors like leakages, bursts, changes in temperature and under dosing of chlorine increases risk of contamination especially when they occur in vulnerable areas like along storm water channels or slums. This poses a dire need to monitor the changes in water quality along the distribution network. Water quality management relies on hazard identification through surveillance (routine and manual monitoring) [12]. To understand water quality and its probable impacts, there is need to collect and monitor data from time to time. With the industry 4.0 revolution [13], there is need to embrace new technologies to make water quality monitoring easy [14,15,16,17,18].

The current study was undertaken to develop a domestic water temperature, pH and turbidity monitoring system that can constantly monitor domestic water points like reservoirs and storage tanks, and automatically notify the concerned personnel when water quality falls below the set standards. This is in line with target 1 of the United Nations’ sixth Sustainable Development Goal which targets the achievement of “universal and equitable access to safe and affordable drinking water for all by 2030”.

Main text

Materials and system design

The proposed domestic water temperature, pH and turbidity monitoring system consisted of a network of 3 sensors for collecting data on temperature, pH and turbidity of water. These sensors were connected to an Arduino microcontroller which processes the data before relaying it to a cloud platform through a Wi-Fi module. From the cloud platform, the information is pulled and displayed on a website. The authorities in charge are then able to monitor the data for the different water quality parameters as well as analyse the data in form of graphs. Should the data collected vary from the set standards, then the authorities are alerted instantly. Figure 1 shows the block diagram of the proposed system.

Fig. 1

Block diagram of the domestic water temperature, pH and turbidity monitoring system

The Arduino Uno used in this system is a microcontroller board based on ATmega 328P [17]. It was chosen because it has enough analog input pins to cater for the three analog sensors used. The waterproof DS18B20 temperature sensor is used to measure temperatures in wet environments with a simple 1-Wire interface [19]. It provides 9 to 12-bit Celsius temperature measurements and communicates over a 1-Wire bus that by definition requires only one data line (and ground) for communication with a central microprocessor [19]. The gravity analog pH sensor have a range of 0 to 14, which is measured between 0 to 60 °C [20]. The turbidity sensor detects suspended particles in water by measuring light transmittance and scattering rate which changes with the amount of total suspended solids [21]. It contains a light transmitter and receiver. When the water is clear, light scattering is minimal hence the light receiver receives the most amount of light. As turbidity of the water increases, the light receiver receives less light. The sensor detects when the light received is below a certain threshold.

The NodeMCU board was equipped with an ESP-12E module, which has an ESP8266 core processor with a module of 4 MB flash memory. With this board, the system was able to connect to internet and send the logged parameter data to the respective ThingSpeak channel fields. From the platform, the channel feeds are retrieved. That is, field data is displayed in the frontend application. Additional file 1: Figure S1 shows the algorithmic flow of the system when placed in water.

Results and discussion

The current water quality monitoring tools range from traditional sample collection to remote sensing technologies in the world, with some time consuming, labour intensive or are too costly. In Uganda, routine monitoring is done by National Water and Sewerage Cooperation (NWSC) by sampling and testing once every quarter [11]. One of the key findings of monitoring drinking water samples by NWSC in areas of Kampala, Mukono and Wakiso districts was that delayed maintenance of the distribution network poses high risks of water contamination [22].

In this study, we designed a water quality monitoring system with sensors that are able to log data and process it with the Arduino Uno before it is sent serially to a NodeMCU. Figure 2 shows a successful connection of the NodeMCU to the internet. Once connected, the values sent serially from Arduino Uno board are pushed to the ThingSpeak platform for storage and analysis. On the ThingSpeak platform, the values for each parameter are recorded as they come in and are presented in graphical forms as shown in Fig. 3 and Additional file 2: Figure S2. These graphs are then displayed on the website.

Fig. 2

Connection of NodeMCU to ThingSpeak

Fig. 3

ThingSpeak pH chart

When it was placed in clear tap water, the system indicated that the pH was 7.54 and turbidity was 0.00 which is in line with the NWSC standards for pumped and treated water. When placed in water with settled dirt, the system displayed that the turbidity was 2969 NTUs which makes the water unpalatable since it lies out of range of the acceptable standards (greater than 5 NTUs). When placed in muddy water, the system displayed that the turbidity was 3000 NTUs which means the water was unpalatable since its turbidity was beyond the acceptable limit. All the data were captured and displayed on the website as the most recent parameter status reading. The graphs and tabular format as presented in Additional file 3: Figure S3.

When temperature is below 20.0 °C, it indicates ‘‘LOW’’, greater than 26.0 °C indicates ‘‘HIGH’’ while ‘‘NORMAL’’ is for temperature between 20.0 and 25.5 °C. When the pH level is below 6.8, the status display on the website is “LOW”. When it is between 6.8–8.8, it shows “NORMAL” and “HIGH” when above 8.8. For turbidity values equal to or less than 5 NTUs, the status shown is “NORMAL” while for values above 5 NTUs, “HIGH” is displayed.

The designed system therefore had water quality sensors that transform detected chemical signals into electrical signals that can be translated into temperature, pH and turbidity measurements (Additional file 3: Figure S3). The results of this study corroborates a report by Azman et al. [23] who designed a low-cost nephelometric turbidity sensor for continual domestic water quality monitoring system. In another study [24], the authors reported that a sensor-based water pollution detection performed better than the traditional monitoring systems in homes and offices because it provided a real-time pH turbidity and temperature measurement which could enhance water quality monitoring. Another study [25] designed a system close to the one designed in the study but did not include the turbidity and temperature sensors. The current designed system is automatic, uses internet (Wi-Fi), is time saving, affordable with low maintenance cost and could prevent the spread of water-borne diseases through drinking water.


While the designed system saves on labour costs and time, it can only be used in a place with a good internet coverage to be able to relay the data to the cloud and consequently the web application. Further studies should incorporate more sensors for other water quality parameters such as nitrates, conductivity and total dissolved solids.

Availability of data and materials

The datasets supporting the conclusions of this study are available from the corresponding author upon reasonable request.


  1. 1.

    WHO. Drinking-water; 2019. Accessed 04 Jan 2021.

  2. 2.

    Ngowi HA. Prevalence and pattern of waterborne parasitic infections in eastern Africa: a systematic scoping review. Food Waterborne Parasitol. 2020;20:e00089.

    Article  Google Scholar 

  3. 3.

    Omara T, Nteziyaremye P, Akaganyira S, Opio DW, Karanja LN, Nyangena DM, et al. Physicochemical quality of water and health risks associated with consumption of African lung fish (Protopterus annectens) from Nyabarongo and Nyabugogo rivers, Rwanda. BMC Res Notes. 2020;13:66.

    CAS  Article  Google Scholar 

  4. 4.

    Nafi’u A, Anandapandian KTK. The occurrence of waterborne diseases in drinking water in Nakaloke Sub-county, Mbale district, Uganda. Int J Sci Res. 2016;5:1416–21.

    Google Scholar 

  5. 5.

    Omara T, Karungi S, Kalukusu R, Nakabuye BV, Kagoya S, Musau B. Mercuric pollution of surface water, superficial sediments, Nile Tilapia (Oreochromis nilotica Linnaeus 1758 [Cichlidae]) and yams (Dioscorea alata) in auriferous areas of Namukombe stream, Syanyonja, Busia. Uganda PeerJ. 2019;7:e7919.

    Article  Google Scholar 

  6. 6.

    Odonkor ST, Mahami T. Escherichia coli as a tool for disease risk assessment of drinking water sources. Int J Microbiol. 2020;2020:2534130.

    Article  Google Scholar 

  7. 7.

    BORGEN Magazine. Poor Sanitation in Kenya Leads to Water-Borne Diseases. 2020. Accessed 20 Jan 2021.

  8. 8.

    Marks SJ, Clair-Caliot G, Taing L, Bamwenda JT, Kanyesigye C, Rwendeire NE, et al. Water supply and sanitation services in small towns in rural–urban transition zones: the case of Bushenyi-Ishaka Municipality, Uganda. NPJ Clean Water. 2020;3:21.

    Article  Google Scholar 

  9. 9.

    Huston A, Gaskin S, Moriarty P, Martin W. More sustainable systems through consolidation? The changing landscape of rural drinking water service delivery in Uganda. Water Altern. 2021;14:248–70.

    Google Scholar 

  10. 10.

    Disaster Relief Emergency Fund (DREF). Cholera Outbreak in Mbale District. The International Federation of Red Cross and Red Crescent. 2012, 9 pages.

  11. 11.

    Water and Environment Sector Performance Report 2018. Government of Uganda. Ministry of Water and Environment, Kampala, Uganda; 2018. p. 1–264

  12. 12.

    Gara T, Fengting L, Nhapi I, Makate C, Gumindoga W. Health safety of drinking water supplied in Africa: a closer look using applicable water-quality standards as a measure. Expo Health. 2018;10:117–28.

    CAS  Article  Google Scholar 

  13. 13.

    Bongomin O, Ocen GG, Nganyi EO, Musinguzi A, Omara T. Exponential disruptive technologies and the required skills of industry 4.0. J Eng. 2020;2020:4280156.

    Google Scholar 

  14. 14.

    Sendra S, Parra L, Lloret J, Jiménez JM. Oceanographic multisensor buoy based on low cost sensors for Posidonia Meadows monitoring in Mediterranean Sea. J Sens. 2015;2015:920168.

    Article  Google Scholar 

  15. 15.

    Geetha S, Gouthami S. Internet of things enabled real time water quality monitoring system. Smart Water. 2016;2:1.

    Article  Google Scholar 

  16. 16.

    Mamun KA, Islam FR, Haque R, Khan MGM, Prasad AN, Haqva H, Mudliar RR, Mani FS. Smart water quality monitoring system design and KPIs analysis: case sites of fiji surface water. Sustainability. 2019;11:7110.

    CAS  Article  Google Scholar 

  17. 17.

    Saravanan K, Anusuya E, Kumar R, Son LH. Real-time water quality monitoring using Internet of Things in SCADA. Environ Monit Assess. 2018;190:556.

    CAS  Article  Google Scholar 

  18. 18.

    Obado SA. IoT Based realtime fish pond water quality monitoring model. MSc Thesis, Strathmore University, Nairobi, Kenya. 2019.

  19. 19.

    Koritsoglou K, Christou V, Ntritsos G, Tsoumanis G, Tsipouras MG, Giannakeas N, et al. Improving the accuracy of low-cost sensor measurements for freezer automation. Sensors. 2020;20:6389.

    Article  Google Scholar 

  20. 20.

    Pratami LWD, Ariswati HG, Titisari D. Effect of temperature on ph meter based on arduino uno with internal calibration. J Electron Electromed Med Inf. 2020;2:23–7.

    Article  Google Scholar 

  21. 21.

    Thenkabail PS. Hyperspectral Remote Sensing for Terrestrial Applications. In: Thenkabail PS, editor. “Remote Sensing Handbook” (Volume II): land resources monitoring, modeling, and mapping with remote sensing. Boca Raton: Taylor and Francis Inc.\CRC Press; 2015. p. 201–36.

    Google Scholar 

  22. 22.

    Ministry of Water and Environment, Uganda Water And Environment Sector Performance Report 2019. 2019. Accessed 07 Jan 2021.

  23. 23.

    Azman AA, Rahiman MHF, Taib MN, Sidek NH, Abu Bakar IA, Ali MF. A low cost nephelometric turbidity sensor for continual domestic water quality monitoring system. IEEE International Conference on Automatic Control and Intelligent Systems (I2CACIS), Selangor, Malaysia. 2016, p. 202–7.

  24. 24.

    Deepiga T, Sivasankari A. Smart water monitoring system using wireless sensor network at home/office. Int Res J Eng Technol. 2015;02:1305–14.

    Google Scholar 

  25. 25.

    Hasan MT, Khan S. GSM based automatic water quality control. Int J Adv Res Elect Electron Inst Eng. 2016;5:5522–9.

    Google Scholar 

Download references


Not applicable.


This research received no external funding.

Author information




DRN & GGO designed the study, DRN performed design experiments. GGO & DM supervised the work and provided technical support. GGO, FB, DM & TS analyzed the collected data. GGO & TO wrote the first draft of the manuscript. All authors revised the final manuscript. All authors read and approved the final manuscript.

Corresponding author

Correspondence to Gilbert Gilibrays Ocen.

Ethics declarations

Ethics approval and consent to participate

Not applicable.

Consent for publication

Not applicable.

Competing interests

The authors declare that there is no conflict of interest regarding the publication of this paper.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Supplementary Information

Additional file 1: Figure S1.

Logical flow of the domestic water temperature, pH and turbidity monitoring system.

Additional file 2: Figure S2.

ThingSpeak turbidity chart.

Additional file 3: Figure S3.

Website for visualization of the logged parameter data.

Rights and permissions

Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit The Creative Commons Public Domain Dedication waiver ( applies to the data made available in this article, unless otherwise stated in a credit line to the data.

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Nanyanzi, D.R., Ocen, G.G., Omara, T. et al. Design and assembly of a domestic water temperature, pH and turbidity monitoring system. BMC Res Notes 14, 161 (2021).

Download citation


  • Internet of Things
  • Water quality
  • Temperature
  • PH
  • Turbidity