CHILD SAFETY ASSISTANT SYSTEM (FINAL REPORT)

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 65

CHILD SAFETY ASSISTANT SYSTEM

A project Report submitted


in the partial fulfillment for the award of the degree of

BACHELOR OF TECHNOLOGY
in
COMPUTER SCIENCE AND ENGINEERING
By

ADITYA SURENDRA TRIPATHY (U18CN234)


SHAHBAZ ALI MIKRANI (U18CN222)
SHEMPHANG RYNTATHIANG (U18CN224)
VISHAL KUMAR (U18CN187)

Under the guidance of


DR. N.NITHIYANANDAM

DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING


SCHOOL OF COMPUTING
BHARATH INSTITUTE OF HIGHER EDUCATION AND RESEARCH
(Deemed to be University Estd u/s 3 of UGC Act, 1956)

CHENNAI 600 073, TAMILNADU, INDIA

April,2022

Page 1 of 55
CERTIFICATE

This is to certify that the project report entitled Child Safety Assistant System submitted
by ADITYA SURENDRA TRIPATHY, SHAHBAZ ALI MIKRANI, SHEMPHANG
RYNTATHIANG, VISHAL KUMAR to the Department of Computer Science and Engineering,
Bharath Institute of Higher Education and Research, in partial fulfillment for the award of the
degree of B. Tech in (Computer Science and Engineering) is a bona fide record of project work
carried out by them under my supervision. The contents of this report, in full or in parts, have not
been submitted to any other Institution or University for the award of any other degree.

<SIGNATURE>
DR.N.NITHIYANANDAM
Department of Computer Science and Engineering,
School of Computing,
Bharath Institute of Higher Education & Research,
April2022,

<SIGNATURE OF HEAD OF THE DEPARTMENT>


Dr. B. Persis Urbana Ivy
Professor &Head ,
Department of Computer Science and Engineering,
School of Computing,
Bharath Institute of Higher Education & Research,
April2022,

Page 2 of 55
DECLARATION

We declare that this project report titled Loan approval system based on machine learning approach
submitted in partial fulfillment of the degree of B. Tech in (Computer Science and Engineering) is a
record of original work carried out by us under the supervision of DR. N.NITHIYANANDAM and
has not formed the basis for the award of any other degree or diploma, in this or any other
Institution or University. In keeping with the ethical practice in reporting scientific information, due
acknowledgements have been made wherever the findings of others have been cited.

ADITYA SURENDRA TRIPATHY

(U18CN234)

SHAHBAZ ALI MIKRANI

(U18CN222)

SHEMPHANG RYNTATHIANG

(U18CN224)

VISHAL KUMAR

(U18CN187)

CHENNAI

23/04/2022

Page 3 of 55
ACKNOWLEDGMENTS

First, we wish to thank the almighty who gave us good health and success throughout our

project work.

We express our deepest gratitude to our beloved President Dr. J. Sundeep Aanand, and Managing

Director Dr.E. Swetha Sundeep Aanand for providing us the necessary facilities for the completion of our
project.

We take great pleasure in expressing sincere thanks to Vice Chancellor (I/C) Dr. K. VijayaBaskar Raju,
Pro Vice Chancellor (Academic) Dr. M. Sundararajan, Registrar Dr. S. Bhuminathan and Additional Registrar
Dr. R. Hari Prakash for backing us in this project.We thank our Dean Engineering Dr. J. Hameed Hussain
for providing sufficient facilities for the completion of this project.

We express our immense gratitude to our Academic Coordinator Mr. G. Krishna Chaitanya for his
eternal support in completing this project.

We thank our Dean, School of Computing Dr. S. Neduncheliyan for his encouragement and the valuable
guidance.

We record indebtedness to our Head, Department of Computer Science and Engineering Dr. B.
Persis Urbana Ivy for immense care and encouragement towards us throughout the course of this project.

We also take this opportunity to express a deep sense of gratitude to our Supervisor
DR. N.NITHIYANANDAM for her cordial support, valuable information and guidance, she
helped us in completing this project through various stages.

We thank our department faculty, supporting staff and friends for their help and guidance to
complete this project.

ADITYA SURENDRA TRIPATHY (U18CN234)

SHAHBAZ ALI MIKRANI (U18CN222)


SHEMPHANG RYNTATHIANG (U18CN224)
VISHAL KUMAR (U18CN187)

Page 4 of 55
ABSTRACT

An average of 38 children dies each year in hot cars, seemingly forgotten by a

distracted parent. This project gives full safety to the children who is being locked in

an unattended vehicle. The proposed system implements a touch sensor, infrared

sensors and DH11sensor.These acquisition devices are connected to a

microcontroller board that is able to combine all acquired data for detecting the

alarm scenario. Consequently, acting some warning procedures and sends alert

messages to user with the help of GSM module. Finally, the data will be updated in

IOT.

5
TABLE OF CONTENT
CHAPTER TITLE PAGE NO
NUMBER
ABSTRACT iv
LIST OF FIGURES vii
LIST OF ABREVIATIONS viii
1 INTRODUCTION 1
1.1 EMBEDDED SYSTEM 2
1.1.1 EMBEDDED SYSTEM HARDWARE 2
1.1.2 EMBEDDED SYSTEM SOFTWARE 3
1.1.3 EMBEDDED FIRMWARE 4
1.1.4 EMBEDDED SYSTEM VS VLSI 4
1.1.5 DEBUGGGING EMBEDDED SYSTEM 4
1.1.6 THE INTERNET OF THINGS 5
2 LITERATURE REVIEW 7
3 PROJECT DESCRIPTIONS 10
3.1 EXISTING SYSTEM 10
3.1.1 DISADVANTAGES 12
3.2 PROPOSED SYSTEM 12
3.3 BLOCK DIAGRAM 13
3.4 CIRCUIT DIAGRAM
3.5 HARDWARE REQUIREMENTS 14
3.5.1 ARDUINO UNO 15
3.5.1.1 ARDUINO BOARD 15
3.5.1.2 FEATURES OF ARDUINO 15
3.5.2 IR SENSOR 16
3.5.2.1 DIFFERENT TYPES OF IR SENSORS 17
3.5.2.2 IR SENSOR APPLICATION 17
3.5.3 TOUCH SENSOR 18

3.5.3.1 WORKING PRINCIPLE OF TOUCH 10


SENSOR
3.5.3.2 APPLICATIONS 12

