Design and deployment of Aqua monitoring system using wireless sensor networks and IAR-Kick

In Aquaculture, the yields (shrimp, fish etc.) depend on the water characteristics of the aquaculture pond. For maximizing fish yields, the parameters which are to be kept at certain optimal levels in water. The parameters can vary a lot during the period of a day and can rapidly change depending on the external environmental conditions. Hence it is necessary to monitor these parameters with high frequency . Wireless sensor networks are used to monitor aqua farms for relevant parameters this system consists of two modules which are transmitter station and receiver station. The data transmits through GSM to the Database at receiver station. The graphical user interface was designed, to convey the data in the form of a message to the farmers in their respective local languages to their Mobile Phones and alerts them in unhygienic environmental conditions, in order to take suitable actions. Keywords; aquaculture; wireless sensor networks; IAR-Kick;pH;


Motivation
In Aquaculture, the yields (shrimp, fish etc.) depend on the water characteristics of the aquaculture pond. For maximizing fish yields, the parameters which are to be kept at certain optimal levels in water are dissolved oxygen, temperature, salinity, turbidity, pH level, alkalinity and hardness, ammonia and nutrient levels. These parameters can vary a lot during the period of a day and can rapidly change depending on the external environmental conditions (Fig.1shown above).
In early years, considerable amount of work has been carried out with respect to related issues yet communications with the outside world are still not yet completely investigated. Till now they have not yet ended up boundless and utilized within the different applications in which they can give huge profits. What's more, there are still just a set number of business WSN-based results accessible in the business. This is not amazing given the difficulties identified with their configuration and execution, power utilization demands of the sensor nodes, communication failures, environmental influence, and scalability issues. The distinguishment of these difficulties inspired us to perform this exploration. Specifically, this exploration proposes a model answer for the issues said above. "Created an online water checking framework focused around ZigBee and GPRS, the sensor information was gathered and transmitted by means of ZigBee and GPRS. The Data Process Procedure was actualized by lab view programming. " [Haijiang et al. 2012].
"Created an appropriated estimation framework focused around organized brilliant sensors to screen aquaculture considers in nature's turf. The framework comprises of four sections: information gathering hubs, steering hubs, on location observing focus and undemonstrative checking focus; and can bring-out ongoing observing water quality parameters and meteorological parameters". [Espinosa-Faller and Rendon-Rodriguez (2012)] Fig.2.shown given below, In Existing system, farmer checks their ponds daily. And manually we will measure the pH value of water. pH is measured by the pH meter made of electronic device. Electronic meter is connected to pH probe(a glass electrode). It display the readings . The key part of pH meter is the probe. It is like a pole structure generally manfactured by the glass that contain a bulb at the bottom and also contain sensitive sensor .Suppose we want to find out solution, probe is dipped into the solution to easily get the readings.
Suppose the farmers want to find out the characteristics of water then they must collect water from the ponds and take to laboratory. Check the parameters of water samples. If those samples are not good results then they must take necessary actions. So this procedure takes a lot of time and manual testing is not possible in unhygienic environmental conditions Disadvantages of existing system: • All pH meters need to be calibrated at some frequency • The probe has to be cleaned well after every use to make sure you get a reliable reading next time • It takes lot of time to test pH in manually • manually testing is not possible in unhygienic environmental conditions Some systems were developed with wireless sensor networks but some problems exist in the system, such as battery problem, communication protocols problems, sensor readings reliability. However, earlier systems were not made with GSM Network in aqua monitoring systems for remotely connecting environmental parameters such as pH, humidity, inside temperature and outside temperature of water.

Proposed system description
We propose the automatic system for checking water characteristics of aqua ponds in any situation (hygienic and unhygienic environmental conditions). (Fig.3 shown below)The system consists of two modules which are transmitter station and receiver station with personal computer as an analyzing center or monitoring center. The following list contributes overall framework of the aqua monitoring system. 1. Embedded Systems Design 2. Radio Frequency Integrated Circuits 3. Wireless Sensor Networks 4. The collected data will be analyzed by using Data Mining Tool. 5. Convert the output into local language using local language translators. 6. user interface design in local languages

