Design and implementation of sewage cloud platform monitoring system

: With Guohua Sewage Treatment Plant being the centre of management and control, by means of structural analysis and construction of cloud platform, important running data, equipment state and surveillance video of each sewage treatment site built or being built nearby will be stored and categorized. Then analysis and decisions will be made, ensuring the good functioning of sites monitored by managers of the centre control site. At the same time, mobile applications can be used on smart phones with the support of the system, thus making it possible for managers to conveniently visit surveillance data in real time through web pages or app. With this arrangement in place, effective management measures will be taken in the shortest time every time the equipment of any one site is out of order. The entire system design has achieved many functions directed at multiple sewage treatment sites, such as decentralized control, centralized management, remote diagnosis and fault early warning.


Foreword
Sewage treatment represents a process in which sewage should be purified before it meets the water-quality requirement of discharge or reuse. It has been applied to use in wide areas such as architecture, agriculture, transportation, energy resources, petrochemistry, environmental protection, city landscape, medical care and catering. Also, sewage treatment has been increasingly commonplace in people's everyday life. Sewage treatment plants play a significant role in cities, but many problems are lurking in many medium-small sewage treatment sites of villages and towns. For example, though scattered in large number, these sites are often located in remote areas. Water quality varies greatly among different areas, so do the processing techniques and equipment selections. Moreover, basic personnel in charge of operation and maintenance lack complete sets of skills training and expertise. These undesirable ills will hinder the efficient operation of sewage treatment plants and management [1] .
In recent years, relying on the widespread application of diverse smart devices and 4G internet technology, cloud platform and "internet of things" (IoT) have been popularized and applied in all walks of life. Policy support and the concept of "Internet+" at home have played a part in the advancement. Internet giants such as Tencent, Alibaba, Huawei and Netease have launched publicoriented Infrastructure as a Service (IAAS) and Platform as a Service (PAAS), while professional IoT cloud platforms have emerged one after another (software services, SAAS). Tomo Popovic and his team, in terms of management application, did a research on the case in which professional IoT platforms were applied to precision agriculture and ecological testing and explored the feature and network structure of Internet application to agriculture [2] . With the rapid development of the society, major accidents such as urban fires, leakage of dangerous goods and explosion are happening more often year after year. The fire control cloud platform offers a collaborative management model characterized by a combination of Internet and fire control, thus making fire rescue more scientific in scheduling and more accurate in command [3] . In terms of medical care, medical informationization and the system of remote unlimited monitoring have delivered a more convenient life to the whole society. Also, FORECAST smart virtual mentoring system based on cloud platforms has become a boon for cancer patients [4] . In recent years, with the popularity of the Internet, the notion of "Smart City" are beginning to transform people's ways of living [5] . Therefore, the sewage treatment system built on cloud platforms represents not only a powerful combination of industry and information, but also a response to the national concept of green development, which is of great significance for ushering in a new era of socialist ecological progress.

System Structure
The sewage surveillance system based on cloud platforms, as is shown in Figure 1, is mainly comprised of the remote management software, communication server and smart control. It integrates such technologies as sensors, database, cloud computing and servers. Meanwhile, combined with the realistic requirements of sewage treatment, in terms of operation, maintenance and management, this system makes the real-time surveillance and fine management of sewage treatment a reality. This design digs deep into the network model of cloud platforms and in the case of sewage treatment plant in Taiping Town, explores in detail the process of constructing the sewage surveillance system in a top-down manner.
In this system, relevant data about the field device should be firstly collected to be stored in smart controllers and communicate with industrial communication servers at the same time. Then, the information involved will be transferred to cloud platforms, which will pass the information received to remote service terminal so that engineers will receive the feedback in time and realize remote maintenance. This system can be applied to apps on smart phones. Thus management personnel can conveniently visit the surveillance data in real time through web pages or apps and have the operation states of equipment in different places at their fingertips. In turn, the optimal decision will be made after the assessment of site conditions.

System Design
The ultimate objective of this sewage surveillance system is to manage the equipment and processing techniques in a smart and fine manner. Meanwhile, disorder testing, effective handling and technique parameters of the equipment will be further adjusted. This system entails application configuration layer, cognitive layer, internet layer, data layer and IntelliSense layer. By installing wireless smart terminals, data can be collected at smart nodes of IoT, including quantity of process collected by traditional field controller PLC, diagnosis information of significant equipment and image data captured by cameras. After preprocessing and time calibration, the data will be passed on to cloud servers through PC site or nodes of IoT to be integrated, analyzed and stored. The servers then will provide users with remote access interface and data interactive interface of terminal analysis tools.