6
3.5.4 DHT11 SENSOR 12
3.5.5 GSM 13
3.5.5.1 FEATURES OF GSM MODULE 14
3.5.5.2 GSM MODEM 15
3.5.5.3 WORKING OF GSM MODEM 15
3.5.5.4 INTELLIGENT GSM DEVICE FOR 15
AUTOMATION AND SECURITY
3.5.6 ESP8266 MODULE 16
3.5.6.1 FEATURES 17
3.5.6.2 ESP8266-01 WIFI MODULE 17
3.5.7 SERVO MOTOR 18
3.5.7.1 MECHANISM
3.5.7.2 CONTROLLING A SERVO MOTOR
3.5.7.3 ADVANTAGES
3.5.7.4 TYPES OF SERVO MOTOR
3.5.8 POWER SUPPLY UNIT
3.5.8.1 CIRCUIT DESCRIPTION
3.6 SOFTWARE REQUIREMENTS
3.6.1 ARDUINO IDE
3.6.2 EMBEDDED C
3.6.2.1 PROGRAMMING EMBEDDED SYSTEM
3.6.2.2 FACTORS FOR SELECTING THE
PROGRAMMING LANGUAGE
3.6.2.3 DIFFERENCE BETWEEN C AND
EMBEDDED C
4 RESULT & DISCUSSION
4.1 CODING FOR THE SYSTEM
4.2 WORKING OF THE SYSTEM
5 CONCLUSION
REFERENCES

LIST OF FIGURES

FIG NUMBER TITLE PAGE NO


7
1.1 EMBEDDED SYSTEMS iv
1.2 EMBEDDED SYSTEM APPLICATIONS viii
3.3 BLOCK DIAGRAM
3.1 ARDUINO UNO 1
3.2 ARDUINO UNO WITH DIGITAL INPUT/OUTPUT 1
3.3 PIN DIAGRAM OF ARDUINO UNO 1
3.4 IR SENSOR 3
3.5 TOUCH SENSOR 4
3.6 DHT11 SENSOR 4
3.7 GSM MODEM 4
3.8 GSM MODEM CIRCUIT
3.9 ESP8266 MODULE
3.10 DC SERVO MOTOR
3.11 AC SERVO MOTOR
3.12 CONTINUOUS ROTATION SERVO MOTOR
3.13 LINEAR SERVO MOTOR
3.14 BLOCK DIAGRAM OF POWER SUPPLY
3.15 PROCESSING OF POWER SUPPLY
3.16 POWER SUPPLY CIRCUIT DIAGRAM
3.17 ARDUINO IDE 1
3.18 BUTTON BAR
3.19 ARDUINO IDE 2
4.1 DEMO WORKING MODEL
4.2 TOUCH SENSOR
4.3 IR SENSOR
4.4 GSM MODULE AND POWER SUPPLY
4.5 DHT11 SENSOR
4.6 ARDUINO UNO
4.7 ESP8266 MODULE
4.8 IR SENSOR BEFORE DETECTING MOTION
4.9 IR SENSOR AFTER DETECTING MOTION
4.10 TOUCH SENSOR BEFORE SENSING TOUCH
4.11 TOUCH SENSOR AFTER SENSING TOUCH
4.12 SCREENSHOT OF IOT CLOUD DATA
8
4.13 SCREENSHOT OF ALERT MESSAGE SEND TO
USER

LIST OF ABREVIATIONS
GSM GLOBAL SYSTEM FOR MOBILE COMUNICATIONS
IOT INTERNET OF THINGS
CPU CENTRAL PROCCESSING UNIT
SoT SYSTEM ON A CHIP
ROM READ ONLY MEMORY
VLSI VERY LARGE-SCALE INTEGRATION
IR INFRA RED
ICSP IN-CIRCUIT SERIAL PROGRAMMING
TCP/IP TRANSMISSION CONTROL PROTOCOL/INTERNET PROTOCOL
RAM RANDOM ACCESS MEMORY
PID PROPORTIONAL-INTEGRAL-DERIVATIVE

9
CHAPTER 1

INTRODUCTION

Every summer, there are some children who have been forgotten in the car and
died due to heatstroke. Some careless parents have forgotten to take the children
out, and finally the irreparable tragedy happens. Just in the United States, 52
children died in 2018 and 43 children died in 2017 because of heatstroke in
vehicle, and the majority of these in-car heatstroke deaths are accidents that are
preventable. In recent years, the number of heatstroke deaths of children in
vehicles is still increasing. How to remind these careless parents is an urgent
problem to solve. An effective solution to these preventable tragedies is to
effectively detect rear seat children, and send a prompt and accurate alert to their
parents. There exist some techniques in the market or in the literature to remind
parents of the children left in the rear seat. The most common way is to install a
pressure sensor under the car seat, but it cannot distinguish between heavy stuff
(e.g., grocery items) and the child in the rear seat. Thus, it may send annoying false
alarms. Another option is to install a 2-D surveillance camera in the vehicle.
According to the image captured by the camera, it can easily analyze whether the
children are left unattended in a parked car or not. Even though with high accuracy
for alerts, all of the activities in the car will be exposed to the camera, which may
lead to the privacy leakage of the driver and passengers. Some other works try to
detect the baby by using the infrared cameras. However, it cannot detect the baby
when the interior environment is already heated in hot summer. Recently, DeWald
et al. in propose an RF-based baby detection system, but additional expensive
devices such as CW-radar are needed.

1.1 EMBEDDED SYSTEM

1
Some examples of embedded systems are MP3 players, mobile phones, video
game consoles, digital cameras, DVD players, and GPS. Household appliances,
such as microwave ovens, washing machines and dishwashers, include embedded
systems to provide flexibility and efficiency.

1.1.1. Embedded system hardware (microprocessor-based, microcontroller-


based)
An embedded system is a microprocessor- or microcontroller-based system of
hardware and software designed to perform dedicated functions within a larger
mechanical or electrical system. The hardware of embedded systems is based
around microprocessors and microcontroller. It has software known as Real time
operating system (RTOS) that rapidly switches between tasks, giving the
impression that multiple programs are being executed at the same time on a single
processing core.

FIG 1.1 EMBEDDED SYSTEMS


A micro controller has a specific amount of program and data memory as well as
I\O ports built within the architecture along with the CPU, making it a complete

2
system. As a result most embedded system are micro controller based ,where are
used to run one or limited number of applications.
The embedded market was estimated to be in excess of $140 billion in 2013, with
many analysts projecting a market larger than $20 billion by 2020. Manufacturers
of chips for embedded systems include many mainstays of the computer world,
such as Apple, IBM, Intel and Texas Instruments, as well as numerous other
companies less familiar to those outside the field. Arm has been a highly
influential vendor in this space. The company began as an outgrowth of Acorn, a
U.K. maker of early PCs. Arm chips, produced under license by other companies,
are based on the reduced instruction set computer (RISC) architecture and are often
used in mobile phones; they remain the most widely deployed SoC in the
embedded world, with billions of units fielded.

1.1.2. Embedded system software

A typical industrial microcontroller is unsophisticated compared to the typical


enterprise desktop computer and generally depends on a simpler, less-memory-
intensive program environment. The simplest devices run on bare metal and are
programmed directly using the chip CPU's machine code language.

3
FIG 1.2 EMBEDDED SYSTEM APPLICTIONS

Often, embedded systems use operating systems or language platforms tailored to


embedded use, particularly where real-time operating environments must be
served. At higher levels of chip capability, such as those found in SoCs, A typical
industrial microcontroller is unsophisticated compared to the typical enterprise
desktop computer and generally depends on a simpler, less-memory-intensive
program environment. The simplest devices run on bare metal and are programmed
directly using the chip CPU's machine code language.

Often, embedded systems use operating systems or language platforms tailored to