Design of transmitter station
Wireless sensor networks have a distributed collection of sensor nodes (Temperature, pH and Humidity sensors ) networked together in some fashion so that they transmit the raw or processed sensed data to some central location called base station. Each sensor node has a microcontroller, sensors and a radio transceiver for communication. The microcontroller can be used for in-network processing, so that only the necessary information can be transmitted instead of plain raw data. As the sensor nodes are battery powered, any reduction in the number of bits transmitted will save power expended on transmission, thereby extending battery life. There is a lot of research activity in this area addressing problems like sensor node placement for optimal coverage, topology formation, routing, in-network data processing techniques to reduce communication costs, operating system design etc. Most of this work is simulation based and the real life deployments are just a hand full, like Princeton's Zebra Net and UCLA's Geo Net. There are few efforts in applying sensor networks for precision aquaculture. It is hard to estimate their impact from these references, as we believe it will take few crop cycles to understand the on-field issues and refine the designs; and few more crop cycles to gather enough data for impact analysis. However to the best of our knowledge the sensor networks deployed in these systems use off-the-shelf available sensor nodes and no specific efforts are made in the hardware design cost reduction. Fig.3 shown below, we propose to use sensors in transmitter station to monitor aqua farms for relevant parameters such as pH levels, ambient humidity dissolved oxygen levels, temperature inside and outside water, ammonia levels etc. In contrast to other studies, the graphical user interface was designed in VB and .Net, so that farmers and investigators can observe, investigate and analyze the related data. The transmitter consists of:

Sensor nodes
Sensors are electronic devices that measures response to vary in physical environmental conditions like humidity, sound, temperature, pressure etc. It senses signals in voltages (eg.+5v,-5v) and continuously sends signal in the form analog signals and also converted into digital form by using an analog-to-digital converter and sent to microcontroller for further processing. They are in small size, consume low power, and operate in high densities.
Here we are using sensors • Temperature sensors for measuring temperature inside and outside water.

Sensor selection
• Water Outside temperature sensor: This is the latest DS18B20 1-Wire digital temperature sensor from Maxim IC. Reports o c with 9 to 12-bit precision, -55C to 125C (+/-0.5C).
• Water Inside temperature sensor: A temperature sensor is used with HOBO U-Series, UX120-006M external-channel data loggers or ZW series wireless data nodes. This model measures temperature in air, water, or soil. Accuracy and resolution vary according with attached logger model.
• pH sensor: The most common pH sensor is the glass electrode. It is used in many industry applications and in a wide variety of fields.
• Humidity sensor: Humidity is one of the most frequently measured quantities in different fields, such as industrial processing, agricultural, climate research, pharmaceutical engineering, etc.

GSM Modems
Aquacultures ponds are far away to villages and power-supply not available to the ponds, data collection nodes are not placed at place .we are setup the receiver node at data collection center in villages or towns and also send the warnings or message to the farmers in unhygienic environmental conditions. So In this prototype we used the GSM modems for covers long range communication.gsm modem have a SIM card, operates under a mobile operator, just like a mobile phone. It support the 2G, 3G technologies, HSUPA, UMTS, WCDMA and HSDPA, as well as the GPRS and EDGE.GSM modems are embedded at both stations (transmitter and receiver station).

Microcontroller
In this prototype we used The AT89C52 is microcontroller with a low-power; high-performance CMOS 8bit microcomputer with 8K bytes of Flash programmable and erasable read only memory (PEROM).

ARM Processor
In this prototype we used the ARM Processor, it is the industry's leading supplier of microprocessor technology, offering the widest range of microprocessor cores to address the performance, power and cost requirements for almost all application markets.

System software
The aqua monitoring system checking with various sensors records also saves the entire measured data to make an aquaculture database system, which provides analysis of date by using analyzed patterns of changing environmental conditions in the fish ponds. That Information compared with preset ideal conditions. If a measure data from a monitoring system is outside a preset range, the system sends warning to the farmers to take suitable actions. Communication process module connected to the PC via serial port RS-232.