On-site sewage treatment process
The sewage treatment plants involved in the system include the ones under construction and those to be improved and upgraded during operation. Taking the Taiping sewage treatment plant as an example, covering an area of one mu, it is a small-scale sewage treatment plant, and treats the domestic sewage produced mainly by residents and small workshops in Taiping district. With regard to the characteristics of the local sewage, an activated sludge treatment process is adopted, and its system structure diagram is shown in Figure 2. A pump station one kilometer away is used to pump sewage into the wastewater treatment plant, and the whole sewage treatment process is fully closed. Due to the relatively remote location of the wastewater treatment plant, an unattended operation and maintenance method is adopted with periodic inspection. The field controller is S7-1214 PLC, WEINVIEW MT8102IE is selected as the humanmachine interface, and a PC master computer is not equipped at the scene.

Data transmission
The variables reflecting sewage states mainly include an inflow rate, an outflow rate, a PH value, an air flow rate, dissolved oxygen, temperature and cod etc. Data generated during the sewage treatment process is collected by various sensors installed on the site, then transmitted to a PLC via Modbus or 4-20ma standard current, and is converted to scalar integers or floating-point numbers after being simply preprocessed in the PLC. As the inconsistency of data sequence intervals caused by network delay exists, data frames sent to a cloud database should contain time stamps. According to the requirements of different data sources, the transmission period is 5s-1min. Although the network enables important wireless nodes to be switched to a redundancymode, network disruptions caused by unpredictable situations would happen. The PLC controller contains a basic logic control program, which is mainly used for cyclically starting and stopping on-site equipment, fault protection and completing the basic process control under network fault conditions. The system structure diagram is shown in Figure 2. Due to the limitations of PLC memory capacity, a refresh rate and a network transmission rate, independent IoT nodes are configured to transmit data including digital images and surveillance videos captured by a camera, as well as important currents and voltages of equipment and important high-frequency information collected by an auxiliary detection module.

Network structure design for cloud platform
The on-site data collection in the sewage treatment plant is realized by connecting sensors to the PLC and an integrated acquisition module using shielded twisted pairs. Besides, an internal wireless network is also included. The main instruments in the remote pump station include two submersible pumps with one in use and the other for standby, a flow meter, a liquid-level meter and a smart meter, with no programmable devices and other types of controllers. A relay circuit intelligently and sectionally controlled by liquid levels controls the start and stop of the pump. Monitored data is sent to the PLC in the main sewage treatment plant via an industrial Zigbee-serial/485 integrated module.

Server structure
A server adopts a B/S structure and has good compatibility for an access end. The server environment is Windows server2012 R2, Apache+tomcat, Mssql 2012, php5.6, phpMyAdmin 2.92. The server performs collection, analysis and storage of data as well as external access to a dynamic interface, with a structure of three parts including a Web front end, back-end services, and a middle part. The front-end program provides access support for web clients. For the sewage treatment platform, basic panels and related object nodes are contained and quickly configured, a configured access interface is consistent with the on-site process. Database-related operations such as HTTP interactions, connection requests of Web Socket, data transmission, as well as compression, storage and queries of data are completed in the Web back end. The middle part of the server provides APT for the communication of each module, provides OPC data access to third-party software, and performs data analysis and scheduled control tasks. Laravel based on PHP is used for the development of a management system, so that in addition to the above-mentioned functional modules, a complete user management system is also included. Different management rights are assigned to different users in order to ensure secure access to the system. The group structure of the server is shown in Figure 3.

Test and Implementation
Since the main pollutants in wastewater are organic pollutants which are easily biodegradable, the sewage treatment plant treats wastewater following the secondary discharge standard of Discharge standard of pollutants for municipal wastewater treatment plant ( GB18918-2002), in which the allowable maximum concentrations of pollutants are as follows: BOD5≤30mg/L, COD≤100mg/L, SS≤30mg/L, NH3-N≤25(30) mg/L and TP≤3mg/L,. The control instruments in production process are shown in Table 1. The monitoring of the entire sewage treatment plant is achieved through the cloud platform. Access to the cloud platform is available with a mobile app or a web server. The monitoring screen of the WEB end of the cloud platform is shown in Figure 4. Status and overall conditions of running sewage treatment instruments are displayed in the cloud platform in real-time. The sewage surveillance system on cloud platforms makes it possible to conduct real-time monitoring of remote device and to follow the manufacturing information of sewage treatment plants in time. Thus, efficient operation of the system will be effectively guaranteed and the manufacturing efficiency of sewage treatment plants as well as the comprehensive strengths of operation and management will be further improved. Steady and efficient implementation of this system has not only make equipment management more information-based and powered the process of industrialization and informationization, but also responded to China's concept of green development, thus contributing to a beautiful China.