The document describes a proposed smart street light system that uses LED lights and sensors to automatically control street lighting based on vehicle and pedestrian presence. The system uses IR sensors and photodiodes to detect movement on the road. When a vehicle is sensed, the microcontroller switches on LED street lights ahead of the vehicle. As the vehicle passes, the trailing lights switch off. This allows energy to be saved by keeping lights off when no one is present. The system is intended to reduce power consumption from street lighting compared to existing systems using less efficient HID lamps.
Processing & Properties of Floor and Wall Tiles.pptx
Kg
1. ABSTRACT
Smart Street light is an automated system which makes the street light to ON/OFF
based on illumination level of the atmosphere and vary the illumination level
according to road trafic . The main aim of Smart Street light is to reduce the power
consumption when there are no vehicle movements on the road. The Smart street
light will turned to be ON when there are vehicles on the road otherwise the lights
will be switched OFF. With advancement of technology, things are becoming
simpler and easier for everyone in the world today. Automation is the use of
control systems and information technologies to reduce the need of human
intervention in the production of goods and services. In the scope of
industrialization, automation is a step beyond mechanization, whereas
mechanization provided human operators with machinery to assist the users with
the muscular requirements of work, automation greatly decreases the need for
human sensory and mental requirements as well. Automation plays an increasingly
important role in the world economy and in daily experience. Automatic systems
are being preferred over manual system. The research work shows automatic
control of streetlights as a result of which power is saved to an extent. The Smart
street light provides a solution for energy saving which is achieved by sensing an
approaching vehicle using the IR sensors and then switching ON a block of street
lights ahead of the vehicle. As the vehicle passes by, the trailing lights switch OFF
automatically. Thus, lot of energy could be saved. So when there are no vehicles
on the highway, then all the lights remain OFF or glow with low illumination level
is being proposed in this project as on intelligent system.
2. CHAPTER 1
INTRODUCTION
Smart Street light is an automated system which makes the street light to On/OFF
based on illumination level of the atmosphere and vary the illumination level
according to road trafic . The main aim of Smart Street light is to reduce the power
consumption when there are no vehicle movements on the road. The Smart street
light will turned to be ON when there are vehicles on the road otherwise the lights
will be switched OFF. With advancement of technology, things are becoming
simpler and easier for everyone in the world today. Automation is the use of
control systems and information technologies to reduce the need of human
intervention in the production of goods and services. In the scope of
industrialization, automation is a step beyond mechanization, whereas
mechanization provided human operators with machinery to assist the users with
the muscular requirements of work, automation greatly decreases the need for
human sensory and mental requirements as well. Automation plays an increasingly
important role in the world economy and in daily experience. Automatic systems
are being preferred over manual system. The research work shows automatic
control of streetlights as a result of which power is saved to an extent. The Smart
street light provides a solution for energy saving which is achieved by sensing an
approaching vehicle using the IR sensors and then switching ON a block of street
lights ahead of the vehicle. As the vehicle passes by, the trailing lights switch OFF
automatically. Thus, lot of energy could be saved. So when there are no vehicles
on the highway, then all the lights remain OFF is being proposed in this project as
on intelligent system. Therefore, the street lamps are relatively simple but with the
development of urbanization, the number of streets increases rapidly with high
traffic density. There are several factors need to be considered in order to design a
good street lighting system such
-1-
3. As night-time safety for community members and road users, provide public
lighting at cost effective, the reduction of crime and minimizing it is effect on the
environment. In the early days, street lamps were manually controlled ,where a
control switch is set in each of the street lamps which is called the first generation
of the original street light. After that, another method that has been used was
optical control method done using high pressure sodium lamp in their system.
Nowadays, it is seen that the method is widely used in the country.
The method operates by set up an optical control circuit, change the
resistance by using of light sensitive device to control street lamps light up
automatically at dusk and turn off automatically after dawn in the morning. Due to
the technological development nowadays, road lighting can be categorized
according to the installation area and performance, For example, lighting for traffic
routes, lighting for subsidiary roads and lighting for urban center and public
amenity areas. The wireless sensor network (WSN) helps in improving the network
sensing for street lighting. Meanwhile, street light system can be classified
according to the type of lamps used such as incandescent lamp, mercury vapor
lamp, metal halide lamp, high pressure sodium lamp, low pressure sodium lamp,
fluorescent lamp, compact fluorescent lamp, induction lamp and LED lamp.
Different type of lamp technology used in lighting design with their luminous
efficiency, lamp life and cost. The LED is considered a promising solution to
modern street lighting system due to its behavior and advantages. Apart from that,
the advantages of LED are likely to replace the traditional street lamps such as the
incandescent lamp, fluorescent lamp and High Pressure Sodium Lamp in future but
LED technology is an extremely difficult process that requires a combination of
advanced production lines, top quality materials and high-precision manufacturing
process. Therefore, the research work highlights the energy efficient system of the
street lights system using LED lamps with IR sensor interface for controlling and
managing.
-2-
4. Street lights are the major requirement in today’s life of transportation for safety
purposes and avoiding accidents during night. Despite that in today’s busy life no
one bothers to switch it off/on when not required. This project introduces a
solution to the problem by eliminating manpower and reducing power
consumption. This requires three basic components i.e. LDR, Sensors and
microcontroller. During daytime there is no requirement of street lights so the LDR
keeps the street light off until the light level is low or the frequency of light is low
the resistance of the LDR is high. This prevents current from flowing to the base of
the transistors.
Thus the street lights do not glow. As soon as the light level goes high or
if light falling on the device is of high enough frequency, photons absorbed by the
semiconductor give bound electrons enough energy to jump into the conduction
band. The resulting free electron (and its hole partner) conduct electricity, thereby
lowering resistance. Now the circuit turn ON the street lights.
-3-
5. CHAPTER 2
LITERATURE SURVEY
S.Suganya et al [1] have proposed about Street Light Glow on detecting
vehicle movement using sensor is a system that utilizes the latest technology for
sources of light as LED lamps. It is also used to control the switching of street light
automatically according to the light intensity to develop flow based dynamic
control statistics using infrared detection technology and maintain wireless
communication among lamppost and control terminal using ZigBee Wireless
protocol. It also combines various technologies: a timer, a statistics of traffic flow
magnitude, photodiodes, LED, power transistors. K.Santha et al [3] have surveyed
on Street Lighting System Based on Vehicle Movements. The system operates in
the automatic mode which regulates the streetlight according to brightness and
dimness algorithm and light intensity. The control can be made according to the
seasonal variation. It includes a time cut-out function and an automatic control
pattern for conserving more electricity. The whole project was implemented using
a PIC microcontroller. Srikanth et al [4] proposed a ZigBee based Remote Control
Automatic Street Light System. The system is designed with the help of ZigBee
modules that helps in detecting the faulty lights and control the light. It also
discusses about an intelligent system that takes automatic decisions for
ON/OFF/DIMMING considering the vehicle movement or pedestrian and also the
surrounding environment. PIR motion sensor is used to detect movement of both
living and non-living things. M.Abhishek et al [5] haveimplemented design of
traffic flow based street light control system with effective utilization of solar
energy in the year 2015. They used the renewable source of energy i.e. the solar
power for street lighting. They have also used 8052 series microcontroller and is
developed by replacing the normal bulbs with the LEDs due to which the power
consumption is reduced by 3 times. Sensors are placed on either side of the road
which senses the vehicle movement and sends the commands to the
-4-
6. Microcontroller to switch ON and OFF the lights.Here all the street
lights remain switched off and it glows only when it senses the vehicle movement.
Hence, because of the microcontroller, even when its night the lights are switched
off. C.Bhuvaneshwari et al [6] have analyzed the street light with auto tracking
system by which one can increase the conversion efficiency of the solar power
generation. Here, the sun tracking sensor is the sensing device which senses the
position of the sun time to time and gives the output to the amplifier based on light
density of the sun. Sun tracking sensor is LDR, amplifier unit is used to amplify
the LDR signals which converts low level signals to high level signals and the
output is given to comparator. The LM324 IC is used as an amplifier. Comparator
compares the signals and gives the command to AT89C51 microcontroller. Steve
Chadwick [7] reports on the two installation case studied in Scotland and Wales
and explains the details and benefits of the technology. The system was called as
MINOS that had a track record of over 100,000 units installed and working
successfully. SomchaiHiranvarodom [8] describes a comparative analysis of
photovoltaic (PV) street lighting system in three different lamps. Namely, a low
pressure sodium lamp, a high pressure sodium lamp and a fluorescent lamp have
been used for installation in each mast to determine the suitable system to install in
a typical rural area of Thailand. All three systems have been mounted with the
same module type and wattage in different places within the Rajamangala Institute
of Technology, Thanyaburi district, Pathumthani province of Thailand. An
operation of solar street lighting system can be divided into 2 period of time,
namely, at 18.00-22.00 hours and 05.00-06.00 hours. The design of a control
circuit was experimentally done in this work. The aim of this work is to determine
the appropriate system to install in a typical rural area or a typical rural village of
Thailand. RadhiPriyasree [9] explains a system to reduce the power consumption
of street lights by avoiding inefficient lighting which wastes significant financial
resources each year. This is done by dimming the lights during less traffic hours.
-5-
7. For this purposePIR sensor is used which detects any movement. This
work also aims at reducing the fatal crashes and road accidents caused due to
alcohol consumption. This is done using skin sensors placed in vehicle doors and
also using breadth sensors inside the vehicle. By implementing this death rates due
to drunk driving can be reduced to a great extent. The prototype has been
implemented and works as expected and will prove to be very useful and will
fulfill all the present constraints if implemented on a large scale. It also aims at
detecting consumption of alcohol by the driver and if it exceeds certain level it
impairs the driver from entering into the Vehicle. This prevents occurrence of
accidents or any fatal crashes. This initiative will help the government to save this
energy and meet the domestic and industrial needs.
From this literature survey, the methods each one has implemented and
used is simple and easy to understand. The survey has given many ideas to further
implement a much efficient system and make things automated. The presentations
are simple and clear with all the necessary information needed for a basic learner
or reader. The gaps identified from the literature survey help to propose this project
work.
-6-
8. CHAPTER 3
EXISTING SYSTEM
Street lighting systems are growing rapidly and becoming to complex
with rapid growth of industry and cities. Automation, Power consumption and Cost
Effectiveness are the important considerations in the present field of electronics
and electrical related technologies. To control and maintain complex street lighting
system more economically, various street light control systems are developed.
These systems are developed to control and reduce energy consumption of a town's
public lighting system using different technologies. The existing work is done
using High intensity discharge lamps (HID). Currently, the HID is used for urban
street light based on principle of gas discharge, thus the intensity is not controlled
by any voltage reduction method as the discharge path is broken. HID lamps[10]
are a type of electrical gas discharge lamp which produces light by means of an
electric arc between tungsten electrodes housed inside a translucent or transparent
fused quartz or fused alumina arc tube. This tube is filled with both gas and metal
salts. The gas facilitates the arc's initial strike. Once the arc is started, it heats and
evaporates the metal salts forming plasma, which greatly increases the intensity of
light produced by the arc and reduces its power consumption. High-intensity
discharge lamps are a type of arc lamp. Disadvantages of Existing System:
HID lamps consume more power.
The life time of the HID lamps is very less.
It cannot be used in all outdoor applications.
Brightness of the lights in the rear view mirrors which causes a
problem for drivers in front of your vehicle.
-7-
9. CHAPTER 4
PROPOSED SYSTEM
Since the HID lamps are not cost effective and not reliable, smart street
light system has overcome by replacing the HID lamps with LED. Due to
automation, power consumption and cost effectiveness in the present technologies,
industry of street lighting systems are growing rapidly and going to complex with
rapid growth of industry and cities. To control and maintain complex street lighting
system more economically, various street light control systems are developed.
These systems are developed to control and reduce energy consumption of a town's
public lighting system using different technologies which uses IR motion sensors
to detect the vehicle movement after which the street light begins to glow. As the
vehicle moves, the street light that was glowing switches off and the following
lights begins to glow.
The main purpose of this project is to “ automate the street light control
using pic microcontroller ”. It can be used to minimize the cost of electricity and
also cost of man power to manually on-off the street light. In the field of modern
embedded world, this project automatic street light control by pic microcontroller
is used to on – off automatically by using LDR (Light dependent Resistor),
Opamp, relay and pic16f877a microcontroller without any human interface.
Now-a-days the amount of power consumed by lighting and streets shares a
major energy demand. The vehicles are passing over always and a part of places
will be consisting of less density areas and even no vehicle moments itself in few
areas. But during night all street lights will be on in conventional street lighting
system. To overcome from this issue, a proper energy saving methods and lighting
control to be implemented. The proposed work is to have two controls like, one is
to switch OFF lights during no vehicle moments in streets and automatically
switch it
-8-
10. ON when vehicles arrive and the other modes are to give less intensity light
for pedestrian and to switch on bright mode during vehicle moments at sides on the
roads. In this work the LED lights are used for street arrangement, the Photo
diodes and IR sensors are used to sense vehicle moments. The control signals of
sensors have been fed to microcontroller PIC16F877A. In the microcontroller the
control logic is implemented to control lights based on vehicles and pedestrian
moments with bright and dim mode of operation and to switch off lights during no
vehicles and pedestrian. From the proposed method the overall energy being
utilized now-a-days for lighting can be minimized. Moreover the automatic and
intelligent control schemes are required to control the complex lighting system due
to growth of cities and standard of living.
A photodiode is a type of photo detector capable of converting light into either
current or voltage, depending upon the mode of operation. Photodiodes are similar
to regular semiconductor diodes except that they may be either exposed (to detect
vacuum UV or X-rays) or packaged with a window or optical fibre connection to
allow light to reach the sensitive part of the device. Many diodes designed for use
specifically as a photodiode will also use a PIN junction rather than the typical PN
junction. The working procedure of the Smart street light using IR sensors is
explained below. The following are the different steps included in building a Smart
street light. 1. LDR pin 1 is connected to A0 (analog) port of Arduino Uno board.
2. Connect all the IR sensors to port numbers 2, 3, 4, 5 and 6 respectively (digital)
which is the input signal to the Arduino board. 3. Connect the ground of all the
sensors to GND port. 4. The LED’s which are the output signals, are connected to
port number 8, 9, 10, 11 and 12 respectively. 5. Again connect the ground of all the
sensors to GND port. 6. Power is passed to the Arduino (7-12V).
The highway model consists of 4 led’s as street lights and 4 pairs of
photodiodes-IR diodes used as sensors, variable resistors and a transistor which
acts as switch as explained above
.-9-
11. The IR diodes are placed on one side of the road and photodiodes are placed on the
other side of the road, directly facing the IR diodes. Consider the case when there
is no vehicle on the highway. In this case, the IR radiation emitted from the IR
diode directly falls on the photodiode which is exactly opposite to it. This causes
the photodiode to fall in conduction state. This implies that photodiode conducts
and current passes through it. The current passes through the photodiode and goes
through the variable resistor and the base-emitter region of the transistor This in
turn connects the collector of the transistor to the emitter. From the circuit diagram
we can see that emitter is connected to ground which implies that the collector also
goes to the ground. The collector region of the transistor is connected to the port 1
(input port) which in turn goes to ground i.e., logic ZERO. So, to summariz, when
there is no vehicle on the highway, then all the inputs to the Arduino port is
ZERO. Consider the case when a vehicle obstructs the IR radiation path. In this
case, IR radiation is blocked and hence it does not fall on the photodiode. This in
turn implies that photodiode doesn't conduct. Hence, there is no current flowing
through this first transistor. So, the collector is at HIGH state. Let us assume that
the first Photodiode-IR diode pair IR path is obstructed. This leads to a transition
from ZERO to HIGH at pin.
The figure 4.1 is shows in the block diagram for the smart street light control
system.
-10-
12. Fig. 4.1 : Block Diagramof smart streetlight control system
It consists of
POWER SUPPLY
ARDUINO UNO
IR SENSOR
PIR SENSOR
LDR SENSOR
WIRELESS MODEM
LCD
MOSFET
ARDUINO IDE
-11-
13. POWER SUPPLY
Power Supply Design
Every circuit needs a sourceto give energy to that circuit. The Source wills a
particular voltage and load current ratings. The following is a circuit diagram of a
power supply. We need a constant low voltage regulated power supply of +5V,
providing input voltages to the microcontroller RS232, LM311 and LCD display
which requires 5 volts supply.
Every power supply has the following parts,
• Transformer
• Rectifier
• Capacitor (filter)
• Regulator
• resistors
TRANSFORMER
WORKING PRINCIPLE OF TRANSFORMER:
The transformer works on the principle of faradays law of electromagnetic
inductions. Transformer in its simplest form.
The core is built up of thin laminations insulated from each other in order to reduce
eddy current loss in the more. The winding are unguarded from each other and
also from the care. The winding connected to the load is called the secondary
winding for samplings they are shown on the oppositeside of core but in practice
they are distributed owner both sides of the cores. The high voltage winding
encloses the low voltage.
-12-
14. Let us say that transformer has N1 turns in its primary winding and N2 turns in its
secondarywinding. The primary winding is connected to a sinusoidal voltage of
magnitude V1 at a frequency FH2. A working flux is set up in magnetic core. The
working flux is alternating and sinusoidal as the applied voltage is alternating and
sinusoidal. When these flux link the primary and the secondarywinding emf are
induced in them. The emf induced in this is called the self-induced emf and that
induced in the secondary is the mutually induced emf. These voltages will have
sinusoidal waveform and the same frequency as that of the applied voltage. The
currents, which flow in the close primary and secondarycircuits, are respectively
I1 and I2.
VOLTAGE REGULATOR:
A voltage regulator is an electronic circuit that provides a stable DC voltage
independent of the load current, temperature and AC line voltage variations.
Although Voltage regulators can be designed using op-amps it is quicker and
easier to use IC voltage regulator. The IC voltage regulators are inscribe and
inexpensive and are available with features such as programmable, output, current
voltage, boosting and floating operation for high voltage application.
7805 VOLTAGE REGULATOR:
78XX series are three terminal positive fixed voltage regulators. There are seven
output voltage options available such as 5, 6, 8,12,15,18 and 24V in 78XX the two
numbers (XX) indicate the output voltage. The connection of a 7805-voltage
regulator is show infix. The AC line voltage is stepped down a cross each half of
the center tapped transformers. If full wane rectifier and capacitors filter then
provides an unregulated DC voltage with AC ripple of a few volts as a input to the
voltage regulator. The 7805 of IC provides an output of +5 Volts D.C.
-13-
15. ARDUINO UNO
Arduino is an open-source computer hardware and software company,
project and user community that designs and manufactures microcontroller-based
kits for building digital devices and interactive objects that can sense and control
objects in the physical world. The project is based on microcontroller board
designs, manufactured by several vendors, using various microcontrollers. These
systems provide sets of digital and analog I/O pins that can be interfaced to various
expansion boards ("shields") and other circuits. The boards feature serial
communications interfaces, including USB on some models, for loading programs
from personal computers. For programming the microcontrollers, the Arduino
project provides an integrated development environment (IDE) based on the
Processing project, which includes support for the C and C++ programming
languages. The first Arduino was introduced in 2005, aiming to provide an
inexpensive and easy way for novices and professionals to create devices that
interact with their environment using sensors and actuators. Common examples of
such devices intended for beginner hobbyists include simple robots, thermostats,
and motion detectors.
Arduino boards are available commercially in preassembled form, or
as do-it-yourself kits is shown in figure 4.2. The hardware design specifications are
openly available, allowing the Arduino boards to be manufactured by anyone.
Adafruit Industries estimated in mid-2011 that over 300,000 official Arduinos had
been commercially produced, and in 2013 that 700,000 official boards were in
users' hands
Fig 4.2: Hardware
-14
16. An early Arduino board with an RS-232 serial interface (upper left) and an
Atmel ATmega8 microcontroller chip (black, lower right); the 14 digital I/O pins
are located at the top and the six analog input pins at the lower right. An Arduino
board historically consists of an Atmel 8-, 16- or 32-bit AVR microcontroller
(although since 2015 other makers' microcontrollers have been used) with
complementary components that facilitate programming and incorporation into
other circuits. An important aspect of the Arduino is its standard connectors, which
lets users connect the CPU board to a variety of interchangeable add-on modules
known as shields. Some shields communicate with the Arduino board directly over
various pins, but many shields are individually addressable via an I²C serial bus—
so many shields can be stacked and used in parallel. Prior to 2015 Official
Arduinos had used the Atmel megaAVR series of chips, specifically the ATmega8,
ATmega168, ATmega328, ATmega1280, and ATmega2560 and in 2015 units by
other manufacturers were added. A handful of other processors have also been
used by Arduino compatible devices. Most boards include a 5 V linear regulator
and a 16 MHz crystal oscillator (or ceramic resonator in some variants), although
some designs such as the LilyPad run at 8 MHz and dispense with the onboard
voltage regulator due to specific form-factor restrictions. An Arduino's
microcontroller is also pre-programmed with a boot loader that simplifies
uploading of programs to the on-chip flash memory, compared with other devices
that typically need an external programmer. This makes using an Arduino more
straightforward by allowing the use of an ordinary computer as the programmer.
Currently, opti boot boot loader is the default boot loader installed on Arduino
UNO.
At a conceptual level, when using the Arduino integrated development
environment, all boards are programmed over a serial connection. Its
implementation varies with the hardware version. Some serial Arduino boards
-15-
17. Contain a level shifter circuit to convert between RS-232 logic levels and TTL-
level signals. Current Arduino boards are programmed via Universal Serial Bus
(USB), implemented using USB-to-serial adapter chips such as the FTDI FT232.
Some boards, such as later-model Uno boards, substitute the FTDI chip with a
separate AVR chip containing USB-to-serial firmware, which is reprogrammable
via its own ICSP header. Other variants, such as the Arduino Mini and the
unofficial Boarduino, use a detachable USB-to-serial adapter board or cable,
Bluetooth or other methods, when used with traditional microcontroller tools
instead of the Arduino IDE, standard AVR ISP programming is used.
Fig 4.3: Arduino Uno with descriptions of the I/O locations
The Arduino board exposes most of the microcontroller's I/O pins for use by other
circuits. The Diecimila, Duemilanove, and current Uno provide 14 digital I/O pins,
six of which can produce pulse-width modulated signals, and six analog inputs,
which can also be used as six digital I/O pins is shown in figure 4.3. These pins are
on the top of the board, via female 0.10-inch (2.5 mm) headers. Several plug-in
application shields are also commercially available. The Arduino Nano, and
Arduino-compatible Bare Bones Board and Boarduino boards may provide male
header pins on the underside of the board that can plug into solderless breadboards.
There are many Arduino-compatible and Arduino-derived boards. Some are
functionally equivalent to an Arduino and can be used interchangeably. Many
enhance the basic Arduino by adding output drivers, often for use in school-level
education to simplify the construction of buggies and small robots.
-16-
18. Others are electrically equivalent but change the form factor, sometimes retaining
compatibility with shields, sometimes not. Some variants use completely different
processors, with varying levels of compatibility.
Software
Arduino Software IDE
Fig 4.4 Arduino Software IDE
A screenshot of the Arduino IDE showing the
"Blink" program, a simple beginner program
Arduino programs may be written in any programming language with a compiler
that produces binary machine code as shown in figure 4.4. Atmel provides a
development environment for their microcontrollers, AVR Studio and the newer
Atmel Studio.
The Arduino project provides the Arduino integrated development environment
(IDE), which is a cross-platform application written in Java. It originated from the
IDE for the Processing programming language project and the Wiring project. It is
designed to introduce programming to artists and other newcomers unfamiliar with
software development.
-17-
19. It includes a codeeditor with features such as syntax highlighting, brace matching,
and automatic indentation, and provides simple one-click mechanism for
compiling and loading programs to an Arduino board. A program written with the
IDE for Arduino is called a "sketch".
The Arduino IDE supports the C and C++ programming languages using special
rules of code organization. The Arduino IDE supplies a software library called
"Wiring" from the Wiring project, which provides many common input and output
procedures. A typical Arduino C/C++ sketch consist of two functions that are
compiled and linked with a program stub main() into an executable cyclic
executive program:
setup(): a function that runs once at the start of a program and that can
initialize settings.
loop(): a function called repeatedly until the board powers off.
After compilation and linking 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 coding that is loaded into the
Arduino board by a loader program in the board's firmware.
IR Sensor
Fig 4.5 IR Transmitter
This device emits and/or detects infrared radiation to sense a particular phase
in the environment. Generally, thermal radiation is emitted by all the objects in the
infrared spectrum. The infrared sensor detects this type of radiation which is not
visible to human eye.
-18-
20. Working
The basic idea is to make use of IR LEDs to send the infrared waves to the
object. Another IR diode of the same type is to be used to detect the reflected wave
from the object. The diagram is shown below.
Fig 4.6 IR working Mechanism
When IR receiver is subjected to infrared light, a voltage difference is
produced across the leads. Less voltage which is produced can be hardly detected
and hence operational amplifiers (Op-amps) are used to detect the low voltages
accurately.
Measuring the distance of the object from the receiver sensor: The electrical
property of IR sensorcomponents can be used to measure the distance of an object.
The fact when IR receiver is subjected to light, a potential difference is produced
across the leads.
-19-
21. Applications
Thermography – According to the black body radiation law, it is possible to
view the environment with or without visible illumination using
thermography
Heating – Infrared can be used to cook and heat food items. They can take
away ice from the wings of an aircraft. They are popular in industrial field
such as, print dying, forming plastics, and plastic welding.
Spectroscopy – This technique is used to identify the molecules by analysing
the constituent bonds. This technique uses light radiation to study organic
compounds.
Meteorology – Cloud heights, calculate land and surface temperature is
possible when weather satellites are equipped with scanning radiometers.
Photo bio-modulation – This is used for chemotherapy in cancer patients.
This is used to treat anti-herpes virus.
Climatology – Monitoring the energy exchange between the atmosphere and
earth.
Communications – Infra red laser provide light for optical fibre
communication. These radiations are also used for short range
communications among mobiles and computer peripherals.
Advantages
Easy for interfacing
Readily available in market
Disadvantages
Disturbed by noises in the surrounding such as radiations, ambient light etc.
-20-
22. Specifications
IR TX RX size: 5mm diameter package
IR LED current rating: 30mA nominal, 600mA pulse loading at 1% duty
cycle
IR LED wavelength: 940nM
Photodiode peak response wavelength: 940nM
LDR (Light Dependent Resistor)
Fig 4.7 LDR
An LDR (Lightdependent resistor), as its name suggests, offers resistance in
response to the ambient light. The resistance decreases as the intensity of
incident light increases, and vice versa. In the absence of light, LDR exhibits a
resistance of the order of mega-ohms which decreases to few hundred ohms in
the presence of light. It can act as a sensor, since a varying voltage drop can be
obtained in accordance with the varying light. It is made up of cadmium sulphide
(CdS).
-21-
23. An LDR has a zigzag cadmium sulphide track. It is a bilateral device, i.e.,
conducts in both directions in same fashion.
PIN DIAGRAM
Fig 4.8 LDR
A photoresistor or light-dependent resistor (LDR) or photocell is a light-
controlled variable resistor. The resistance of a photoresistor decreases with
increasing incident light intensity; in other words, it exhibits photoconductivity. A
photoresistor can be applied in light-sensitive detector circuits, and light- and dark-
activated switching circuits.
A photoresistor is made of a high resistance semiconductor. In the dark, a
photoresistor can have a resistance as high as a few mega ohms (MΩ), while in the
light, a photoresistor can have a resistance as low as a few hundred ohms. If
incident light on a photoresistor exceeds a certain frequency, photons absorbed by
the semiconductor give bound electrons enough energy to jump into the conduction
band. The resulting free electrons (and their hole partners) conduct electricity,
thereby lowering resistance. The resistance range and sensitivity of a photoresistor
can substantially differ among dissimilar devices.
-22-
24. Moreover, unique photoresistors may react substantially differently to
photons within certain wavelength bands.
A photoelectric device can be either intrinsic or extrinsic. An intrinsic
semiconductor has its own charge carriers and is not an efficient semiconductor,
for example, silicon. In intrinsic devices the only available electrons are in the
valence band, and hence the photon must have enough energy to excite the electron
across the entire band gap. Extrinsic devices have impurities, also called dopants,
and added whose ground state energy is closer to the conduction band; since the
electrons do not have as far to jump, lower energy photons (that is, longer
wavelengths and lower frequencies) are sufficient to trigger the device. If a sample
of silicon has some of its atoms replaced by phosphorus atoms (impurities), there
will be extra electrons available for conduction. This is an example of an extrinsic
semiconductor.
DESIGN CONSIDERATIONS
Fig 4.9 LDR sizes
Fig4.9. Threephotoresistors with scale in mm
Photoresistors are less light-sensitive devices than photodiodes or phototransistors:
The two latter components are true semiconductor devices, while a photoresistor is
a passive component and does not have a PN-junction. The photo resistivity of any
photoresistor may vary widely depending on ambient temperature, making them
unsuitable for applications requiring precise measurement of or sensitivity to light.
-23-
25. Photoresistors also exhibit a certain degree of latency between exposure to light
and the subsequent decrease in resistance, usually around 10 milliseconds. The lag
time when going from lit to dark environments is even greater than, often as long
as one second. This property makes them unsuitable for sensing rapidly flashing
lights, but is sometimes used to smooth the response of audio signal compression.
APPLICATIONS
The internal components of a photoelectric control for a typical American
streetlight. The photoresistor is facing rightwards, and controls whether
current flows through the heater which opens the main power contacts. At
night, the heater cools, closing the power contacts, energizing the street
light.
Photoresistors come in many types. Inexpensive cadmium sulphide cells can
be found in many consumer items such as camera light meters, street lights,
clock radios, alarm devices, night lights, outdoor clocks, solar street lamps
and solar road studs, etc.
They are also used in some dynamic compressors together with a small
incandescent or neon lamp, or light-emitting diode to control gain reduction.
A common usage of this application can be found in many guitar amplifiers
that incorporate an onboard tremolo effect, as the oscillating light patterns
control the level of signal running through the amp circuit.
The use of CdS and CdSe photoresistors is severely restricted in Europe due
to the RoHS ban on cadmium.
Lead sulphide (PbS) and indium antimonide (InSb) LDRs (light-dependent
resistors) are used for the mid-infrared spectral region. Ge: Cu
photoconductors are among the best far-infrared detectors available, and are
used for infrared astronomy and infrared spectroscopy.
-24-
26. PASSIVE INFRARED SENSOR
A Passive Infrared sensor (PIR sensor) is an electronic device that measures
infrared (IR) light radiating from objects in its field of view. PIR sensors are often
used in the construction of PIR-based motion detectors. A PIR-based motion
detector is used to sense movement of people, animals, or other objects. They are
commonly used in burglar alarms and automatically-activated lighting systems.
Apparent motion is detected when an infrared source with one temperature, such as
a human, passes in front of an infrared source with another temperature, such as a
wall.
It is usually infrared radiation that is invisible to the human eye but can be
detected by electronic devices designed for such a purpose. The term passive in
this instance means that the PIR device does not emit an infrared beam but merely
passively accepts incoming infrared radiation.
Every object that has a temperature above perfect zero emits thermal
energy (heat) in form of radiation. The PIR sensors are tuned to detect this IR
wavelength which only emanates when a human being arrives in their proximity.
The term “pyroelectricity” means: heat that generates electricity (here, an electric
signal of small amplitude). Since these sensors do not have an infrared source of
their own, they are also termed as passive.
CONSTRUCTION
Fig 4.10 PIR Sensor
-25-
27. On closely observing the top region of the sensor, the beehive structure,
curved segments are seen. These curved segments are Fresnel lenses which
constitute an array that increases the detection zone of the sensor. Fresnel lens
array is known to capture more infrared radiation and focus it to a relatively
smaller point. Detection is more stable and maximum distance for detection is
also increased. Fresnel lens has been crafted to be translucent so that it can
capture only infrared radiation without getting unwanted radiations from visible
spectrum of light.
Fig 4.11 PIR - IR filter
At the top of the sensor is the infrared filter. Looking more like a square
shaped glass, this filter selects the desired wavelength at which sensor is desired
to respond. Since this sensor is designed to detect human presence, the
wavelength chosen is 8micrometer to 14 micrometer which is the range within
which human body radiates electromagnetic rays.
-26-
28. Fig 4.12 MOSFET Interconnection Pins
The connecting lead placement which are arranged in the same fashion as
in a JFET. The specific function of each lead is shown in the image.
OPERATION
An individual PIR sensor detects changes in the amount of infrared radiation
impinging upon it, which varies depending on the temperature and surface
characteristics of the objects in front of the sensor. When an object, such as a
human, passes in front of the background, such as a wall, the temperature at that
point in the sensor's field of view will rise from room temperature to body
temperature, and then back again. The sensor converts the resulting change in the
incoming infrared radiation into a change in the output voltage, and this triggers
the detection. Moving objects of similar temperature to the background but
different surface characteristics may also have a different infrared emission pattern,
and thus sometimes trigger the detector.
PIRs come in many configurations for a wide variety of applications. The
most common models have numerous Fresnel lenses or mirror segments, an
effective range of about ten meters (thirty feet), and a field of view less than 180
degrees.
-27-
29. Models with wider fields of view, including 360 degrees, are available
typically designed to mount on a ceiling. Some larger PIRs are made with single
segment mirrors and can sense changes in infrared energy over one hundred feet
Away from the PIR. There are also PIRs designed with reversible orientation
mirrors which allow either broad coverage (110° wide) or very narrow “curtain”
coverage or with individually selectable segments to “shape" the coverage.
SPECIFICATION
Can detect human and animals.
Operating voltage 3.3V-5V.
Comparators used in those sensor modules which give a digital output.
Output form: Digital switching output (0 and 1).
MOSFET IRF540N
The metal–oxide–semiconductor field-effect transistor (MOSFET, MOS-
FET, or MOSFET) is a type of transistor used for amplifying or switching
electronic signals. The main advantage of a MOSFET over a regular transistor is
that it requires very little current to turn on (less than 1mA), while delivering a
much higher current to a load. The MOSFET has a three-terminal device with
source (S), gate (G), drain (D), and body (B) terminals.
Fig 4.13 MOSFET Representation
-28-
30. FEATURES
Drain-Source Volt (Vds): 100V
Drain-Gate Volt (Vdg): 100V
Gate-Source Volt (Vgs): 20V
Drain Current (Id): 30A
Power Dissipation (Ptot): 150W
Type: N-Channel
APPLICATIONS
Digital integrated circuits such as microprocessors and memory devices
contain thousands to millions of integrated MOSFET transistors on each
device, providing the basic switching functions required to implement logic
gates and data storage.
Discrete devices are widely used in applications such as switch mode power
supplies, variable-frequency drives and other power electronics applications
where each device may be switching hundreds or thousands of watts.
Radio-frequency amplifiers up to the UHF spectrum use MOSFET
transistors as analog signal and power amplifiers.
Radio systems also use MOSFETs as oscillators, or mixers to convert
frequencies.
MOSFET devices are also applied in audio-frequency power amplifiers for
public address systems, sound reinforcement and home and automobile
sound systems.
-29-
31. ZIGBEE TX RX
The XBee RF module is the product based on ZigBee protocol. So it also
uses IEEE 802.15.4 standards. It can support a wireless sensor network which
requires low-cost and low-power. For the XBee RF module, it does not need too
much power and it can provide a reliable way to communicate between two or
more devices. It interfaces to a host device through a logic-level asynchronous
serial port. Through its serial port, the module can communicate with any logic and
voltage compatible UART; or through a level translator to any serial device (for
example through an XBee Adapter). The controlling with the XBee RF module is
very easy with the AT commands. The XBee RF module can be configured with
the AT (Application Transparent) mode or API (Application Programming
Interface) mode but in this thesis implementation, only the AT mode is used. So in
the next chapters, this thesis concentrates on the AT commands. /2/, /5/, /13/ A key
component of the ZigBee protocol is the ability to support mesh networking. In a
mesh network, nodes are interconnected with other nodes so that multiple
pathways connect to each node. In this project, three XBee RF modules were used
to build a small mesh network. In this wireless network, all of them could
communicate with each other with the suitable configuration.
ZigBee Protocol and Communication
ZigBee operates in the worldwide 2.4 GHz ISM (Industrial Scientific
Medical) band. Proprietary radios are the primary competitor of ZigBee today.
ZigBee is based on the IEEE 802.15.4 networking. The protocol stack can be
divided into two parts: IEEE 802.15.4 and the ZigBee Alliance. The physical layer
(PHY) and the MAC (Medium Access Control) layer are defined by the IEEE
802.15.4 specification. The ZigBee stack’s NWK (Network) layer of the ZigBee
stack and all layers above it are under the control of the ZigBee Alliance
specification. A typical ZigBee stack is organized in the fashion shown in Figure.
-30-
33. In a nutshell, the IEEE 802.15.4 standard defines the characteristics
of the physical and MAC layers. ZigBee builds upon the IEEE 802.15.4
standard and defines the network layer specifications and provides a framework
for application programming in the application layer /2/ .
UART Serial Communication
The Universal Asynchronous Receiver/Transmitter (UART) controller is
the key component of the serial communications subsystem of a computer. The
UART 14 takes bytes of data and transmits the individual bits in a sequential
fashion /1 /. At the destination, a second UART re- assembles the bits into
complete bytes /1 /. In this project, the communication between Raspberry Pi and
XBee RF module is the UART serial communication. Raspberry Pi can transmit
and receive bytes of data from XBee RF module.
-32-
35. Fig 4.16 LCD Pin outs to Arduino
Programming:
Algorithm to send data to LCD:
1.Make R/W low
2.Make RS=0; if data byte is command .RS=1;if data byte is data (ASCII value)
3.Place data byte on data register
4.Pulse E (HIGH to LOW)
5.Repeat the steps to send another data byte
-34-
36. LCD Initialization:
This is the pit fall for beginners. Proper working of LCD depend on the how the
LCD is initialized. We have to send few command bytes to initialize the LCD.
Simple steps to initialize the LCD
1.Specifyfunction set: Send 38Hfor 8-bit,double line and 5x7 dot character
format.
2.DisplayOn-Off control: Send 0FH for display and blink cursor on.
3.Entry mode set: Send 06H for cursorin increment position and shift is invisible.
4. Cleardisplay: Send 01H to clear display and return cursor to home position.
LCD commands and codes:
Fig 4.17 LCD Display codes Representation
-35-
37. LCD COMMANDS AND CODES:
1 Clear display screen
2 Return Home
4 Decrement cursor(shift cursor to left)
5 Increment cursor(shift cursorto right)
6 shift display right
7 shift display left
8 Display off, cursor off
A Display off, cursoron
C Display on, cursoroff
E Display on, cursorblinking
F Display on, cursorblinking
10 Shift cursor position to left
14 Shift cursorposition to right
18 Shift the entire display to the left
1C Shift the entire display to the right
80 Force cursorto the beginning of 1st line
C0 Forcecursorto the beginning of 2nd line
38 2 lines and 5 x 7 matrix.
-36-
38. Interfacing LCD with the Microcontroller
Fig 4.18 Typical LCD Interface Circuit
Circuit Explanation
The LCD we have used in this project is HD1234. This is an alphanumeric type of
LCD with 16 pins. Of which Pins 7 to 14 are used as data pins, through which an
8-bit data can be input to the LCD. These Pins are connected to the Port 0 of Micro
controller. There are 3 control pins RS (Pin-4), RW (Pin-5) and EN (Pin-6). The
RS pin is connected to the 28th Pin of micro controller. The RW pin is usually
grounded. The Enable pin is connected to 27th Pin. The LCD has two Rows and 16
Columns. The LCD is powered up with 5V supply connected to Pins 1(Gnd) and
2(Vcc). The Pin 3 is connected to Vcc through a Potentiometer. The potentiometer
is used to adjust the contrast level.
-37-
39. CHAPTER 5
CIRCUIT DIAGRAM DESCRIPTION
When AC is applied to the primary winding of the power transformer it can
either be stepped down or up depending on the value of DC needed. In this project
the transformer of 230v/15v is used to perform the step down operation where a
230V AC appears as 15V AC across the secondary winding. In the power supply
unit, rectification is normally achieved using a solid-state diode. Diode has the
property that will let the electron flow easily in one direction at proper biasing
condition. As AC is applied to the diode, electrons only flow when the anode and
cathode is negative. Reversing the polarity of voltage will not permit electron flow.
A commonly used circuit for supplying large amounts of DC power is the bridge
rectifier. A bridge rectifier of four diodes (4*IN4007) is used to achieve full wave
rectification. Two diodes will conduct during the negative cycle and the other two
will conduct during the positive half cycle. The DC voltage appearing across the
output terminals of the bridge rectifier will be somewhat less than 90% of the
applied RMS value. Filter circuits, which usually capacitor is acting as a surge
arrester always follow the rectifier unit. This capacitor is also called as a
decoupling capacitor or a bypassing capacitor, is used not only to ‘short’ the ripple
with frequency of 120Hz to ground but also to leave the frequency of the DC to
appear at the output. The voltage regulators play an important role in any power
supply unit. The primary purpose of a regulator is to aid the rectifier and filter
circuit in providing a constant DC voltage to the device. Power supplies without
regulators have an inherent problem of changing DC voltage values due to
variations in the load or due to fluctuations in the AC liner voltage. With a
regulator connected to the DC output, the voltage can be maintained within a close
tolerant region of the desired output. The regulators IC7812 and 7805 are used to
provide the +12v and +5v to the circuit.The below figure is shown in the circuit
diagram of the smart street light control system.
-38-
40. Fig 5.1 Circuit diagram of the smart street light control system
The Arduino Uno is a microcontroller board based on the
ATmega328. It has 14 digital input/output pins (of which 6 can be used as
PWM outputs), 6 analog inputs, a 16 MHz crystal oscillator, 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. The Uno differs from
all preceding boards in that it does not use the FTDI USB-to-serial driver chip.
Instead, it features the Atmega8U2 programmed as a USB-to-serial converter.
-39-
41. Comparator is often necessary to be able to detect a certain voltage and switch
a circuit according to the voltage that has been detected. Here we use LM324 as
comparator. This consists of 4 op-amps inbuilt on to it and 14 pins.
We can connect sensors with inverting inputs and potentiometers connected
on the Non-inverting inputs. The 4th pin of the LM324 is Vcc and 11th pin of the
LM324 is GND. The 5V supply is given to the Vcc. The output pins are interfaced
to the Micro controller. The comaparator which drives the IR sensors.
The relays are connected to microcontroller through ULN2003 relay driver
IC. The ULN2003 has 16 pins. The 9th pin of ULN2003 is Vcc and 8th pin of the
ULN2003 is GND. The 12V supply is given to the 9th pin of the ULN2003. The
ULN2003 has 7 input pins (1-7) and 7 output pins (10-16). The ULN consists of
Darlington arrays. The 1st pin of ULN2003 is connected to the 33rd pin of the
PIC16F877A microcontroller. The 16th pin of the ULN2003 is connected to the
relay, which drives the relay and the relay which drives the LEDs.
-40-
42. CHAPTER 6
SOFTWARE DESCRIPTION
6.1 Arduino IDE
Arduino is a flexible programmable hardware platform designed for artists,
designers, tinkerers, and the makers of things. Arduino’s little, blue circuit board,
mythically taking its name from a local pub in Italy, has in a very short time
motivated a new generation of DIYers of all ages to make all manner of wild
projects found anywhere from the hallowed grounds of our universities to the
scorching desert sands of a particularly infamous yearly arts festival and just
about everywhere in between. Usually these Arduino based projects require little
to no programming skills or knowledge of electronics theory, and more often than
not, this handiness is simply picked up along the way.
The Arduino ecosystem begins with the Arduino platform, itself several layers of
hardware and software working together to create a cohesive whole. We can
start with the hardware interface board—that little, blue circuit board that you
build into your projects. It has a fairly standard onboard microcontroller that can
interact with the world around it by using its programmable inputs and outputs,
as well as a USBport and controller for easily communicating with your computer.
This USB connectivity and friendly sockets for hookup wires to easily plug in to,
contribute to the high level of usability in the interface board design. Equally
important to this ecosystem is the Arduino development environment, a program
based on the Processing development environment (http://processing.org) that
you use to write, edit, compile, and upload your Arduino source code to the
interface board. The Arduino team made the general assumption that people
don’t really care about the myriad of technical specifics involved with
microcontroller architecture—they just want it to do something cool.
-41-
43. With that in mind, the Arduino development environment wraps up some of
the more techie parts of programming AVR microcontrollers into a nice, simple
library of Arduino-specific commands that are easier to use and easier to
understand, and built right into every sketch written for the Arduino. This
development environment is so versatile, that an Arduino interface board is not
even needed to use it. Instead, we can use the very same AVR microcontroller as
is built onto the interface board, but in an entirely different device.
In addition to the various aspects of the diverse Arduino ecosystem, we have the
programming language of the Arduino platform, which is the central focus of this
book. The core language used in the Arduino development environment is the C
computer programming language first developed at the research institute of Bell
Laboratories in the early 1970s for use with the UNIX operating system. C uses a
procedural language syntax that needs to be processed by a compiler to map
human-readable code to machine instructions. The long-standing popularity of C
lends the Arduino some of its heritage, but the code that we are writing in this
book is only mostly C. Because there are aspects of the C language that look like it
was written by dyslexic aliens, and with the language sometimes accused of being
overly cryptic and difficult for beginners to pick up, the Arduino team has
developed the standard Arduino library that provides a simple and targeted set of
functions that make programming the Arduino interface board about as easy as it
can get. Now, these libraries are themselves actually C++, itself a subset of the
original C language, but we really don’t need to go there. What’s important is that
most of the code that we will write for the Arduino, including its syntax, structure,
operators, control statements, and functions, remain fundamentally and
functionally the same as C. What will be unique to the Arduino, however, are all
sorts of functions that you will come to know and love, including pinMode(),
digitalWrite(), and delay() that are specific to the standard Arduino library.
-42-
44. For the purposes of this book, this basic framework of C combined with the
additional Arduino library that is automatically a part of every sketch that we
write, is what we will refer to as Arduino C. To illustrate this point, Listings 1-1 and
1-2 provide two examples of the same source code to blink the onboard LED
connected to digital pin 13. Listing 1-1. Blink LED with avr-libc #include #include
int main(void) { while (1) { PORTB = 0x20; _delay_ms(1000); PORTB = 0x00;
_delay_ms(1000); } return 1; } Listing 1-2. Blink LED with Arduino void setup() {
pinMode(13, OUTPUT); } void loop() { digitalWrite(13, HIGH); delay(1000);
digitalWrite(13, LOW); delay(1000); } These two different listings show two
functionally identical sketches, one written with the Arduino library and one
written without. The really nifty thing here is that, if you want to geek out, the
Arduino development environment is fully compatible and extensible using C/C++
code written using the avrlibc library, a subset of the standard C library, and the
GCC compiler, both written for Atmel’s standard 8-bit AVR microcontrollers.
Listing 1-1 is written with avr-libc while Listing 1-2 is written using the Arduino
library. They both are compatible with the Arduino development environment
and can be uploaded the same way to the Arduino board. The first example also
consumes a fifth of the amount of memory as the second example, coming in at
210 bytes as opposed to 1010 bytes. What the Arduino example lacks in memory
efficiency, however, it more than makes up for in usability and integration with
the Arduino interface board. For example, referring to the digital pin that our LED
is connected to as pin number 13 is generally easier for most people than the
hexadecimal address 0x20 on PORTB. This simplicity is one the benefits to writing
code using Arduino C. That is not to say that one is better than the other, but
simply that this scalability and flexibility is an oftenoverlooked benefit of learning
on the Arduino platformbecause it allows budding code-monkeys the opportunity
to develop into ever more powerful architectures later.
-43-
45. We will focus on programming the Arduino using the standard Arduino
libraries, although if you want to know more, full Documentation on the avr-libc
library packagecan be found at www.nongnu.org/avr-libc/. While we are at it, it is
also worth mentioning that it is even possible to program the Arduino interface
board using other development environments more often associated with
computer development, such as Eclipse, NetBeans, or any other development
package that you are familiar with … or if you have an aversion to the color teal.
By this point, we have a pretty good sense for what the Arduino is, its history,
and some of what you can do with it. It’s really exciting that with a few carefully
written commands, which you will learn in the upcoming chapters, you can make
things light up or move, sense the world around you, and generally make things
more fun. And now that you have some basic hardware in hand, including an
Arduino interface board, it’s time to get up and running. We need to do the
following before moving on to the next chapter: 1. Download and install the
Arduino development environment 2. Connect the Arduino board with a USB
cable and install drivers 3. Launch the Arduino application and open the Blink
example 4. Select your board and serial port 5. Upload your first sketch Don’t
worry. It’s not that difficult to get going. In fact, it’s generally hard to go wrong,
because it is nearly impossible to burn the house down or cut off an arm with an
Arduino. And even if you wire up something wrong, it’s probably okay because
the Arduino board is a tough little guy and can take some abuse. So don’t worry
that you might mess something up. Of course, we are going to make some
mistakes, but hopefully they will teach us something and we will become better
programmers and makers because of it. So let’s get on with it. Installing the
SoftwareFirstthings first, you need to download and install the Arduino software.
-44-
46. Because the Arduino Team is always making updates to the software, you should
head to the main download page on the Arduino web site
(http://arduino.cc/en/Main/Software), shown in Figure 6.1
Fig 6.1 Arduioo Downloading site
From here download and install the latest version of the software for your
particular operating system. Full installation instructions are available on the
Getting Started page at http://arduino.cc/en/ Guide/HomePage. Linux can be a
little tricky to get installed as of this writing, so be sure to carefully follow the
instructions posted. Connecting the Arduino With the software installed, you
should be able to connect your Arduino to the USB port on your computer using
an A-B USB cable. The Arduino’s power indicator LED will light up on the board,
letting us know that it has power and is ready to go. With a brand-new Arduino
Uno, the first time that it powers up, the pin 13 LED marked L will begin
-45-
47. To blink rapidly, letting us know that the board has been fully tested. On
Windows-based PCs or older Arduino boards, it is necessary to install a driver for
the Arduino’s onboard USB to Serial convertor, as shown in Figure 6.2. For the
latest on how to install these drivers, be sure to follow the instructions on the
drivers section of the Getting Started Guide at
http://arduino.cc/en/Guide/Windows#toc4.
Fig 6.2 Installation guide for Arduino
Opening a Sketch
Now you can launch the Arduino development environment. This will bring up an
empty window if this is your first time out. Open an example sketch by navigating
to the File menu ➤ Examples ➤ 1.Basics and select the sketch named Blink, as
shown in Figure 6.3. You should now see a very simple example sketch for
blinking the onboard LED once every second.
-46-
48. Fig 6.3 Navigator for sketch
Selecting the Board and Serial Port
Before we can upload our sample sketch, we need to select the correct board
type and serial port that the
board is attached to on our computer. Setting the correct board can be done in
the Tools ➤ Board menu
by selecting Arduino Uno or one of the other corresponding board names, as
shown in Figure 6.4.
Fig 6.4 Board selection
Next, we need to choose the correct serial port under the Tools ➤ Serial Port
menu, as shown in Figure 6.5 1-
12. This port should be named COM3, or something similar, on a Windows PC;
-47-
49. Fig 6.5 Port selection for serial data transfer
Uploading a Sketch Onceyou have selected the proper board and serial port, it’s
time for the fun part. To upload a sketch onto the Arduino board, simply hit the
Upload button on the toolbar, as shown in Figure6.6. The onboard LEDs marked
RX and TX will blink furiously and you will receive a messagein the status bar
that says, “Doneuploading.” That’s all there is to it!
-48-
50. With all the installing, connecting, and uploading done and out of the way, you
should now have a blinking LED on your Arduino Uno. That’s not to say you
already fully understand how it all works—becausethatwould kind of defeat the
entire purposeof this book. But now that we’vegot something to blink and know
that we can make it work, wemight as well jump into learning the basics of
programming the Arduino with our first project. By jumping right into how the
code works, wecan move fromhacking together lines of code that somebody else
gave us to actually writing them ourselves.
Fig 6.6 Arduino sketch
-49-
51. CHAPTER - 8
CONCLUSION
By using Smart Street light, one can save surplus amount of energy
which is done by replacing sodium vapor lamps by LED and adding an additional
feature for security purposes. It prevents unnecessary wastage of electricity, caused
due to manual switching OFF streetlights when it’s not required. It provides an
efficient and smart automatic streetlight control system with the help of IR sensors.
It can reduce the energy consumption and maintains the running cost. The system
is versatile, extendable and totally adjustable to user needs. Street-lights are a large
consumer of energy for cities using up to 50 percent of a city's energy budget. If
every city installs the proposed system then a lot of power can be saved. Proposed
system is power saving mechanism for street lights by using LED lamps as
replacement of normal lamps and using special power savings mechanism for
microcontroller. It turns out most reliable and time efficient way to switch
ON/OFF streetlights. It provides an effective measure to save energy by preventing
unnecessary wastage of electricity, caused due to manual switching or lighting of
street-lights when it is not required. It adopts a dynamic control methodology for
traffic flow. The proposed system is especially appropriate for street lighting in
remote urban and rural areas where the traffic is low at right times. The system is
versatile, extendable and totally adjustable to user needs
-55-
52. References
[1]. http://opensourceecology.org/wiki/Automation
[2]. S. Suganya, R. Sinduja, T. Sowmiya& S. Senthilkumar, Street light glow on
detecting vehicle movement using sensor-2017
[3]. K.Santha Sheela,S.Padmadevi, Survey on Street Lighting System Based On
Vehicle Movements -2019
[4]. Srikanth M, Sudhakar K N,ZigBee Based Remote Control Automatic Street
Light System -2018
[5]. M.Abhishek, Syed ajram shah, K.Chetan, K,Arun Kumar, Design and
implementation of traffic flow based street light control system with effective
utilization of solar energy, International journal of Science Engineering and
Advance Technology, IJSEAT, Vol 3, Issue 9, September -2018
[6]. C.Bhuvaneshwari, R.Rajeswari, C.Kalaiarasan, Analysis of Solar energy based
street light with auto tracking system, International Journal of Advanced Research
in Electrical, Electronics and Instrumentation Engineering, Vol 2, Issue 7, July
2019
[7]. Steve Chadwick,“Street Light Monitoring – a Practical Solution magazine”
November/December 2018
[8]. “Intelligent Street Lighting System Using Gsm” International Journal of
Engineering Science Invention ISSN (Online): 2319 – 6734, ISSN : 2319 –
6726Volume 2 Issue 3 March. 2019
[9]. “Wireless internet lighting control system”,Budike, E.S. Lothar (Power web
Technologies), US patent 7,167,777, Jan 23, 2017.
[10]. https://en.wikipedia.org/wiki/High-intensity_discharge_lamp
[11]. http://www.hobbytronics.co.uk/arduino-uno-r3
[12]. Tarun Agarwal. Retrieved from https://www.google. co.in
/webhp?sourceid=chromeinstant&ion=1&espv=2&ie=UTF- 8#q=ir%20sensors.
-56-