embedded use, particularly where real-time operating environments must be
served. At higher levels of chip capability, such as those found in SoCs,

4
have increasingly decided the systems are generally fast enough and the tasks
tolerant of slight variations in reaction time that near-real-time approaches are
suitable. In these instances, stripped-down versions of the Linux operating system
are commonly deployed, although other operating systems have been pared down
to run on embedded systems, including Embedded Java and Windows IoT
(formerly Windows Embedded).

Generally, storage of programs and operating systems on embedded devices make


use of either flash or rewritable flash memory.

designers have increasingly decided the systems are generally fast enough and the
tasks tolerant of slight variations in reaction time that near-real-time approaches
are suitable. In these instances, stripped-down versions of the Linux operating
system are commonly deployed, although other operating systems have been pared
down to run on embedded systems, including Embedded Java and Windows IoT
(formerly Windows Embedded).

Generally, storage of programs and operating systems on embedded devices make


use of either flash or rewritable flash memory.

1.1.3. Embedded firmware

The firmware on embedded systems, referred to as embedded firmware, is specific


software written into the memory of a device that serves the purpose of ROM, but
can be updated more easily. Firmware can be stored in non-volatile memory
devices including ROM, programmable ROM, erasable PROM or flash memory.
Embedded firmware is used to control various device and system functions, for
example, telling the device how to communicate with other devices, perform

5
specific functions and provide input and output functionality.

The delineation between the terms embedded firmware and embedded software are
blurring, but embedded software often refers to the only code running on a piece of
hardware, while firmware can also refer to the chip that houses a device's basic
input/output system (BIOS) or Unified Extensible Firmware Interface (UEFI),
which connect software and a system's operating system.

1.1.4. Embedded systems vs. VLSI

Very-large-scale integration, or VLSI, is a term that describes the complexity of an


integrated circuit. VLSI is the process of embedding hundreds of thousands of
transistors into a chip, whereas LSI (large-scale integration) microchips contain
thousands of transistors, MSI (medium-scale integration) contain hundreds of
transistors, and SSI (small-scale integration) contain tens of transistors. ULSI, or
ultra-large-scale integration, refers to placing millions of transistors on a chip.

VLSI circuits are common features of embedded systems. Many ICs in embedded
systems are VLSI, and the use of the VLSI acronym has largely fallen out of favor.

1.1.5. Debugging embedded systems

One area where embedded systems part ways with the operating systems and
development environments of other, larger-scale computers is in the area
of debugging. While programmers working with desktop computer environments
have systems that can run both the code being developed and separate debugger
applications that monitor the actions of the development code as it is executed,
embedded system programmers generally cannot.

6
Some programming languages run on microcontrollers with enough efficiency that
rudimentary interactive debugging is available directly on the chip. Additionally,
processors often have CPU debuggers that can be controlled -- and, thus, control
program execution -- via a JTAG or similar debugging port.

In many instances, however, programmers of embedded systems need tools that


attach a separate debugging system to the target system via a serial or other port. In
this scenario, the programmer can see the source code on the screen of a
conventional personal computer just as would be the case in the debugging of
software on a desktop computer. A separate, frequently used approach is to run
software on a PC that emulates the physical chip in software, thus making it
possible to debug the performance of the software as if it were running on an
actual, physical chip.

Broadly speaking, embedded systems have received more attention to testing and
debugging because a great number of devices using embedded controls are
designed for use in situations where safety and reliability are top priorities.

1.1.6. The internet of things

While some embedded systems can be relatively simple, a growing number either
supplant human decision-making or offer capabilities beyond what a human could
provide. For instance, some aviation systems, including those used in drones, are
able to integrate sensor data and act upon that information faster than a human
could, permitting new kinds of operating features.

7
CHAPTER 2
LITERATURE SURVEY
M. Vamsi et al. [1] “IN-VEHICLE OCCUPANCY DETECTION AND
CLASSIFICATION USING MACHINE LEARNING” Occupancy detection is
a difficult problem. There are several mechanisms exists for occupancy detection
in vehicles, particularly in Automobiles. Now, safety has become an important and
necessary aspect of the automobile industry. Airbag became a basic and important
safety measure in cars. Even though airbag is a vehicle safety device, it can kill
children below 12 years due to its rapid action by the exerting lot of force. This
project explains about detecting the number of passengers sitting in the car and
then classifying each person whether he/she is a child or an adult by processing the
image taken from the camera. So that the deployment of airbags can be avoided
near children. Each time car speeds from 0 Kmph to 20 Kmph, occupancy of the
car is determined and each one is classified again. We are using widely used
technique Haar Cascades, for detection. First, we detect faces and then classify
each occupant adult or child.

Joy Kuri et al. [2] “IMPLEMENTATION OF REAL-TIME PASSENGER


SAFETY ALERT SYSTEM” Car accidents are a common event in all
modernized society. However, as vehicles become more autonomous, car accidents
will slowly begin to decrease. Even with the decrease in accidents, mistakes will
still be made that cause damage to both property and persons. In an effort to reduce
the damage caused by these mistakes, the system described in this paper uses
sensors to measure features such as height and weight in order to distinguish
between adult and small child. Once the system has made the distinction, it will
inform the driver of potentially dangerous travel accommodations and recommend
the proper safety seat or harness. This paper describes the process of designing,
8
constructing, and testing the prototype of the system.
Adnan Shaout et al. [3] “CLOUD BASED SYSTEM FOR DETECTING
CHILDREN IN AUTOMOBILES” Children and infants being left in cars on hot
summer days is a major public health issue across the world. With modern sensor
and connectivity technology, it should be possible to detect these scenarios by
uploading raw data to the cloud. In the cloud, systems will be able to respond to
this data and make judgements to notify proper response personnel. We use cloud
technology to process updates from a sensor system and how it could be used to
send notifications to prevent these tragic occurrences.
K. Brolin et al. [4] “ANALYSIS ON THE DESIGN OF CHILD SAFETY
SEATS IN VEHICLE” The article analyzed the importance of the design of child
seat for vehicle, at the same time, it proposed the basic design principles and
design approach to improve the comfort and security of children. Finally, it further
analyzed of the design of child safety seats through outstanding examples. It is
increasingly long time for children to stay in the vehicle when cars come into more
and more families. It is gradually arousing people's attention that there are many
J. W. Finn et al. [5] “AN INTEGRATED CHILD SAFETY SEAT COOLING
SYSTEM—MODEL AND TEST” Vehicle safety remains a prominent
automotive issue for engineers, consumers, and government regulators. One area
that merits attention is the safety issue of when a child is left alone in a parked
vehicle during the summer months when the ambient air temperatures are warmer.
Injuries and deaths of infants, young children, and elderly adults have occurred due
to elevated body temperatures for prolonged time periods. One proposed solution
is the design of a car safety seat that offers temporary thermal protection to the
occupant. This seat features thermoelectric cooling and forced air convection to
maintain the body temperature within acceptable ranges for a limited time. In this
paper, a system thermal model and experimental results are presented to validate
9
the effectiveness of the thermoelectric-based safety system. The experimental
system demonstrates the capability of maintaining localized cabin air temperatures
below critical survivability thresholds in a closed parked vehicle for up to 95
minutes. This represents an 85% increase over standard child seating units, in
cabin temperatures up to 69°C, for an emulated 7 kg infant.
L. Zhong et al. [6] “RESEARCH ON THE EFFECT OF REAR SEAT
STRUCTURE ON CHILD OCCUPANT SAFETY” This paper aims to study
the effect of the rear seat structure on child occupant protection. According to
GB15083-2006 standard, a finite element model of luggage cabin and rear-row
seat was developed in LS-DYNA and validated via test results. The model was
used in analysis of the safety performance of rear seat structure under luggage
impact in car frontal crashes, in order to minimize the risk of child occupant injury.
A 3 years old child seat was simulated with fixing on the rear seat. Four
optimization schemes were designed in order to reduce the intrusion and
acceleration of the rear seat structure, comparing to the original model.

