Content uploaded by Azam Rafique
Author content
All content in this area was uploaded by Azam Rafique on Dec 01, 2016
Content may be subject to copyright.
Proceedings of the 10th INDIACom; INDIACom-2016
3rd 2016 International Conference on “Computing for Sustainable Global Development”, 16th – 18th March, 2016
Bharati Vidyapeeth’s Institute of Computer Applications and Management (BVICAM), New Delhi (INDIA)
Internet of Things (IoT) Enabled Smart Animal Farm
Muhammad Hunain Memon,
Wanod Kumar, Azam Rafique
Memon, Bhawani S. Chowdhry
Department of Electronic Engineering,
Mehran University of Engineering &
Technology, Jamshoro, Pakistan
Email Ids: hunain_memones@yahoo.com,
wanod.kumar@faculty.muet.edu.pk,
azam.memon@admin.muet.edu.pk,
bhawani.chowdhry@faculty.muet.edu.pk
Muhammad Aamir
Department of Electronic Engineering,
Sir Syed University of Engineering &
Technology, Karachi, Pakistan
Email Id: muaamir5@gmail.com
Pardeep Kumar
Department of Computer System
Engineering, Quaid-e-Awam University
of Engineering Science & Technology
Nawabshah, Pakistan
Email Id: pardeep.kumar@quest.edu.pk
Abstract – Farming plays an important role in today’s world
and it requires proper environmental and diet care. A smart
system is needed to operate and monitor animal farm
remotely. This system should provide feed and water as
required, exhaust the excess of biogas which is produced by
the animals’ waste, and detect fire in the farm. Moreover, this
intelligent system should also do surveillance of the entire
farm. This kind of intelligent system can be designed cost
effectively by using microcontrollers, water level sensor,
ultrasonic sensor, gas sensor, temperature, humidity sensor,
and an IP Camera along with Internet or Intranet
connectivity with the devices i.e. smart phones or computer.
In this paper, we develop an IoT based smart animal farm
with above mentioned features.
Keywords – Internet of Things, Animal, Smart, Animal Farm.
I. INTRODUCTION
There has been strong relationship between humans and
animals throughout the centuries. We depend on animals in
many aspects of life such as sports, food, clothes and other
product that support and facilitate our living. Therefore a good
care of animals is very important. The livestock industry could
greatly be benefitted from a sophisticated system capable of
continuously monitoring the health of animals, aggregating the
data and reporting the obtained results to owners and regional
[1].
The term Internet of Things (IoT) was first defined by Kevin
Ashton in 1999 [2]. It is a new paradigm about the ability of
connected devices to sense and gather data, and then share that
data using the Internet facility so that it can be processed and
utilized to fulfill common goals [3]. IoT refers to a technology
that tells that in near future billions of devices will have intent
connectivity and can be accessed from anywhere in the world.
According to [4], there can be many IoT enabled applications
such as smart parking, smart animal farm, smart waste
management system etc.
Stock theft has been a main problem in the agricultural sector
in many countries around the world and threatens both
commercial and the emerging farming sectors. In [5] authors
carry out investigation about cow behavior modeling using
global positioning wireless nodes to acquire the probable
position of a cow. A WSN node was designed to sense the
speed and position of a cow to determine the presence of a
thief. The position and the speed of the cow were collected for
analysis purpose.
In [6], a water management model integrating Internet of
Things (IoT) technologies has been developed. The proposed
smart water management model makes specific vendor
equipment interoperable and manageable in a water
management domain in a homogeneous way.
We in this paper design a complete system which is comprised
of feed filling system, water filling system, incubator system,
biogas exhaust system, fire detecting system and an IP camera.
The data from the system is transmitted and received by a
certain IP address and port address using a WIFI router to the
GUI of the system. The system can be controlled and
monitored using the GUI of the system. Moreover, it has two
modes of operation manual and as well as an automatic. Our
designed system considers almost all parameters which are
important for an animal farm compared to the readily available
systems which only consider a few parameters. Hence, in this
sense our complete system becomes a novel design.
Following the introduction paper is organized as follows:
Section II discuss the system design. The operation of the
system is described in Section III. Results are given in Section
IV. The paper concludes in Section V.
II. SYSTEM DESIGN
We discuss complete system design in two main parts; i.e.
hardware design and software design.
Proceedings of the 10th INDIACom; INDIACom-2016
3rd 2016 International Conference on “Computing for Sustainable Global Development”, 16th – 18th March, 2016
A. Hardware Description
The designed system mainly consists of two modules;
embedded system module and Ethernet communication
module. The first module contains Water level sensor, Biogas
Sensor, temperature and humidity sensor, fire sensor and two
microcontrollers (i.e. Arduino mega and Arduino Uno) which
are placed in the animal farm to sense the system parameters.
The data is transmitted by Ethernet shield through WIFI using
UDP. The embedded system module acquires information of
the animal farm and maintains the record and performs
respective function in real time. It has two modes of operation;
i.e. automatic mode and manual mode. If the system is in
automatic mode, the system operates according to the
programmed threshold values and keeps on giving feedback
through GUI on Certain IP. Moreover, if the System is in
manual mode it is controlled manually using switches in GUI.
This smart animal farm consists of subsystems which are Bio
Gas Control System, Feed Control System, Incubator Control
system, IP Camera, Fire Detecting System, and Water Control
System. Complete system is shown in Fig. 1.
Fig. 1. Complete System Block Diagram
a) Bio Gas Control System
Animals’ waste causes biogas emission which can be harmful
to them. To get rid of it, we have designed an exhaust system
which will let the bio gas emit out from the farm. Exhaust
system having fan which turns on when bio gas level is
detected using the gas sensor. It works automatically if the
system is in automatic mode, however one can turn it on/off
manually by transmitting control signal from GUI to processing
unit using WIFI. The system block diagram is shown in Fig. 2.
Fig. 2. Bio Gas Control System
b) Feed Control System
Feed control system consists of hopper storage and feed
storage. The hopper storage have a valve which is turned on
using stepper motor and the feed storage having ultrasonic
sensor which is used to sense the level of feed. As the level of
feed decreases the hoper valve turns on so that feed can be
filled. The system block diagram is shown in Fig. 3.
Fig. 3. Feed Control System
Internet of Things (IoT) Enabled Smart Animal Farm
c) Incubator Control System
Incubator box consists of a temperature Sensor, a humidity
sensor, a heater, and a fan. Sensors sense the humidity and
temperature of the incubator according to predefined conditions
and subsequently either heater or fan is turned on or off. The
system block diagram is shown in Fig. 4.
Fig. 4. Incubator Control System
d) IP Camera based Surveillance System
We have used an Android cell phone as an IP camera using
application “IP Cam”. This application is connected with same
WIFI router to have IoT based system. Fig. 5 shows block
diagram of IP camera based surveillance system.
Fig. 5. IP Camera based Surveillance System
e) Fire Detecting System
Fire detecting system consists of fire sensor module and an
alarm. When a fire sensor module detects the fire in the
system it turns on alarm if the System is in automatic mode so
one can rescue animals. Fire sensor also gives an indication to
GUI through WIFI. The alarm buzzer can be controlled
manually as well in an emergency condition. Block diagram of
Fire Detecting System is shown in Fig. 6.
Fig. 6. Fire Detecting System
Fig. 7. Water Level Control System
f) Water Level Control System
Water level control system has water level sensor and a water
pump. Water level sensor senses the level of the water in the
Proceedings of the 10th INDIACom; INDIACom-2016
3rd 2016 International Conference on “Computing for Sustainable Global Development”, 16th – 18th March, 2016
container and when the water level goes down to the minimum
point (say point 1) then water pump is turned on to fill the
water tank. The readings are also shown using GUI. Block
diagram of water level control system is shown in Fig. 7.
B. System Software
The monitoring and controlling takes place by receiving and
transmitting the data over a specific IP address and port address
using User Datagram Protocol (UDP). LabVIEW software is
used for making a GUI of an IoT enabled smart animal farm.
LabVIEW provides a very good platform for any measurement
or control system. GUI consist of switches and different
measuring scales that keep on receiving data from the
environment using WIFI, whereas switches are used to control
the system manually.
a) Active X Controller
ActiveX Event callback for IE is used in GUI which displays
an IP Camera result of the video feedback acquired from farm
[7]. LabVIEW block diagram is shown in Fig. 8.
Fig. 8. Active X Controller
b) UDP Communication in GUI
User Datagram Protocol (UDP) provides a means for
communicating short packets of data [8]. The Data is sent in
multiple packets and these packets arrive at the destination in
the order they were sent. The receiving data over UDP gets
concatenated and is shown in the panels of GUI of the system
i.e. humidity, temperature. LabVIEW block diagram of UDP
communication in GUI is shown Fig. 9 (a) and Fig. 9 (b).
Fig. 9(a). UDP Communication in GUI
Fig. 9(b). UDP Communication in GUI
c) GUI Representation
GUI is having an IP Camera panel, vertical progress bar to
indicate fire, vertical tank bar to indicate water level in tank, a
numeric gauge to indicate bio-gas, a vertical yellow tank to
indicate feed in tank, a humidity bar and a thermometer bar to
indicate humidity and temperature respectively.
Complete system of animal farm will keep on giving readings
of the environment by using sensors to a processing unit.
Processing unit will have certain IP and port address
(ie.XXX.XXX.XXX.XXX:8888). IP camera has a certain IP
and port address (ie.XXX.XXX.XXX.XXX:8888) that is
connected to a central router which transmits data to a desired
IP and port by which this system can be monitored and
controlled.
For operating this GUI, a device such as computer/laptop
needs to be connected with the same LAN with which the
system is connected. After successful configuration, the
system will start to acquire data on a certain IP and port
address. Using GUI, system can be monitored and controlled
in two modes (i.e. automatic mode and manual mode).
Complete GUI of the system is shown in Fig. 10.
Internet of Things (IoT) Enabled Smart Animal Farm
Fig. 10. System GUI
III. SYSTEM OPERATION
The complete system operation is shown in system flowchart in
Fig. 11.
Fig. 11. System Operational Flow Chart
The complete system operates as described below:
If the biogas indication is less than threshold value it will
not turn on exhaust system. If it becomes more than a
threshold value it will start an exhaust system.
If the feed in the container is less than a threshold value or
a certain quantity then system turns on the feed valve to
maintain up to a specified level.
If the temperature and humidity of the incubator is less
than a threshold value, the system turns on heater.
Otherwise fan is used to maintain the humidity.
IP camera keeps providing a continuous video feed to the
GUI panel.
If the fire sensor value goes below the threshold value,
system turns on an alarm.
Finally, if the water level becomes below the threshold
value, the system turns on the water pump.
The system is monitored and controlled remotely in
continuous fashion to ensure the provisioning of proper care
and diet to the animals using Internet facility.
IV. RESULTS
Results related to humidity, and temperatures are shown
hourly basis in Fig. 12 and Fig. 13 respectively.
The humidity of the system is low in day time hours as shown
in Fig. 12. It rises especially in evening hours. The results
reveal that it can be maintained using this smart system.
Fig. 12. Humidity Data on Hourly Basis
Fig. 13 shows that the temperature of incubator can be
stabilized using heater and fan. The continuous data from the
temperature sensor is used to maintain the temperature of the
system.
Proceedings of the 10th INDIACom; INDIACom-2016
3rd 2016 International Conference on “Computing for Sustainable Global Development”, 16th – 18th March, 2016
Fig. 13. Temperature Data on Hourly Basis
V. CONCLUSION
In this paper we have designed an IoT enabled smart animal
farm. This is a cost efficient system and is built with a cost of
USD300. It continuously monitors the physical parameters of
an animal farm. It can be controlled manually as well as
automatically. This kind of system is suitable for any kind of
animal farm with little modifications.
REFERENCES
[1] Smith, K.; Martinez, Angel; Craddolph, R.; Erickson, H.;
Andresen, D.; Warren, S., "An Integrated Cattle Health
Monitoring System," in 28th IEEE Annual International
Conference of the Engineering in Medicine and Biology
Society, pp.4659-4662, 2006.
[2] Gubbi, J.; Buyya, R.; Marusic, S.; Palaniswami,M.
"Internet of Things (IoT): A vision, architectural elements,
and future directions," Future Generation Computer
Systems, vol. 29, no. 7, 2013, pp. 1645-1660
[3] Atzori, L.; Iera, A.; Morabito, G., "The Internet of Things:
A survey, " Computer Networks, vol. 54, no.15, 2010, pp.
2787-2805.
[4] Applications of IoT,
http://www.libelium.com/top_50_iot_sensor_applications_ra
nking/
[5] Mashoko Nkwari, P.K.; Rimer, S.; Paul, B.S., "Cattle
monitoring system using wireless sensor network in order to
prevent cattle rustling," in IST-Africa Conference
Proceedings, pp.1-10, 7-9 May 2014
[6] Robles, T.; Alcarria, R.; Martin, D.; Morales, A.; Navarro,
M.; Calero, R.; Iglesias, S.; Lopez, M., "An Internet of
Things-Based Model for Smart Water Management," in 28th
International Conference on Advanced Information
Networking and Applications Workshops (WAINA), pp.821-
826, 13-16 May 2014.
[7] ActiveX and LabVIEW, Report published on Oct 07, 2015,
http://www.ni.com/white-paper/2983/en/
[8] UDP Communication in LabVIEW, Report published on
Sep 06, 2006,
http://www.ni.com/tutorial/4950/en/