Sensor node firmware
The embedded software to control the wireless sensor system is actualized utilizing IAR or RAM created in C language. The hex document is then ported to the flash memory of the ATmega8 microcontroller via USB interface. The project is created with subroutine modules for sensor indicator digitization, engine transfer and valve hand-off control, remote information procurement and transmission, and universal and asynchronous receive and transmit (UART). Analog to digital converter (ADC)is used for converting signals from analog format to digital format.. The microcontroller ADC performs cyclic scans of those sensors. The check rate is programmable and can be adaptive based on the rate of vary of sensor readings.
The sensors information might be contrasted and set-point qualities put away in memory. Serial correspondence at 9600 baud rate is carried out and information is given to GSM transceiver which transmits information to collector by means of GSM remote system. The recipient station receives the information and goes to PC at baud rate of 9600 bps and Crystal_frequency_in_hz 12000000 serial interface. Information obtaining and transformation of crude information is carried out by utilizing ARM processor utilizing IAR 5.4_2 KICK.

GSM network communication software
In this paper we implemented the GSM communication protocol for sending the data from transmitter to the receiver. It covers long range and directly send the data to databases or Farmers mobile Phones. The GSM (shown in Tab.1) modems are placed at both sides of transmitter and receiver. The Transmitter needs to start working first. After power is switched on, it initializes the protocol stack and then performs energy detection; it selects the appropriate channel and starts the GSM modem. Then sensor nodes can be connected, accepted and the transmission of sensor data from each node to PC is done. Transmitter process flow diagram is shown in Fig. 5. After power is switched on, the sensor nodes does the first scan, looks for a transmitter and then establishes a connection with microcontroller. If the connection is successful, it synchronizes through the microcontroller to the transmitter, and collects the parameter by collection cycle, and finally sends the measurements to the receiver station. Receiver process flow diagram is shown in Fig. 6.

Monitoring interface software
For this project IAR 5.4_2 KICK software development environment has been chosen. It gives powerful comprehensive group of software tools and functional libraries for analysis, presentation and data acquisition. To develop data acquisition, analysis and presentation to interactively IAR 5.4_2 KICK flexibility to provides all these libraries in C language and easy to use tools for design of aqua monitoring system. It consists driver software's, flash magic libraries, Analog to digital converter programs, sensor node programming, database connectivity programs. However, IAR 5.4_2 KICK provides scalability, modularity and customization than conventional softwares. We can edit, compile, debug and link with C programs in the IAR 5.4_2 KICK development environment. On the other hand compiled C object files, dynamic linking libraries, drivers ,C libraries connected to the C source file. Aqua monitoring system have a three steps, they are data acquisition, analyzing and presentation. Hardware device gives sensing data to the data acquisition system, analyzing by the data mining tools and presentation developed in VB OR dot NET. That Graphical user interface created control to hardware device for data acquisition and also display the data. Analysis is done by performing scaling, signal processing, formatting, statistical analysis, and curve fitting. Data displayed in the form of strip charts, graphs etc. pull down menus and pop-up dialog boxes are created for giving inputs to the graphics. The user interface elements designed interactively by the GUI editor and also configure and create programmatically. Data acquisition, data analysis and user interface control by the program control. it manages the flow of program execution. IAR 5.4_2 KICK takes advantage of multithreading which benefits data acquisition and instrumental control applications including improved responsiveness, throughput and more efficient background processing. Task can be divided as multithreads. Sometimes when the lowest priority thread is executing, it is interrupted by the highest priority thread. Then the lowest priority thread goes into wait queue. Thread switches are performed by the operating system. The total waiting time is reduced through input/output operations are performed simultaneously. It improves the multiprocessor performance by making each processor to execute a thread. So, more than one task can be executed simultaneously. For example acquiring data, analyzing the data and present the analyzed data on the graphical user interface .
It includes a pH monitor, water temperature monitor, and humidity monitor. In addition, it displays graphical and numerical values of all monitored data in real time. The archive management module is responsible for storing and maintaining previous l data in aquaculture. Sensor nodes gives data to the database for the store the fundamental data and generates reports in word spreadsheet, option for performing calibration of sensors, indicates the status of output relays and network status, and provides help option in daily production.

System implementation
The system(shown in Fig.7 & 8) was implemented in Gudlavalleru, Krishna district. Intensive aquaculture monitoring system acquire the data from March-15 2014 to September-10,2014. This system observes for the appropriate operation of the system and assesses the feasibility. The pond area is 3 acres, divided into four fish ponds. Four sensors nodes were deployed in fish pond. Water inside and outside temperature sensors, pH sensor and humidity sensors were installed as input devices at transmitter node. The system was tested connecting the sensors to the modules and the receiver node to the monitoring computer in the control room, installation of sensor nodes in the fish ponds and their operation. 7.Installation of Transmitter station at pond Fig. 8. Receiver Station