10
CHAPTER 3
PROJECT DESCRIPTIONS
3.1 EXISTING SYSTEM:
• In existing system, they used WIFI signals to detect the persons in car.

• In existing systems, they use camera to detect the persons, but it will affect
the user’s privacy.

3.1.1. DISADVANTAGES:
• Users’ privacy will affect if we use camera.
• Lack of integrity.
• Lack of availability and continuity of service.
• lack of accuracy

3.2 PROPOSED SYSTEM:


• In proposed system, we use touch sensor, DHT11 sensor and IR sensor to
detect the conditions.

• We use GSM module to send the alert to user.

• Buzzer will beep, when the IR sensor or touch sensor will be HIGH during
the car is locked.

• By using IOT we can monitor the data in cloud.

3.3 BLOCK DIAGRAM:

11
3.4 CIRCUIT DIAGRAM

12
HARDWARE REQUIREMENTS:
• Arduino Uno.

• IR Sensor.

• Touch Sensor

• DH11 Sensor.

• GSM Modem.

• Buzzer.

• IOT Module.

13
• Servo Motor.

• Power Supply.

SOFTWARE REQUIREMENTS:
• Arduino IDE
• Embedded C
• PHP

3.5 HARDWARE REQUIREMENTS

3.5.1. ARDUINO UNO

Arduino Uno is a microcontroller board based on the ATmega328P


(datasheet). It has 14 digital input/output pins (of which 6 can be used as
PWM outputs), 6 analog inputs, a 16 MHz quartz crystal, a USB
connection, a power jack, an ICSP header and a reset button.

It contains everything needed to support the microcontroller; simply


connect it to a computer with a USB cable or power it with a AC-to-DC
adapter or battery to get started.

There are many versions of Arduino boards introduced in the market like Arduino
Uno, Arduino Due, Arduino Leonardo, Arduino Mega, however, most common
versions are Arduino Uno and Arduino Mega. If you are planning to create a
project relating to digital electronics, embedded system, robotics, or IoT, then
using Arduino Uno would be the best, easy and most economical option.

14
FIG 3.1 ARDUINO UNO

3.5.1.1. ARDUINO BOARD

There are various types of Arduino boards in which many of them were third-party
compatible versions. The most official versions available are the Arduino Uno R3
and the Arduino Nano V3. Both of these run a 16MHz Atmel ATmega328P 8-bit
microcontroller with 32KB of flash RAM 14 digital I/O and six analogue I/O and
the 32KB will not sound like as if running Windows. Arduino projects can be
stand-alone or they can communicate with software on running on a computer. For
e.g. Flash, Processing, Max/MSP). The board is clocked by a 16 MHz ceramic
resonator and has a USB connection for power and communication. You can easily
add micro SD/SD card storage for bigger tasks.

15
FIG 3.2 ARDUINO UNO WITH DIGITAL INPUT/OUTPUT

3.5.1.2. FEATURES OF ARDUINO:

• It is an easy USB interface. This allows interface with USB as this is like a
serial device.
• The chip on the board plugs straight into your USB port and supports on
your computer as a virtual serial port. The benefit of this setup is that serial
communication is an extremely easy protocol which is time-tested and USB
makes connection with modern computers and makes it comfortable.
• It is easy-to-find the microcontroller brain which is the ATmega328 chip. It
has more number of hardware features like timers, external and internal
interrupts, PWM pins and multiple sleep modes.

16
FIG 3.3 PIN DIAGRAM OF ARDUINO UNO

You can then use Atmel’s FLIP software (Windows) or the DFU programmer
(Mac OS X and Linux) to load a new firmware.

3.5.2. IR SENSOR
An infrared sensor is an electronic device, that emits in order to sense some aspects
of the surroundings. An IR sensor can measure the heat of an object as well as
detects the motion. These types of sensors measure only infrared radiation, rather
than emitting it that is called as a passive IR sensor. Usually in the infrared
spectrum, all the objects radiate some form of thermal radiations. These types of
radiations are invisible to our eyes, that can be detected by an infrared sensor. The
emitter is simply an IR LED (Light Emitting Diode) and the detector is simply an
IR photodiode which is sensitive to IR light of the same wavelength as that emitted

17
by the IR LED. When IR light falls on the photodiode, The resistances and these
output voltages, change in proportion to the magnitude of the IR light received.

FIG 3.4 IR SENSOR


3.5.2.1. Different Types of IR Sensors and Their Applications

IR sensors are classified into different types depending on the applications. Some
of the typical applications of different types of sensors are
The speed sensor is used for synchronizing the speed of multiple motors.
The temperature sensor is used for industrial temperature control. PIR sensor is
used for automatic door opening system and Ultrasonic sensor are used for
distance measurement.
3.5.2.2. IR Sensor Applications
IR sensors are used in various Sensor based projects and also in various electronic
devices which measures the temperature that are discussed in the below.
Radiation Thermometers

IR sensors are used in radiation thermometers to measure the temperature depend


upon the temperature and the material of the object and these thermometers have
some of the following features

18
• Measurement without direct contact with the object
• Faster response
• Easy pattern measurements

3.5.3. TOUCH SENSOR


A touch sensor is an electronic sensor which is used to detect and record physical
touch. They operate as a switch when touched. They act as a closed switch when
they are subjected to touch, Pressure or force and when the pressure or contact is
removed they act as open switch .Capacitive touch sensors have two parallel
conductor plates and an insulator in between them. These conductor plates act as a
capacitor with capacitance value CO. When our finger comes to contact with these
conductor plates then our finger act as a conductive object and due to this reason,
there will be an uncertain increase in the capacitance. The capacitance is used to
measure the capacitance CO of the sensor and if there are any changes in
capacitance it will send a signal to the Arduino Uno.

FIG 3.5 TOUCH SENSOR


3.5.3.1. Working Principle of Touch Sensor

19
Touch sensors work similar to a switch. When they are subjected to touch, pressure
or force they get activated and acts as a closed switch. When the pressure or
contact is removed, they act as an open switch.

Capacitive touch sensor contains two parallel conductors with an insulator between
them. These conductors’ plates act as a capacitor with a capacitance value C0.
When these conductor plates come in contact with our fingers, our finger acts as a
conductive object. Due to this, there will be an uncertain increase in the
capacitance.

