In urban areas, especially in Indonesia, sewer lines are generally located at the front of the house. This channel will drain the remaining water from each house to a landfill. In some ditches, some obstacles cause water not to flow correctly, coupled with the tropical season in Indonesia, making these conditions an optimal place for mosquitoes to breed. Before this causes a worse impact, some treatments are needed to overcome this.
SolutionIn overcoming the problems that have been mentioned, a monitoring system to monitor the condition of the sewer line in front of the house. The prototype of this system is called NOMOS which stands for no mosquito. This monitoring uses some parameters such as temperature, humidity, and water flow. The system will determine the level of danger that may occur based on these three parameters if prevention is not immediately carried out by cleaning the drain. The system will notify if precautions are needed so that the user can immediately check the sewer line.
How it works?NOMOS will monitor the water flow to see if the water flow is running well or not. Warm temperatures will also be one of the parameters to determine whether the condition of the sewer is an optimal place for mosquitoes to breed. All data will be sent to the database using Seeed's SenseCAP K1100. The system will also be built to provide notifications to users. The use of tinyML on the edge impulse platform will be used to predict the level of danger that may arise.
Process and Steps1. Read SHT4x sensor
2. Read water flow sensor YF-S201
3. Make GUI on SenseCAP K1100
4. Make holder for the device and sensor
5. Make connector for water flow sensor YF-S201
6. Test connection (optional)
7. Send data to Thinkspeak
8. Collect data
9. Make a machine learning model
10. Model implementation on the device
11. Make monitoring website using weebly
12. Test the device
STEP 1: Read SHT4x SensorThis Grove SHT4x digital sensor is based on Sensirion's industry-proven humidity and temperature sensors. It can provide constant temperature and humidity accuracy over an extensive measurement range And with the grove platform, you are ready to plug and play the SHT4x sensor on any microcontroller (Arduino) or microprocessor (Raspberry Pi).
The first step is to try to access the SHT4x sensor to find out the temperature and humidity values of the environment. In this step, the Arduino IDE is used to upload the created program. There is documentation on the seed studio's official website regarding SHT4x on this link: (link). When the sensor has been successfully accessed, the SenseCAP K1100 will display the temperature and humidity in real-time
Water Flow Sensor is mainly made of plastic, hall sensor and magnetic rotor. This sensor is used to detect or measure the flow of water. When water passes through the rotor, the magnetic rotor will rotate. The rotation speed of the magnetic rotor depends on changes in the water flow rate, then this hall sensor is read by the microcontroller.
The use of this sensor is to use a digital pin on the SenseCAP K1100. The power pin on the sensor is connected to pin 3v3, the gnd sensor pin is connected to the gnd SenseCAP K1100, and the data pin is connected to pin D0 (BCM27). For more information, see the image below. The program can be accessed on the following GitHub link: (link)
When the sensor has been successfully accessed, the SenseCAP K1100 will display the water flow measurement value in real-time
SenseCAP K1100 has a built-in TFT LCD which can be accessed very easily. There is some documentation on the official website that can be used to access the TFT LCD at the link: (link), or this GitHub link for the complete code: (link). In this project, a simple GUI is created to display sensor measurement value and status results of the Mosquito growth monitoring system. The GUI result (using dummy data) is shown in the picture below.
The sensor and SenseCAP K1100 used in this project are still component modules. In the implementation process directly in nature, it is necessary to make some additions to the components that will be used so that the project can be implemented properly and quickly. Related to this, additional holders were made for the components to be used. The holder creation process is carried out using the SolidWorks application. SolidWorks is a solid modeling computer-aided design (CAD) and computer-aided engineering (CAE) application published by Dassault Systèmes. According to the publisher, over two million engineers and designers at more than 165, 000 companies were using SolidWorks as of 2013.
The first process is accomplished by creating a partition of the components to be used, as shown in the image below.
The next part is to design the holder for each component that will be used. The holder that will be built will be divided into several partitions to make it easier to print using a 3d printer machine. The partitions that have been created can be seen in the picture below.
After the design process in the form of partitions has been completed, then an assembly file is created to unite all the files that have been created and to see the feasibility and precision of all the components that have been made. This process is also used to create rendering images from assembly files which are then used for project documentation. The results of the assembly file that has been created can be seen in the image below.
After the design process is complete, the next process is the process of printing files that have been created using a 3d printer machine. Files that have been created using the SolidWorks application will then be saved in the form of an STL file (stereolithography file).
The next process will use the Ultimaker Cura app to convert the STL file into a compatible GCode file for the 3d printer machine used. In this project, the Anycubic Kossel Pulley 3d printer was used. The Ultimaker Cura application is very easy to use, the steps that need to be done are to import an existing STL file and press the slice button. After the process is complete, save the GCode file that has been created into the PC directory.
This GCode file is then transferred to the SDCard on the 3d printer machine. Then let's print the file!
One process that is no less important is the image rendering process to make the documentation better. The image rendering process in this project uses the keyshot application. This application will generate an image from the assembly file that has been created as shown below.
All 3d files can be accessed at the link: (link) or in the attachment file at the bottom of the project documentation.
STEP 5: Make connector for water flow sensor YF-S201The YF-S201 water flow sensor used in this project has a pinout header with a 3-pin JST connector and is not compatible with the pinout header of the SenseCAP K1100.
In this project, a simple connector was made using the Eagle application for the YF-S201 water flow sensor. EAGLE is a scriptable electronic design automation (EDA) application with schematic capture, printed circuit board (PCB) layout, auto-router and computer-aided manufacturing (CAM) features. EAGLE stands for Easily Applicable Graphical Layout Editor (German: Einfach Anzuwendender Grafischer Layout-Editor) and is developed by CadSoft Computer GmbH. The company was acquired by Autodesk Inc. in 2016.
The first part of creating a connector is to create a schematic file. components that need to be added are 2x7 headers and 1x3 headers. After adding components, then connect the pins to be used. The schematic results can be seen in the image below.
The next part is to create a board file. Once made, each connected pinout needs to be connected so that all pinouts are connected properly. The results of the board file can be seen in the image below.
After being printed and connected to the water flow sensor YF-S201 the results are as shown below.
The schematic and board files of the connector can be accessed at the following link: (link) or in the attachment at the bottom of the project.
STEP 6: Test connection (optional)One of the things to note regarding the SenseCAP K1100 is the section for connecting to wifi. If the product you have is a product that was produced before July 15, then you must update the firmware so that it can connect to your wifi. You can follow the step-by-step instructions on the following link: (link).
STEP 7: Send data to ThinkspeakAfter all sensors can be read and can issue values, then the next part is to create a data storage area that can accommodate the readings from the 4x SHT sensor and the YF-S201 water flow sensor. The platform chosen for this task is thingspeak. ThingSpeak is open-source software written in Ruby which allows users to communicate with internet-enabled devices. It facilitates data access, retrieval and logging of data by providing an API to both the devices and social network websites. ThingSpeak was originally launched by ioBridge in 2010 as a service in support of IoT applications.
Seeed Studio has provided a very detailed step-by-step tutorial on how to send data using the SenseCAP K1100. You can follow the step-by-step in the video below.
The data that has been saved can be seen in the image below.
After all components are ready, both from the circuit connection and the process of reading the data, the next process is the data collecting process. In this project, data collecting is carried out using a data forwarder to the edge impulse.
Refer to this link (link) and (link), There are several applications that must be installed:
- Node.js v12 or higher
- Arduino IDE
- The Edge Impulse CLI. Install by opening command prompt or terminal and run (windows):
npm install -g edge-impulse-cli
There are some notes that must be considered in the installation process:
- install the addition tools when installing NodeJS (not selected by default).
- The Arduino IDE version must be at least 1.15.
- more details on this link. (link)
After all applications are installed, the next process is to add a program for the Serial monitor which will later be used to send data using a data forwarder.
The next process is to open Edge Impulse CLI using Node js command prompt with the command:
edge-impulse-data-forwarder
Login with the impulse edge account, select the port from SenseCAP K1100, select the project on the impulse edge, and give each data feature a name.
And VOILA! The device is ready to collect data. You can check if the device is connected to the edge impulse.
In this project, there are 6 location points that are used as a place to collect data. This location point is divided into 3 safe points with drains flowing and 3 danger points with sewers not flowing properly. The use of these two types of places will then be used as classes in the classification process.
There is some detailed documentation by Seeed for the step-by-step data collection process on the link (link), (link), and (link).
STEP 9: Make a machine learning modelThe first process of creating a machine learning model is Impulse Design. This section begins with creating an impulse that will be used. The user must select the processing block and learning block to be used.
In this project, the flatten processing block was chosen. Flatten block will take several features in the form of statistical parameters such as Average, Min, Max, and other functions of raw data within time window. In this project four features were selected to simplify the process.
In the learning block section, NN Classifiers are selected to carry out the classification process. This process aims to create a machine learning model from features that have been extracted from raw data in the previous process.
Edge impulse is equipped with features to convert machine learning models for various devices and programming languages. On the Deployment tab, you can select the type of device or programming language to be used. In this project, the machine learning model will be implemented using the Arduino IDE.
When the download is complete, extract the archive and place it in your Arduino libraries folder. Open Arduino IDE and choose static buffer sketch (located in File -> Examples -> name of your project -> static_buffer), which already has all the boilerplate code for classification with your model in place.
STEP 11: Make monitoring website using WeeblyWeebly was founded in 2006 by Chief Executive Officer David Rusenko, Chief Technology Officer Chris Fanini, and former Chief Product Officer Dan Veltri. Rusenko and Fanini both attended the College of Information Sciences and Technology at Pennsylvania State University (Penn State). Veltri attended the university's Smeal College of Business. At the time, Penn State required all students to maintain an Internet portfolio, so they built upon this idea and created software that made it easy for anyone to build a personal website.
Using weebly is very easy, users just need to drag and drop for the features to be used. There are lots of features that can be used, one of which is the Embed Code feature. The Embed Code feature will be used to display graphics from thingspeak. The way to display the graph is by copying the embed code on thingspeak and pasting it on weebly.
The use of web monitoring is intended so that NOMOS users can find out the current situation of the user's sewer conditions wherever they are as long as they are connected to the internet. In this project, monitoring can be done on the following link: https://rifqi-abdillah.weebly.com/nomos.html
STEP 12: Test the deviceClosingNOMOS can be used to monitor sewer conditions. NOMOS has the aim of preventing the breeding of mosquitoes which are usually found in sewers whose conditions do not flow properly and in dry and warm environmental conditions.
The developer hopes that NOMOS can become one of the solutions to reduce the risk of mosquito breeding in urban areas. In the future, the developer hopes that more features can be developed, for example, in addition to monitoring water flow conditions, NOMOS can also be developed to monitor the condition of sewer cleanliness.
The developer also hopes that in the future NOMOS can develop more widely and receive support from various parties, including the government, so that it can provide a real and better form of implementation.
There is a proverb in Indonesia, "provide an umbrella before it rains", which means that it is better to prepare something for prevention purposes before a bigger bad impact occurs. So, let's take care of our sewers by using NOMOS and cleaning regularly to prevent mosquito breeding.
SEE YOU ON THE NEXT PROJECT! :)
Comments