Results and discussion
Storing data in the database ( Fig.9.b) of aquaculture environmental information sent from each sensor nodes in real time and also monitoring data show in Fig.9.a so that the user can have access to aquaculture environmental information. Information can be displayed as graph (Fig.11-15), or opened as datasheet with which user can understand the condition of aquaculture environment and take suitable action for any feasible problems in appropriate time. The database for storing sensor values consists of one table for all sensors where the index, date, time and sensor values are stored. The monitoring program can be configured to store data every selected time interval in seconds. The monitoring program displays an instrument panel with the latest values stored into the database and automatically updates to display the new values The measured data change consistently and reasonably reflecting the values from field sensors. Fig.10.the graphical user interface was designed in VB and .NET, so that farmers and investigators can observe, investigate and analyze the related data. The user interface allows us to convey the analyzed data in the form of a message to the farmers in their respective local languages to their Mobile Phones and alerts them in unhygienic environmental conditions. With this even semi-literate farmers can interact with the system and can understand the information in order to take suitable actions.  Table.2. shows the statistical performance of our system for various parameters in six months. Fish mortality reduced significantly and environmental parameters were ascertained in real-time and as a result optimum condition suitable for fish growth and disease reduction were achieved. The standard deviation of all measurements is also shown. In our deployment, we used manual measurement of humidity, pH and water inside/outside temperature to verify the data. The results are not shown but were matching well. Dissolved oxygen level was constant at night sustained by aerator pumps. However, during the day most of the time the aerator pumps was idle, due to enough humidity level depending on daily weather. In some cases especially on cloudy days, even during the day the ponds humidity level had to be sustained by aerator pumps. The relays were working properly at each node. Remote actuation of water valve and aerator pump was successfully operated by the wireless networks. That representing that the firmware and software were properly operated. They were automatically switching on/off whenever the parameters were outside preset range. The status light emitting diodes (LEDs) at the GUI were used to indicate the status of GSM communication, data transmission, relay states and terminal states. The latest parameters at each terminal were displayed in numerical and graphical by selecting the respective parameter of interest. The control dialog allows selecting of terminal number for performing data acquisition on and plotting graph in real-time. Additional functions of the system for performing sensor calibration, data saving, report generation and help options were functioning properly. It also allows manual starting and stopping the relays by pressing the relay knobs in respective positions. Communication range depends on transmitter and receiver parameters, the output power of the transmitter and the sensitivity of the receiver and several external parameters. These parameters includes the physical environment particularly objects in or close to communication path which result in multipath propagation, signal scattering and attenuation as well as other interference sources. The communication range decreases as the quantity of tall buildings, trees and foliage near the fishponds increases. The presence of vegetation appears to impair communication by reducing the span of the connected area. Sometimes short outages occurred because of heavy rain and thunderstorms causing signal cutoff. When the system reset was done the signal got well operating normally. Water inside and outside temperature, dissolved oxygen and pH were regularly monitored by this system. For example, water characteristics were maintained at best levels that is pH level is maintained between 4 to 10. The smart sensor nodes are small, low cost, efficient and suitable for deployment in harsh environment. The nodes were protective watertight housing and weatherproof. Making it resistant to environmental factors like rain and heat. It was easy to move the nodes to the desired point of interest whenever needed. The experimental results reported in this work show that the power management and networking solutions were adopted to work in practice. This increased economic benefit for aquaculture by improving production process in quality and quantity, consumer confidence and safety. This system could prove to be helpful in the event of a failure to take rapid actions to prevent the damage that could be caused to the fish stock.

Conclusions
A wireless sensor network for aquaculture monitoring and control based on virtual instruments is presented. In addition, a detailed hardware design of the smart sensor nodes and transmitter/receiver with their software design is also presented. Finally, the prototype system with four smart sensor nodes and a transmitter/receiver is designed and implemented. The collected data provides an accurate analysis of successful operation of the system. This work can be used in various application areas such as greenhouse monitoring and control, hydrological water conservation and farmland irrigation. Future development efforts should involve enhancing the WSN by adding GPRS modules on the smart sensor nodes in order to monitor aquaculture environment on-line through the internet. The monitoring program should be linked to the web server through a passive IP address in one port of the receiving computer, thus making the architecture more scalable and robust.