A capacitance measuring circuit continuously measures the capacitance C0 of the


sensor. When this circuit detects a change in capacitance it generates a signal.

The resistive touch sensors calculate the pressure applied on the surface to sense
the touch. These sensors contain two conductive films coated with indium tin
oxide, which is a good conductor of electricity, separated by a very small distance.

Across the surface of the films, a constant voltage is applied. When pressure is
applied to the top film, it touches the bottom film. This generates a voltage drop
which is detected by a controller circuit and signal is generated thereby detecting
the touch.

3.5.3.2. Applications

The capacitive touch sensors can be easily manufactured with an attractive design
and in less investment. These sensors are highly used in mobile phones, iPods,
automotive, small home appliances, etc.… These are also used for measuring
pressure, distance, etc.… A drawback of these sensors is that they can give a

20
false alarm. The other type of touch sensors includes resistive. These sensors
could not detect anything because of small touching sense or contact.

3.5.4. DHT11 SENSOR

The DHT11 is a basic, ultra-low-cost digital temperature and humidity sensor. It


uses a capacitive humidity sensor and a thermistor to measure the surrounding air,
and spits out a digital signal on the data pin (no analog input pins needed). It’s
fairly simple to use, but requires careful timing to grab data. You can get new data
from it once every 2 seconds, so when using the library from Adafruit, sensor
readings can be up to 2 seconds old.
Comes with a 4.7K or 10K resistor, which you will want to use as a pullup from
the data pin to VCC. Each DHT11 element is strictly calibrated in the laboratory
that is extremely accurate on humidity calibration. The calibration coefficients are
stored as programmes in the OTP memory, which are used by the sensor’s internal
signal detecting process. The single-wire serial interface makes system integration
quick and easy. Its small size, low power consumption and up-to-20-meter signal
transmission making it the best choice for various applications, including those
most demanding ones. The component is 4-pin single row pin package. It is
convenient to connect and special packages can be provided according to users’
request.

21
FIG 3.6 DHT11 SENSOR

3.5.5. GSM

GSM is a mobile communication modem; it is stands for global system for mobile
communication (GSM). The idea of GSM was developed at Bell Laboratories in
1970. It is widely used mobile communication system in the world. GSM is an
open and digital cellular technology used for transmitting mobile voice and data
services operates at the 850MHz, 900MHz, 1800MHz and 1900MHz frequency
bands.

GSM system was developed as a digital system using time division multiple access
(TDMA) technique for communication purpose. A GSM digitizes and reduces the
data, then sends it down through a channel with two different streams of client
data, each in its own particular time slot. The digital system has an ability to carry
64 kbps to 120 Mbps of data rates.

22
FIG 3.7 GSM MODEM
There are various cell sizes in a GSM system such as macro, micro, pico and
umbrella cells. Each cell varies as per the implementation domain. There are five
different cell sizes in a GSM network macro, micro, pico and umbrella cells. The
coverage area of each cell varies according to the implementation environment.

3.5.5.1. Features of GSM Module

• Improved spectrum efficiency


• International roaming
• Compatibility with integrated services digital network (ISDN)
• Support for new services.
• SIM phonebook management
• Fixed dialing number (FDN)
• Real time clock with alarm management
• High-quality speech
• Uses encryption to make phone calls more secure
• Short message service (SMS)
The security strategies standardized for the GSM system make it the most secure

23
telecommunications standard currently accessible. Although the confidentiality of
a call and secrecy of the GSM subscriber is just ensured on the radio channel, this
is a major step in achieving end-to- end security.

3.5.5.2. GSM Modem

A GSM modem is a device which can be either a mobile phone or a modem device
which can be used to make a computer or any other processor communicate over a
network. A GSM modem requires a SIM card to be operated and operates over a
network range subscribed by the network operator. It can be connected to a
computer through serial, USB or Bluetooth connection.

A GSM modem can also be a standard GSM mobile phone with the appropriate
cable and software driver to connect to a serial port or USB port on your computer.
GSM modem is usually preferable to a GSM mobile phone. The GSM modem has
wide range of applications in transaction terminals, supply chain management,
security applications, weather stations and GPRS mode remote data logging.

3.5.5.3. Working of GSM Module:

From the below circuit, a GSM modem duly interfaced to the MC through the level
shifter IC Max232. The SIM card mounted GSM modem upon receiving digit
command by SMS from any cell phone send that data to the MC through serial
communication. While the program is executed, the GSM modem receives
command ‘STOP’ to develop an output at the MC, the contact point of which are
used to disable the ignition switch. The command so sent by the user is based on an
intimation received by him through the GSM modem ‘ALERT’ a programmed
message only if the input is driven low. The complete operation is displayed over
16×2 LCD display.

24
FIG 3.8 GSM MODEM CIRCUIT

3.5.5.4. Intelligent GSM Device for Automation and Security

In these days, the GSM mobile terminal has become one of the items that are
constantly with us. Just like our wallet/purse, keys or watch, the GSM mobile
terminal provides us a communication channel that enables us to communicate
with the world. The requirement for a person to be reachable or to call anyone at
any time is very appealing.

In this project, as the name says project is based on GSM network technology for
transmission of SMS from sender to receiver. SMS sending and receiving is used
for ubiquitous access of appliances and allowing breach control at home. The
system proposes two sub-systems. Appliance control subsystem enables the user to
control home appliances remotely and the security alert subsystem gives the
automatic security monitoring.

25
The system is capable enough to instruct user via SMS from a specific cell number
to change the condition of the home appliance according to the user’s needs and
requirements. The second aspect is that of security alert which is achieved in a way
that on the detection of intrusion, the system allows automatic generation of SMS
thus alerting the user against security risk.\

3.5.6. ESP8266 MODULE

The ESP8266 is a low-cost Wi-Fi microchip with full TCP/IP


stack and microcontroller capability produced by manufacturer Espressif
Systems in Shanghai, China.

The chip first came to the attention of western makers in August 2014 with
the ESP-01 module, made by a third-party manufacturer Ai-Thinker. This small
module allows microcontrollers to connect to a Wi-Fi network and make simple
TCP/IP connections using Hayes-style commands. However, at first there was
almost no English-language documentation on the chip and the commands it
accepted.[2] The very low price and the fact that there were very few external
components on the module, which suggested that it could eventually be very
inexpensive in volume, attracted many hackers to explore the module, chip, and the
software on it, as well as to translate the Chinese documentation

3.5.6.1. FEATURES

• Memory:
• 32 KiB instruction RAM
• 32 KiB instruction cache RAM
• 80 KiB user-data RAM
• 16 KiB ETS system-data RAM

26
• External QSPI flash: up to 16 MiB is supported (512 KiB to 4 MiB typically
included)
• IEEE 802.11 b/g/n Wi-Fi
• Integrated TR switch, balun, LNA, power amplifier and matching network
• WEP or WPA/WPA2 authentication, or open networks
• 16 GPIO pins
• SPI
• I²C (software implementation)[6]
• I²S interfaces with DMA (sharing pins with GPIO)
• UART on dedicated pins, plus a transmit-only UART can be enabled on GPIO2
• 10-bit ADC (successive approximation ADC)

ESP8266 is Wi-Fi enabled system on chip (SoC) module developed by Espressif


system. It is mostly used for development of IoT (Internet of Things) embedded
applications.

3.5.6.2. ESP8266-01 WIFI Module


It employs a 32-bit RISC CPU based on the Tensilica Xtensa L106 running at 80
MHz (or overclocked to 160 MHz). It has a 64 KB boot ROM, 64 KB instruction
RAM and 96 KB data RAM. External flash memory can be accessed through SPI.

ESP8266 module is low-cost standalone wireless transceiver that can be used for
end-point IoT developments.

27
FIG 3.9 ESP8266 MODULE

To communicate with the ESP8266 module, microcontroller needs to use set of AT


commands. Microcontroller communicates with ESP8266-01 module using UART
having specified Baud rate.

3.5.7. SERVO MOTOR

A servomotor is a rotary actuator or linear actuator that allows for precise control
of angular or linear position, velocity and acceleration.[1] It consists of a suitable
motor coupled to a sensor for position feedback. It also requires a relatively
sophisticated controller, often a dedicated module designed specifically for use
with servomotors.

Servomotors are not a specific class of motor although the term servomotor is often
used to refer to a motor suitable for use in a control system.

Servomotors are used in applications such as robotics, CNC


machinery or automated manufacturing.

3.5.7.1. MECHANISM

28
A servomotor is a closed-loop servomechanism that uses position feedback to
control its motion and final position. The input to its control is a signal (either
analogue or digital) representing the position commanded for the output shaft.

The motor is paired with some type of encoder to provide position and speed
feedback. In the simplest case, only the position is measured. The measured
position of the output is compared to the command position, the external input to
the controller. If the output position differs from that required, an error signal is
generated which then causes the motor to rotate in either direction, as needed to
bring the output shaft to the appropriate position. As the positions approach, the
error signal reduces to zero and the motor stops.

The very simplest servomotors use position-only sensing via


a potentiometer and bang-bang control of their motor; the motor always rotates at
full speed (or is stopped). This type of servomotor is not widely used in
industrial motion control, but it forms the basis of the simple and cheap servos
used for radio-controlled models.

More sophisticated servomotors use optical rotary encoders to measure the speed
of the output shaft[2] and a variable-speed drive to control the motor speed.[3] Both
of these enhancements, usually in combination with a PID control algorithm, allow
the servomotor to be brought to its commanded position more quickly and more
precisely, with less overshooting

The servo motor is actually an assembly of four things: a normal DC motor, a gear
reduction unit, a position-sensing device and a control circuit. The DC motor is
connected with a gear mechanism which provides feedback to a position sensor
which is mostly a potentiometer. From the gear box, the output of the motor is
delivered via servo spline to the servo arm. For standard servo motors, the gear is
normally made up of plastic whereas for high power servos, the gear is made up of
29
metal.
A servo motor consists of three wires- a black wire connected to ground, a
white/yellow wire connected to control unit and a red wire connected to power
supply.

3.5.7.2. Controlling a Servo Motor

A servo motor is controlled by controlling its position using Pulse Width


Modulation Technique. The width of the pulse applied to the motor is varied and
send for a fixed amount of time.

The pulse width determines the angular position of the servo motor. For example a
pulse width of 1 ms causes a angular position of 0 degrees, whereas a pulse width
of 2 ms causes a angular width of 180 degrees.

3.5.7.3. Advantages

• If a heavy load is placed on the motor, the driver will increase the current to the
motor coil as it attempts to rotate the motor. Basically, there is no out-of-step
condition.
• High-speed operation is possible.

3.5.7.4. Types of Servo Motor

Servo motors are classified into different types based on their application, such as
AC servo motor, DC servo motor, brushless DC servo motor, positional rotation,
continuous rotation and linear servo motor etc. Typical servo motors comprise of
three wires namely, power control and ground. The shape and size of these motors
depend on their applications. RC servo motor is the most common type of servo

30
motor used in hobby applications, robotics due to their simplicity, affordability and
reliability of control by microprocessors.

DC Servo Motor

The motor which is used as a DC servo motor generally have a separate DC source
in the field of winding & armature winding. The control can be archived either
by controlling the armature current or field current. Field control includes some
particular advantages over armature control. In the same way armature control
includes some advantages over field control. Based on the applications the control
should be applied to the DC servo motor. DC servo motor provides very accurate
and also fast respond to start or stop command signals due to the low armature
inductive reactance. DC servo motors are used in similar equipment and
computerized numerically controlled machines.

FIG 3.10 DC SERVO MOTOR


AC Servo Motor

31
AC servo motor is an AC motor that includes encoder is used with controllers for
giving closed loop control and feedback. This motor can be placed to high
accuracy and also controlled precisely as compulsory for the applications.
Frequently these motors have higher designs of tolerance or better bearings and
some simple designs also use higher voltages in order to accomplish greater
torque. motor mainly involve in automation, robotics, CNC machinery, and other
applications a high level of precision and needful versatility.

FIG 3.11 AC SERVO MOTOR


Positional Rotation Servo Motor

Positional rotation servo motor is a most common type of servo motor. The shaft’s
o/p rotates in about 180o. It includes physical stops located in the gear mechanism
to stop turning outside these limits to guard the rotation sensor. These common
servos involve in radio-controlled water, radio-controlled cars, aircraft, robots, toys
and many other applications.

Continuous Rotation Servo Motor

32
Continuous rotation servo motor is quite related to the common positional rotation
servo motor, but it can go in any direction indefinitely. The control signal, rather
than set the static position of the servo, is understood as the speed and direction of
rotation. The range of potential commands sources the servo to rotate clockwise or
anticlockwise as preferred, at changing speed, depending on the command signal.
This type of motor is used in a radar dish if you are riding one on a robot or you
can use one as a drive motor on a mobile robot.

FIG 3.12 CONTINUOUS ROTATION SERVO MOTOR

Linear Servo Motor

Linear servo motor is also similar the positional rotation servo motor is discussed
above, but with an extra gear to alter the o/p from circular to back-and-forth. These
servo motors are not simple to find, but sometimes you can find them at hobby
stores where they are used as actuators in higher model airplanes.

33
FIG 3.13 LINEAR SERVO MOTOR

3.5.8 POWER SUPPLY UNIT:


A power supply (sometimes known as a power supply unit or PSU) is a device or
system that supplies electrical or other types of energy to an output load or group
of loads. The term is most commonly applied to electrical energy supplies, less
often to mechanical ones, and rarely to other.

Transformer Rectifier Filter Regulator

FIG 3.14 BLOCK DIAGRAM OF POWER SUPPLY

110VDC (AVERAGE
345V (PEAK TO PEAK) 173V PEAK 110VDC
VOLTAGE WITH AC
(PULSATING DC)
ROPPLE)

RECTIFIER FILTE REGULATOR


TRANSFORM
BRIDGE R
115VAC ER

FIG 3.15 PROCESSINGG OF POWER SUPPLY


The transformer steps up or steps down the input line voltage and isolates the
power supply from the power line. The RECTIFIER section converts the

34
alternating current input signal to a pulsating direct current. However, as you
proceed in this chapter you will learn that pulsating dc is not desirable. For this
reason, a FILTER section is used to convert pulsating dc to a purer, more desirable
form of dc voltage.
The final section, the REGULATOR, does just what the name implies. It maintains
the output of the power supply at a constant level in spite of large changes in load
current or input line voltages. Now that you know what each section does, let's
trace an ac signal through the power supply. At this point you need to see how this
signal is altered within each section of the power supply. Later on, in the chapter
you will see how these changes take place. An input signal of 115 volts ac is
applied to the primary of the transformer.
The transformer is a step-up transformer with a turn’s ratio of 1:3. You can
calculate the output for this transformer by multiplying the input voltage by the
ratio of turns in the primary to the ratio of turns in the secondary; therefore, 115
volts ac ´ 3 = 345 volts ac (peak-to- peak) at the output. Because each diode in the
rectifier section conducts for 180 degrees of the 360-degree input, the output of the
rectifier will be one-half, or approximately 173 volts of pulsating dc. The filter
section, a network of resistors, capacitors, or inductors, controls the rise and fall
time of the varying signal; consequently, the signal remains at a more constant dc
level. You will see the filter process more clearly in the discussion of the actual
filter circuits. The output of the filter is a signal of 110 volts dc, with ac ripple
riding on the dc. The reason for the lower voltage (average voltage) will be
explained later in this chapter. The regulator maintains its output at a constant 110-
volt dc level, which is used by the electronic equipment (more commonly called
the load).

3.5.8.1. Circuit description

35
This circuit is a small +5V power supply, which is useful when experimenting with
digital electronics. Those transformers are easily available, but usually their
voltage regulation is very poor, which makes then not very usable for digital circuit
experimenter unless a better regulation can be achieved in some way.

This circuit can give +5V output at about 150 mA current, but it can be increased
to 1 A when good cooling is added to 7805 regulator chip. The circuit has over
overload and terminal protection.

FIG 3.16 POWER SUPPLY CIRCUIT DIAGRAM

36
3.6 SOFTWARE REQUIREMENTS
3.6.1 ARDUINO IDE:

The Arduino IDE is incredibly minimalistic, yet it provides a near-complete


environment for most Arduino-based projects. The top menu bar has the
standard options, including “File” (new, load save, etc.), “Edit” (font, copy,
paste, etc.), “Sketch” (for compiling and programming), “Tools” (useful options
for testing projects), and “Help”. The middle section of the IDE is a simple text
editor that where you can enter the program code. The bottom section of the
IDE is dedicated to an output window that is used to see the status of the
compilation, how much memory has been used, any errors that were found in
the program, and various other useful messages.

FIG 3.17 ARDUINO IDE 1

37
Projects made using the Arduino are called sketches, and such sketches are
usually written in a cut-down version of C++ (a number of C++ features are not
included). Because programming a microcontroller is somewhat different from
programming a computer, there are a number of device-specific libraries (e.g.,
changing pin modes, output data on pins, reading analog values, and timers).
This sometimes confuses users who think Arduino is programmed in an
“Arduino language.” However, the Arduino is, in fact, programmed in C++. It
just uses unique libraries for the device.

While more advanced projects will take advantage of the built-in tools in the
IDE, most projects will rely on the six buttons found below the menu bar.

FIG 3.18 BUTTON BAR

The button bar

1. The check mark is used to verify your code. Click this once you have
written your code.
2. The arrow uploads your code to the Arduino to run.
3. The dotted paper will create a new file.
4. The upward arrow is used to open an existing Arduino project.
5. The downward arrow is used to save the current file.
6. The far-right button is a serial monitor, which is useful for sending data
from the Arduino to the PC for debugging purposes.

38
FIG 3.19 ARDUINO IDE 2
The Arduino IDE supports the languages C and C++ using special rules of code
structuring. The Arduino IDE supplies a software library from the Wiring project,
which provides many common input and output procedures. User-written code
only requires two basic functions, for starting the sketch and the main program
loop, that are compiled and linked with a program stub main() into an
executable cyclic executive program with the GNU toolchain, also included with
the IDE distribution.
The Arduino IDE employs the program avrdude to convert the executable code
into a text file in hexadecimal encoding that is loaded into the Arduino board by a
loader program in the board's firmware.
3.6.2 EMBEDDED C
Embedded C is one of the most popular and most commonly used Programming
Languages in the development of Embedded Systems. So, in this article, we will
see some of the Basics of Embedded C Program and the Programming Structure of

39
Embedded C.
Embedded C is perhaps the most popular languages among Embedded
Programmers for programming Embedded Systems. There are many popular
programming languages like Assembly, BASIC, C++ etc. that are often used for
developing Embedded Systems but Embedded C remains popular due to its
efficiency, less development time and portability.

Before digging in to the basics of Embedded C Program, we will first take a look at
what an Embedded System is and the importance of Programming Language in
Embedded Systems.

3.6.2.1. Programming Embedded Systems

As mentioned earlier, Embedded Systems consists of both Hardware and Software.


If we consider a simple Embedded System, the main Hardware Module is the
Processor. The Processor is the heart of the Embedded System and it can be
anything like a Microprocessor, Microcontroller, DSP, CPLD (Complex
Programmable Logic Device) and FPGA (Field Programmable Gated Array).

All these devices have one thing in common: they are programmable i.e. we can
write a program (which is the software part of the Embedded System) to define
how the device actually works.

Embedded Software or Program allow Hardware to monitor external events


(Inputs) and control external devices (Outputs) accordingly. During this process,
the program for an Embedded System may have to directly manipulate the internal
architecture of the Embedded Hardware (usually the processor) such as Timers,
Serial Communications Interface, Interrupt Handling, and I/O Ports etc.

40
From the above statement, it is clear that the Software part of an Embedded System
is equally important to the Hardware part. There is no point in having advanced
Hardware Components with poorly written programs (Software).

There are many programming languages that are used for Embedded Systems like
Assembly (low-level Programming Language), C, C++, JAVA (high-level
programming languages), Visual Basic, JAVA Script (Application-level
Programming Languages), etc.

In the process of making a better embedded system, the programming of the


system plays a vital role and hence, the selection of the Programming Language is
very important.

3.6.2.2. Factors for Selecting the Programming Language

The following are few factors that are to be considered while selecting the
Programming Language for the development of Embedded Systems.

• Size: The memory that the program occupies is very important as Embedded
Processors like Microcontrollers have a very limited amount of ROM.
• Speed: The programs must be very fast i.e. they must run as fast as possible.
The hardware should not be slowed down due to a slow running software.
• Portability: The same program can be compiled for different processors.
• Ease of Implementation
• Ease of Maintenance
• Readability

Earlier Embedded Systems were developed mainly using Assembly Language.

41
Even though Assembly Language is closest to the actual machine code
instructions, the lack of portability and high number of resources spent on
developing the code, made the Assembly Language difficult to work with.

There are other high-level programming languages that offered the above-
mentioned features but none were close to C Programming Language.

3.6.2.3. Difference between C and Embedded C

There is actually not much difference between C and Embedded C apart from few
extensions and the operating environment. Both C and Embedded C are ISO
Standards that have almost same syntax, datatypes, functions, etc.

Embedded C is basically an extension to the Standard C Programming Language


with additional features like Addressing I/O, multiple memory addressing and
fixed-point arithmetic, etc.

C Programming Language is generally used for developing desktop applications


whereas Embedded C is used in the development of Microcontroller based
applications.

42
CHAPTER 4
RESULT & DISCUSSION

4.1. CODING FOR THE SYSTEM

#include <Servo.h>
Servo myservo;
#include <SoftwareSerial.h>
SoftwareSerial myserial(2, 3);/* (Rx, Tx) */
#include <dht.h>
dht DHT;
#define DHT11_PIN 8
int irpin = 11;
int buzzer = 6;
int touchpin=10;
int pos = 0;

void setup()
{
myservo.attach(9);
43
Serial.begin(9600);
myserial.begin(9600);
pinMode(6, OUTPUT);
pinMode(irpin, INPUT);
pinMode(touchpin, INPUT);
}

void loop()
{

int chk = DHT.read11(DHT11_PIN);


Serial.print("Temperature = ");
Serial.println(DHT.temperature);
Serial.print("Humidity = ");
Serial.println(DHT.humidity);
delay(1000);

int ir=digitalRead(irpin);
Serial.print("ir data= ");

44
Serial.println(ir);
delay(1000);

int seat=digitalRead(touchpin);
Serial.print("seat occupency= ");
Serial.println(seat);
delay(1000);

if((ir==0 || seat==1))
{
digitalWrite(buzzer, HIGH);
delay(1000);
digitalWrite(buzzer, LOW);
delay(1000);
for (pos = 90; pos <= 180; pos += 1)
{
// in steps of 1 degree
myservo.write(pos);
delay(15);

45
}
myserial.println("AT+CMGF=1");
delay(1000);
myserial.println("AT+CMGS=\"+919774546083\"\r");
delay(1000);
myserial.println("children is in car");
Serial.println("children is in car");
delay(200);
myserial.println((char)26);
delay(1000);
}
}

46
4.2. WORKING OF THE SYSTEM

FIG 4.1 DEMO WORKING MODEL

47
FIG 4.2 TOUCH SENSOR

FIG 4.3 IR SENSOR

48
FIG 4.4 GSM MODULE AND POWER SUPPLY

FIG 4.5 DHT11 SENSOR

49
FIG 4.6 ARDUINO UNO

FIG 4.7 ESP8266 MODULE

50
FIG 4.8 IR SENSOR BEFORE DETECTING MOTION

FIG 4.9 IR SENSOR AFTER DETECTING MOTION

51
FIG 4.10 TOUCH SENSOR BEFORE SENSING TOUCH

FIG 4.11 TOUCH SENSOR AFTER SENSING TOUCH

52
FIG 4.12 SCREENSHOT OF IOT CLOUD DATA

FIG 4.13 SCREENSHOT OF ALERT MESSAGE SEND TO USER


53
CHAPTER 5

CONCLUSION

To avoid hot car deaths, we have developed a new sensor-based system with
IOT and GSM alert. In this system we implemented infrared sensors, a touch
sensor and a temperature/humidity sensor. These acquisition devices are connected
to a microcontroller board that is able to combine all acquired data for detecting
the alarm scenario and consequently acting some warning procedures, and sends
alert messages to user with GSM module. We get the expected results in the
project and implemented a safety system for children forgotten in cars.

54
REFERENCES
[1] O. Kids and Cars, “Heatstroke deaths of children in vehicles,” https://
www.kidsandcars.org/how-kids-get-hurt/heat-stroke/, accessed April 1, 2019.
[2] E. Gold, “Sensorsafe securemax smart infant car seat,”
https://www.evenflo.com/gold/, accessed April 1, 2019.
[3] B. Security, “Dual view car camera,” https://www.brickhousesecurity. com/car-
cameras/, accessed April 1, 2019.
[4] A. R. Diewald, J. Landwehr, D. Tatarinov, P. Di Mario Cola, C. Watgen, C.
Mica, M. Lu-Dac, P. Larsen, O. Gomez, and T. Goiva, “Rfbased child occupation
detection in the vehicle interior,” in 2016 17th International Radar Symposium
(IRS), May 2016.
[5] D. Shi, J. Ding, S. M. Errapotu, H. Yue, W. Xu, X. Zhou, and M. Pan, “Deep
Q-network based route scheduling for transportation network company vehicles,”
in IEEE Global Communications Conference (GLOBECOM), Abu Dhabi,
December 2018.
[6] Y. Sun, M. Peng, Y. Zhou, Y. Huang, and S. Mao, “Application of machine
learning in wireless networks: Key techniques and open issues,” IEEE
Communications Surveys Tutorials, vol. 21, no. 4, pp. 3072–3108, Fourthquarter
2019.
[7] W. Xu, X. Li, C. Lee, M. Pan, and Z. Feng, “Joint sensing duration adaptation,
ser matching, and power allocation for cognitive ofdm-noma systems,” IEEE
Transactions on Wireless Communications, vol. 17, no. 2, pp. 1269–1282, Feb
2018.
[8] C. Wang, J. Liu, Y. Chen, H. Liu, and Y. Wang, “Towards in-baggage
suspicious object detection using commodity wifi,” in 2018 IEEE Conference on
Communications and Network Security (CNS), May 2018.
[9] X. Wang, L. Gao, S. Mao, and S. Pandey, “Csi-based fingerprinting for indoor
55
localization: A deep learning approach,” IEEE Transactions on Vehicular
echnology, vol. 66, no. 1, pp. 763–776, Jan 2017.
[10] D. Zhang, Y. Hu, and Y. Chen, “Breath status tracking using commodity
wifi,” in 2018 IEEE Global Communications Conference (GLOBECOM), Abu
Dhabi, December 2018.
[11] D. Zhang, Y. Hu, Y. Chen, and B. Zeng, “Breathtrack: Tracking indoor
human breath status via commodity wifi,” IEEE Internet of Things Journal, vol. 6,
no. 2, pp. 3899–3911, April 2019.
[12] X. Ma, Y. Zhao, L. Zhang, Q. Gao, M. Pan, and J. Wang, “Practical device-
free gesture recognition using wifi signals based on metalearning,” IEEE
Transactions on Industrial Informatics, vol. 16, no. 1, pp. 228–237, Jan 2020.
[13] C. Wu, Z. Yang, Z. Zhou, K. Qian, Y. Liu, and M. Liu, “Phaseu: Realtime los
identification with wifi,” in 2015 IEEE Conference on Computer Communications
(INFOCOM), April 2015.
[14] X. Wang, L. Gao, and S. Mao, “Csi phase fingerprinting for indoor
localization with a deep learning approach,” IEEE Internet of Things Journal, vol.
3, no. 6, pp. 1113–1123, Dec 2016.

56

You might also like