Drainage Management System

July 15, 2018 | Author: Shubham Thakare | Category: Rectifier, Embedded System, Microcontroller, Gsm, Computer Network
Share Embed Donate


Short Description

Drainage Management System...

Description

A Seminar-II Report on

“Internet of Things for Underground Drainage Monitoring System for Metropolitan Cities” By Shubham Vinayak Thakare

The Shirpur Education Society’s Department of Computer Engineering R. C. Patel Institute of Technology Shirpur - 425405. Maharashtra State, India [2017-18]

A Seminar-II Report on

“Internet of Things for Underground Drainage Monitoring System for Metropolitan Cities” Submitted By Shubham Vinayak Thakare Guided By Prof. M. M. mhajan

The Shirpur Education Society’s Department of Computer Engineering R. C. Patel Institute of Technology Shirpur - 425405. Maharashtra State, India [2017-18]

The Shirpur Education Society’s

R. C. Patel Institute of Technology Shirpu Shirpur, r, Dist. Dist. Dhule Dhule (M.S.) Department of Computer Engineering Maharashtra State, India

CERTIFICATE

This is to certify that minor project entitled “Internet of Things for Underground Drainage Monitoring System for Metropolitan Cities”  has been carried out by team: Shubham Vinayak Thakare

Prof. M. M. Mahajan Mahajan  during the of TE Computer Engineering class under the guidance of   Prof. academic year 2017-18. Date: Place: Place: Shirpur Shirpur

Guide Prof. M. M. Maha jan

Seminar-II Co ordinator Prof. P. S. Sanjekar

H. O. D. Prof. Nitin N. Patil

Principal Prof. Dr. J. B. Patil

ACKNOWLEDGEMENT We take this opportunity to express our heartfelt gratitude towards the Department of Computer Engineering RCPIT,Shirpur that gave us an opportunty for presentation of our Project in their esteemed organization. It is a privilege for us have to been associated with   Prof Prof.. M. M. Mahajan, our guide during project work.We have been greatly beneted by his valuable suggestion and ideas.It is with great pleasure that express our deep sense of gratitude to his for his valuable guidance, constant encouragement and patience throughout this work.

 Prof. Nitin Nitin N. Patil Patil,, [HOD [HOD Comput Computer] er]  for his constant We express our gratitude to  Prof. encouragement, co-operation and support and also thankful to all people who have contributed in their own way way in making making this project success. success. We take take this this opportuni opportunity ty to thank thank all the classmates for their company during the course work and for useful discussion we had with them.  Prof. f. Dr. Dr. J. B. Pati Patill, who presented us with We would also like to thank our Principal  Pro such an opportunity to expand our horizons of knowledge prayed for us. Shubham Vinayak Thakare

Contents List of Figures

iii

1 Intro duction 1.1 Emb edded Systems Overview . . . . . . . . 1.1.1 Introd odu uction of Embed bedded System . . 1.1.2 History and Future . . . . . . . . . . 1.1.3 Real Time Systems . . . . . . . . . . 1.2 Application Areas . . . . . . . . . . . . . . . 1.2.1 Consumer appliances . . . . . . . . . 1.2.2 Office automation . . . . . . . . . . . 1.2.3 Medical electronics . . . . . . . . . . 1.2.4 Computer networking . . . . . . . . . 1.2.5 Telecommunications . . . . . . . . . 1.2.6 Wireless technologies . . . . . . . . . 1.2.7 Insemination . . . . . . . . . . . . . 1.2.8 Security . . . . . . . . . . . . . . . . 1.2.9 Finance . . . . . . . . . . . . . . . . 1.3 Overview of Embed bedded System Architecture

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

. . . . . . . . . . . . . . .

1 2 2 3 3 4 4 4 4 5 5 5 5 5 6 6

2 INTRODUCTION TO WIRELESS COMMUNICATION 9 2.1 Applicati cation onss of Wirel reless Data ata Comm ommunicati ations . . . . . . . . . . . . . . . . . . 10 2.2 Global System for Mobile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 2.3 GSM services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 3 EXPLANATION OF EACH BLOCK 3.1 Power Supply Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.2 microcontrollers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3 description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

14 14 17 19

4 ARDUINO/GENUINO UNO 24 4.1 What’s on the b oard? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 5 THE ARDUINO FAMILY 28 5.1 Arduino Uno (R3) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 5.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 5.3 Worki rking with Water ter Flow Sen Sensors ors & Arduino uino . . . . . . . . . . . . . . . . . . . 29 i

5.4 5.5 5.6

How to use use the Water ter Lev Level Sen Sensor – Ardu duiino . . . . . . . . . . . . . . . . . . . 31 Advantage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33

6 CONCLUSION 34 6.1 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 BIBLIOGRAPHY

35

ii

List of Figures 1.1 1.2

Architecture of Embed bedded System . . . . . . . . . . . . . . . . . . . . . . . . . . Central processing Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

6 7

2.1

Global System for Mobile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

12

3.1 3.2 3.3 3.4 3.5

Design of Power Sypply . . . . . Internal working of Power Supply Bridge Rectifier . . . . . . . . . . Micro cotroller . . . . . . . . . . . PIN Diagram . . . . . . . . . . .

. . . . .

14 15 16 18 20

4.1

Arduino/Genuino UNO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

25

5.1 5.2 5.3

Arduino UNO(R3) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Flow of Sensors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 Connection with Arduino kit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33

. . . . .

. . . . .

. . . . .

iii

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

ABSTRACT Internet of Things for Underground Drainage Monitoring System for Metropolitan Cities India has announce announced a proje project ct of making making 100 smart cities. For making a smart smart city one nee needs  to consider many parameters such as smart water, smart electricity, smart transportation etc. There There will be a nee need of smart smart under underground ground infrastr infrastructu ucturre which includes includes under underground ground water  pipeline pip elines, s, communic ommunicatio ation n cables, ables, gas pipelines pipelines,, electric electric flow, etc. As most of the cities in India  have adopted underground drainage system, it is very important that this system should work  in prop proper er manner to keep keep the city clean, clean, safe and healthy. healthy. If they fail to maintain maintain the draina drainage  ge  system system the pure pure water water may get contaminat ontaminateed with drainag drainagee water water and can spre spread infectiou infectious  s  diseases diseases.. So different different kind of work has been been done to detect, detect, maintain and manage manage these these underunderground ground systems. Also Leaks Leaks and bursts are an unavoidable aspect aspect of water distribution systems  managemen management, t, and can acc account for significa significant nt water water loss within a distribut distribution ion network network if left  undete undetecte cted d for long periods. eriods. This paper paper presen presents ts the implementa implementation tion and design design functions functions for  monitoring and managing undergr underground ound drainage system with different approaches. approaches. It also gives  description about Water wise system and detection method to detect leakage defects in sewer  pipeline. pip eline. Also some part of condition condition rating model for undergr underground ound Infrastructure Infrastructure Sustainable  Water Water Mains and Intelligent Intelligent system system for undergr underground ound pip pipeline eline assessm assessment, ent, rehabilita ehabilitation tion and  management are explained.

Chapter 1 Introduction Underground Underground drainage system is important component of urban infrastructure. infrastructure. It is considered considered to be city’s city’s lifelin lifeline. e. Most Most manageme management nt on undergro underground und drainage drainage is manual manual therefor thereforee it is not efficient efficient to have have clean and working working underground system. Therefore, Therefore, it is essential essential to develop develop a system which can handle underground drainage drainage without human human intervention. intervention. Underground Underground Drainage Drainage involves involves sewerage system, gas pipeline network, network, water pipeline and manholes. manholes. Different functions are described which are used for maintenance and monitoring underground drainage system. Underground manhole is one of the most efficient solutions to drainage .However putting these manholes underground is very challenging. Also the difficulties derived from the fact that manhole manhole is hard to search search once it is hide hide und under er the road surface. surface. Therefor Therefore, e, it is necessary to develop a set of mechanism which can be used to search, authenticate manhole in order to manage this problem. Closings of these manholes are covered by a manhole cover. Manhole cover is a flat plug which is designed to protect from unauthorized access. Also some people implements implements Underground Drainage Drainage and Manhole Monitoring System. System. This is a model mo del which provides a system which is able to monitor the water level, atmospheric temperature. Also it can be used to find pressure inside a manhole and to check whether a manhole lid is open. Also Also this this system system can be used to monitor monitorss und undergr erground ound install installed ed electric electric pow power er lines. Manhole explosion is one of the most dangerous and serious problems as these explosions releases of chemical and electrical energy inside a manhole. Manhole explosion events can be of  three types mainly smoking events, fires and explosion due to sudden raise in pressure so they can monitor monitor these these manhole manholess using using sensors. sensors. If such drainage drainage system system gets blocked blocked and wa water ter overflo overflows ws it can be identifi identified ed by sensor sensor system[ system[2]. 2]. Also Also if suppose that manhole manhole lid is open it will immediately sense by the sensor in system, and that sensor sends information via transmitter which is located in that area to the corresponding managing station. But sometime this fails to solve these kinds of problems because it increases the number of sensors. It is not able to provide scalability. These are reasons for significant water loss. Therefore it is necessary to build a system which has the ability to detect and localize pipe burst and leaks.

1

RCPIT, Shirpur

1.1 1.1

Embed Embedde ded d Syst System emss Over Overvi view ew

1.1.1 1.1.1

Introd In troduct uction ion of Embedde Embedded d Syste System m

An Embedded System is a combination of computer hardware and software, and perhaps additional mechanical or other parts, designed to perform a specific function. A good example is the microwave oven. Almost every household has one, and tens of millions of them are used everyday, but very few people realize that a processor and software are involved in the preparation of their lunch or dinner. This is in direct This direct contra contrast st to the the persona personall compu computer ter in the famil family y room. room. It too is comprised of computer hardware and software and mechanical components (disk drives, for example). However, a personal computer is not designed to perform a specific function rather; it is able able to do many different different things. things. Many Many people people use the term generalgeneral-purpo purpose se computer computer to make this distinctio distinction n clear. clear. As shipped, shipped, a general general-pu -purpose rpose computer computer is a blank blank slate; the manufac manufacture turerr does not know know what the customer customer will do wish wish it. One customer customer may use it for a network file server another may use it exclusively for playing games, and a third may use it to write the next great American novel[3]. Frequently, an embedded system is a component within some larger system. For example, modern cars and trucks contain many embedded systems. One embedded system controls the anti-lock brakes, other monitors and controls the vehicle’s emissions, and a third displays information on the dashboard. In some cases, these embedded systems are connected by some sort of a communication network, but that is certainly not a requirement. At the possible risk of confusing you, it is important to point out that a general-purpose computer is itself made up of numerous embedded systems. systems. For example, my computer consists of a keyboard, mouse, video card, modem, hard drive, floppy drive, and sound card-each of  which which is an embedded embedded system. system. Each Each of these device devicess contai contains ns a processor processor and software software and is designed designed to perform perform a specific specific function. function. For example, example, the modem is designed designed to send and receiv receivee digital digital data over over analog analog telephone telephone line. Tha That’s t’s it and all of the other devices devices can be summarized in a single sentence as well[6]. If an embedded system is designed well, the existence of the processor and software could could be compl complete etely ly unnotic unnoticed ed by the user user of the device. device. Such Such is the case case for for a micro microw wave ave oven, oven, VCR, or alarm alarm clock. In some cases, it wo would uld even even be possible possible to build build an equiv equivalent alent device device that does not contain contain the processor processor and softwa software. re. This This could could be don donee by replacin replacingg the combination with a custom integrated circuit that performs the same functions in hardware. However, a lot of flexibility is lost when a design is hard-cooled in this way. It is mush easier, and cheaper, to change a few lines of software than to redesign a piece of custom hardware[3].

2

RCPIT, Shirpur

1.1. 1.1.2 2

Hist Histor ory y and and Futur uture e

Given the definition of embedded systems earlier is this chapter; the first such systems could not possibly have appeared before 1971. That was the year Intel introduced the world’s first microprocessor. This chip, the 4004, was designed for use in a line of business calculators produced by the Japanese Company Busicom. In 1969, Busicom asked Intel to design a set of  custom custom integr integrated ated circuits circuits-one -one for each each of their their new calculator calculator models. The 4004 wa wass Intel Intel’s ’s response rather than design custom hardware for each calculator, Intel proposed a generalpurpose purpose circuit circuit that could be used used througho throughout ut the entire entire line line of calcul calculator ators. s. Intel Intel’s ’s idea wa wass that the software would give each calculator its unique set of features. The microcontroller was an overnight success, and its use increased steadily over the next decade. Early Early embedde embedded d applica application tionss included included unmanned unmanned space space probes, probes, compute computeriz rized ed traffic lights, and aircraft flight control systems. In the 1980s, embedded systems quietly rode the waves of the microcomputer age and brought microprocessors into every part of our kitchens (bread machines, machines, food processors, and microwa microwave ve ovens), ovens), living rooms ro oms (televisions, (televisions, stereos, and remote controls), and workplaces (fax machines, pagers, laser printers, cash registers, and credit card readers). It seems inevitable hat the number of embedded systems will continue to increase rapidly. rapidly. Already Already there are promising new embedded devices that have enormous market potential; light switches and thermostats that can be central computer, intelligent air-bag systems that don’t inflate when children or small adults are present, pal-sized electronic organizers and personal digital assistants (PDAs), digital cameras, and dashboard navigation systems. Clearly, individuals who possess the skills and desire to design the next generation of embedded systems will be in demand for quite some time[5].

1.1. 1.1.3 3

Real Real Time Time Syst System emss

One subclass subclass of embedde embedded d is worthy worthy of an introducti introduction on at this point. point. As commonly commonly defined, fined, a real-ti real-time me system is a computer computer system system that has timing timing constrain constraints. ts. In other other wo words rds,, a real-time system is partly specified in terms of its ability to make certain calculations or decisions in a timely manner. These important calculations are said to have deadlines for completion. And, for all practical purposes, a missed deadline is just as bad as a wrong answer[4]. The issue of what if a deadline is missed is a crucial one. For example, if the real-time system is part of an airplane’s flight control system, it is possible for the lives of the passengers and crew to be endanger endangered ed by a single single missed missed deadlin deadline. e. Howe Howeve ver, r, if instead instead the system is involved in satellite communication, the damage could be limited to a single corrupt data packe packet. t. The more severe severe the consequenc consequences, es, the more likely likely it will will be said said that the deadlin deadlinee is ”hard” and thus, the system is a hard real-time system. Real-time systems at the other end of  this discussion are said to have ”soft” deadlines[1]. All of the topics and examples presented in this book are applicable to the designers of real-time real-time system system who is more more deligh delightt in his wo work. rk. He must guarantee guarantee reliable reliable operation operation of  3

RCPIT, Shirpur the software and hardware under all the possible conditions and to the degree that human lives depend upon three system’s proper execution, engineering calculations and descriptive paperwork[7].

1.2 1.2

Appl Applic icat atio ion n Area Areass

Nearl Nearly y 99 per cent cent of the process processors ors manufa manufactu ctured red end up in embedd embedded ed syst system ems. s. Th Thee emembedded system market is one of the highest growth areas as these systems are used in very market segment- consumer electronics, office automation, industrial automation, biomedical engineering, wireless communication, data communication, telecommunications, transportation, military and so on.

1.2.1 1.2.1

Consu Consumer mer applia appliance ncess

At home we use a number of embedded systems which include digital camera, digital diary, DVD player, electronic toys, microwave oven, remote controls for TV and air-conditioner, VCO player, video game consoles, video recorders etc. Today’s high-tech car has about 20 embedded systems for transmission control, control, engine spark control, air-conditioning, air-conditioning, navigation navigation etc. Even wrist wristwa watch tches es are now now becoming becoming embedded embedded systems systems.. The palmt palmtops ops are pow powerfu erfull embedde embedded d systems using which we can carry out many general-purpose tasks such as playing games and word processing[8]. processing[8].

1.2. 1.2.2 2

Office Office au auto toma mati tion on

The office automation products using em embedded systems are copying machine, fax machine, key telephone, telephone, modem, printer, scanner etc. Industrial Industrial automation: Today a lot of industries use embedde embedded d systems systems for process process control control.. These These includ includee pharmac pharmaceuti eutical cal,, cement, cement, sugar, oil exploration, nuclear energy, electricity generation and transmission. The embedded systems for industrial use are designed to carry out specific tasks such as monitoring the temperature, pressure, humidity, voltage, current etc., and then take appropriate action based on the monitored levels levels to control control other devices devices or to send informati information on to a central centralize ized d monitori monitoring ng station. station. In hazardous industrial environment, where human presence has to be avoided, robots are used, which which are programm programmed ed to do specific jobs. The robots are now now becoming becoming very powerfu powerfull and carry out many interesting and complicated tasks such as hardware assembly[5].

1.2.3 1.2.3

Medic Medical al electr electroni onics cs

Almost Almost every medical medical equipm equipmen entt in the hospital hospital is an embedde embedded d system. system. These These equipm equipment entss include diagnostic aids such as ECG, EEG, blood pressure measuring devices, X-ray scanners; equipmen equipmentt used used in blood analysi analysis, s, radiatio radiation, n, colonosc colonoscop opy y, endoscop endoscopy y etc. Develop Developmen ments ts in medical electronics have paved way for more accurate diagnosis of diseases[2].

4

RCPIT, Shirpur

1.2.4 1.2.4

Compu Computer ter netw networking orking

Computer networking products such as bridges, routers, Integrated Services Digital Networks (ISDN), Asynchronous Transfer Mode (ATM), X.25 and frame relay switches are embedded systems which implement the necessary data communication protocols. For example, a router interconnects two networks. The two networks may be running different protocol stacks. The router’s function is to obtain the data packets from incoming pores, analyze the packets and send them towards the destination after doing necessary protocol conversion. Most networking equipments, other than the end systems (desktop computers) we use to access the networks, are embedded systems.

1.2.5 1.2.5

Telecomm elecommunica unication tionss

In the field of telecommunications, the embedded systems can be categorized as subscriber terminals and network network equipment. equipment. The subscriber terminals such as key telephones, telephones, ISDN phones, terminal adapters, web cameras are embedded systems. The network equipment includes multiplexers, multiple access systems, Packet Assemblers Dissemblers (PADs), sate11ite modems etc. IP phone, IP gatewa gateway y, IP gatekeeper gatekeeper etc. are the latest latest embedded embedded system systemss that provide provide very low-cost voice communication over the Internet[2].

1.2.6 1.2.6

Wirele Wireless ss techno technolog logies ies

Advances in mobile communications are paving way for many interesting applications using embed embedded ded system systems. s. Th Thee mobi mobile le phone phone is one of the the marv marvel elss of the last last decade decade of the 20th century century.. It is a very very pow powerfu erfull embedde embedded d system system that provid provides es voice voice communica communicatio tion n while while we are on the move move.. The Personal Personal Digital Digital Assistan Assistants ts and the palmtops palmtops can now be used to access multimedia services over the Internet. Mobile communication infrastructure such as base station controllers, mobile switching centers are also powerful embedded systems[5].

1.2. 1.2.7 7

Inse In semi mina nati tion on

Testing and measurement are the fundamental requirements in all scientific and engineering activit activities ies.. The measuring measuring equipmen equipmentt we use in laborator laboratories ies to measure measure parameters parameters such as weight, weight, temperature, pressure, humidity humidity,, voltage, current etc. are all embedded systems. systems. Test equipmen equipmentt such such as oscillo oscilloscope scope,, spectrum spectrum analyzer analyzer,, logic logic analyzer analyzer,, protocol protocol analyzer analyzer,, radio radio communi communicati cation on test set etc. are embedded embedded systems systems built around powerfu powerfull processor processors. s. Than Thank k to miniaturization, the test and measuring equipment are now becoming portable facilitating easy testing and measurement in the field by field-personnel[7].

1.2. 1.2.8 8

Secu Securi ritty

Securit Security y of persons and informa informatio tion n has always always been a major issue. We need to protect protect our homes homes and offices; offices; and also the informati information on we transmi transmitt and store. store. Develop Developing ing embedded embedded systems systems for securit security y applicat application ionss is one of the most most lucrati lucrative ve busines businesses ses nowa nowada days. ys. Securit Security y devices devices at homes, homes, offices, offices, airports airports etc. for authentica authentication tion and verific verificatio ation n are embedded embedded syssystems. tems. Encrypti Encryption on devices devices are nearly nearly 99 per p er cent of the processors processors that are manufa manufactur ctured ed end 5

RCPIT, Shirpur up in embedde embedded d systems systems.. Embedde Embedded d systems systems find applicati applications ons in every every industri industrial al segmentsegmentconsumer electronics, transportation, avionics, avionics, biomedical engineering, engineering, manufacturin manufacturing, g, process control and industrial automation, data communication, telecommunication, defense, security etc. Used Used to encrypt encrypt the data/v data/voic oicee being transmitt transmitted ed on commu communic nicatio ation n links links such such as teletelephone lines. Biometric Biometric systems using fingerprint and face recognition recognition are now being extensively extensively used for user authentication authentication in banking applications applications as well as for access control in high security buildings.

1.2. 1.2.9 9

Fina Financ nce e

Financial dealing through cash and cheques are now slowly paving way for transactions using smart cards and ATM (Automatic Teller Machine, also expanded as Any Time Money) machines. Smart card, of the size of a credit card, has a small micro-controller and memory; and it interacts with the smart card reader! ATM machine and acts as an electronic wallet. Smart card technology has the capability of ushering in a cashless society. Well, the list goes on. It is no exaggeration to say that eyes wherever you go, you can see, or at least feel, the work of an embedded system! system!

1.3

Overv Overview iew of Em Embedded bedded Syste System m Arc Architect hitecture ure

Every embedded system consists of custom-built hardware built around a Central Processing Unit (CPU). This hardware also contains memory chips onto which the software is loaded. The software residing on the memory chip is also called the ‘firmware’. The embedded system architecture can be represented as a layered architecture.

Figure 1.1: Architecture of Embedded System The operating system runs above the hardware, and the application software runs above 6

RCPIT, Shirpur the operating system. The same architecture is applicable to any computer including a desktop computer. However, there are significant differences. It is not compulsory to have an operating system in every embedded system. For small appliances such as remote control control units, air conditioners, toys etc., there is no need for an operating system and you can write only the software specific to that application. application. For applications applications involving involving complex processing, it is advisable to have an operating system. In such a case, you need to integrate the application software with the operating operating system system and then transfer transfer the entire entire softwa software re on to the memory chip. chip. Once the software is transferred to the memory chip, the software will continue to run for a long time you don’t need to reload new software[7]. Now, let us see the details of the various building blocks of the hardware of an embedded system. As shown in Fig. the building blocks are : •  Central Processing Unit (CPU) •  Memory (Read-only Memory and Random Access Memory) •  Input Devices •  Output devices •   Communication interfaces •   Application-specific circuitry

Figure 1.2: Central processing Unit 1. Central Processing Unit (CPU) The Central Processing Unit (processor, in short) can be any of the following: microcontroller, troller, microprocessor microprocessor or Digital Digital Signal Processor (DSP). A micro-control micro-controller ler is a low-cost low-cost 7

RCPIT, Shirpur processo processor. r. Its main attraction attraction is t2hat t2hat on the chip chip itself, itself, there there will will be many many other other comcomponents such as memory, serial communication interface, analog-to digital converter etc. So, for small applications, a micro-controller is the best choice as the number of external componen components ts required required will be very very less. On the other other hand hand,, micropr microprocess ocessors ors are more powerful, but you need to use many external components with them. D5P is used mainly for applications in which signal processing is involved such as audio and video processing. 2. Memory The memory is categorized as Random Access Memory (RAM) and Read Only Memory (ROM). The contents of the RAM will be erased if power is switched off to the chip, whereas whereas ROM retains retains the conten contents ts even if the power power is switched switched off. So, the firmwa firmware re is stored in the ROM. When power is switched on, the processor reads the ROM; the program is program is executed. 3. Input devices Unlike the desktops, the input devices to an embedded system have very limited capability bility. There will be no keyboard or a mouse, and hence interacting interacting with the embedded system is no easy task. Many embedded systems will have a small keypad-you press one key key to give give a specific specific command. command. A keypad keypad may be used to input only only the digits digits.. Many Many embedded systems used in process control do not have any input device for user interaction; they take inputs from sensors or transducers 1’fnd produce electrical signals that are in turn fed to other systems. 4. Output devices The output devices devices of the embedded embedded systems systems also have very limited limited capabilit capability y. Some embedded systems will have a few Light Emitting Diodes (LEDs) to indicate the health status of the system modules, or for visual indication indication of alarms. A small Liquid Crystal Crystal Display (LCD) may also be used to display some important parameters. 5. Communicatio Communication n interfaces The embedded systems may need to, interact with other embedded systems at they may have have to transmit transmit data to a desktop. To facilitate this, the embedded systems are provided provided with one or a few communication interfaces such as RS232, RS422, RS485, Universal Serial Bus (USB), IEEE 1394, Ethernet etc. 6. ApplicationApplication-specific specific circuitry Sensors, transducers, special processing and control circuitry may be required fat an embedded system, depending on its application. This circuitry interacts with the processor to carry out the necessary work. The entire hardware has to be given power supply either through through the 230 volts volts main main supply supply or through through a battery battery.. The hardware hardware has to design in such a way that the power consumption is minimize. 8

Chapter 2 INTRODUCTION TO WIRELESS COMMUNICATION In the world today, everything would be incredibly different if it were not for wireless communication devices. The fact that we can communicate with people in other parts of our own country country and the world world is amazing amazing and has led to lots of change changess in human history history.. There There are various kinds of wireless communication tools and here we will look at a few different kinds as well as the benefits of having them. 1. Short Distances Sometimes wireless communication does not happen across thousands of miles but only across across a few feet. For instance, instance, if you you have have a televi televisio sion n with with a remote remote control, control, there is communication happening between the two. The remote control tells the television what to do and this information is transferred without the use of any wires. You could also use walkie walkie talkies for this purpose. These are little devices that work like telephones telephones except with different methods and will allow two people or a group of people to talk to each other from a small distance away, such as at a festival or celebration. 2. Benefits of Short Distance Wireless Communication Having Having these short distance devices allows allows many things to happen. You do not have to get up to change the channel, for one thing. With walkie talkies you are able to communicate with a group of people, which means that people who need to work together such as police men or fire fighters or security guards can do so at special events without having to take the time to dial a phone number. This can save time and sometimes lives. 3. Medium and Long Distances Anything that can connect to the internet is capable of going through medium or long distances. distances. Many forms of wireless communicati communication on such as cell phones and laptop computers can send information from ten feet to thousands of miles because they can connect to the internet. Wireless Wireless communication communication of this form has changed changed the world world dramatically. dramatically. One of the most widely acknowledged benefits of long distance wireless communication is that people can perform their jobs at a distance. If they are trying to contact their boss or write a report, they can do so from almost any part of the globe without having to be physicall physically y present. This reduces travel travel costs and the impact of travel on the environmen environment. t. 9

RCPIT, Shirpur Another benefit of long distance wireless communication is that families can stay in touch with with each other other even even if one of them is far far aw away ay.. It used to be that that if someo someone ne was on a business trip, they would have to write a letter to communicate with their loved ones. Now they can communicate through video and show their family exactly where they are so that the family can connect about these experiences and maintain closer relationships with with each each other[3] other[3].. The types and forms of wireles wirelesss communi communicati cation on are changi changing ng at a rapid pace to include ever more increasing advances in technology. The benefits of these devices are many and range from benefits that relate to our jobs to those that relate to our loving loving connection to our families. families. There is virtually virtually no end to the amount amount that human kind can advance given the incredible leaps and bounds we are making with technology!

2.1

Applic Applicati ations ons of of Wirele Wireless ss Data Data Comm Communi unicat cation ionss

Wireless Wireless data communicati communications ons are an essential component component of mobile computing. computing. The various various available technologies differ in local availability, coverage range and performance, and in some circumstances, users must be able to employ multiple connection types and switch between them. To simplify the experience for the user, connection manager software can be used, or a mobile VPN deployed to handle the multiple connections as a secure, single virtual network. Supporting technologies technologies include: 1. Wi-Fi is a wireless wireless local area network that enables enables portable computing devices devices to connect easily easily to the internet. internet. Standard Standardized ized as IEEE IEEE 802.11a, 802.11a,b,g b,g,n, ,n, Wi-Fi Wi-Fi approac approaches hes speeds of some types of wired Ethernet. Ethernet. Wi-Fi Wi-Fi has become the de facto standard standard for access in private private homes, within offices, and at public hotspots. Some businesses businesses charge customers a monthly fee for service, while others have begun offering it for free in an effort to increase the sales of their goods. 2. Cellular Cellular data service offers coverage coverage within a range of 10-15 miles from the nearest cellsite. cellsite. Speeds Speeds have have increas increased ed as technol technologie ogiess have have evolv evolved, ed, from earlier earlier technol technologi ogies es such such as GSM,CDMA and GPRS, to3G networks such as W-CDMA,EDGE or CDMA2000 3. Mobile Satellite Communications may be used where other wireless connections are unavailable, such as in largely rural areas or remote locations Satellite Communication are especially important for transportation, aviation, maritime and military.

2.2 2.2

Glob Global al Syst System em for for Mob Mobil ile e

It is a globall globally y accepted accepted standard standard for digital digital cellular cellular communi communicati cation. on. GSM is the name of  standardization group established in 1982 to create a common European mobile telephone standard that would formulate specifications for a pan-European mobile cellular radio system operating at 900MHZ[5]. Throughout the evolution of cellular telecommunications, various systems have been developed without the benefit of standardized specification. This presented many problems directly related to compatibilit compatibility y, especially especially with the developmen developmentt of digital radio technology. technology. The GSM standard is intended to address these problems.

10

RCPIT, Shirpur

GSM-Introduction •   Architecture •  Technical Specifications •  Frame Structure •   Channels •  Security •  Characteristics and features •   Applications

Definition Global System for Mobile (GSM) is a second generation cellular standard developed to cater voice services and data delivery using digital modulation. GSM-History • Developed Developed by Group Special Sp ecial Mobile (founded 1982) which was an initiative

of CEPT (Conference of European Post and Telecommunication) •  Aim : to replace the incompatible analog system •  Presently the responsibility of GSM standardization resides with special

mobile group under ETSI ( European telecommunication Standards Institute ) •  Full set of specifications phase-I became available in 1990 •  Under ETSI, GSM is named as “Global System for Mobile communication

“ •  Today many providers all over the world use GSM (more than 135 Coun-

tries in Asia, Africa, Europe, Australia, America) •  More than 1300 million subscribers in world and 45 million subscribers in

India.

11

RCPIT, Shirpur

Figure 2.1: Global System for Mobile

2.3

GSM GS M serv servic ices es

1. Tele-services 2. Bearer or Data Services 3. Supplementary services 1. Tele-services •  Telecommunication services that enable voice communication via mo-

bile phones •  Offered services •  Mobile telephony •  Emergency calling

2. Bearer or Data Services •  Include various data services for information transfer between GSM

and other networks like PSTN, ISDN etc at rates from 300 to 9600 bps •  Short Message Service (SMS) 12

RCPIT, Shirpur

•  up to 160 character alphanumeric data transmission to/from the mo-

bile terminal •  Unified Messaging Services(UMS) •  Group 3 fax •  Voice mailbox •  Electronic mail

3. Supplementary services

all related services •  Call Waiting- Notification of an incoming call while on the handset •  Call Hold- Put a caller on hold to take another call •  Call Barring- All calls, outgoing calls, or incoming calls •  Call Forwarding- Calls can be sent to various numbers defined by the

user •  Caller line identification presentation •  Multi Party Call Conferencing - Link multiple calls together •  CLIP – CLIR – Caller line identification restriction •  CUG – Closed user group

13

Chapter 3 EXPLANATION OF EACH BLOCK 3.1 3.1

Power Su Supp pply ly Desi Design gn

Figure 3.1: Design of Power Sypply

The input input to the circui circuitt is ap appli plied ed from from the regulat regulated ed po powe werr suppl supply y. The a.c. a.c. input input i.e., i.e., 230V 230V from from the the mains mains supply supply is step step do down wn by the transfo transforme rmerr to 12V an and d is fed fed to a rect rectifi ifier er.. Th Thee ou outp tput ut obtai obtaine ned d from from the rect rectifi ifier er is a pulsating d.c voltage. So in order to get a pure d.c voltage, the output voltage from the rectifier is fed to a filter to remove any a.c components present even after rectification. Now, this voltage is given to a voltage regulator to obtain a pure constant dc voltage[6].

14

RCPIT, Shirpur

Transformer Usually, DC voltages are required to operate various electronic equipment and these voltages are 5V, 9V or 12V. But these voltages cannot be obtained directly. Thus the a.c input available at the mains supply i.e., 230V is to be brought down to the required voltage level. This is done by a transformer. Thus, a step down transformer is employed to decrease the voltage to a required level. Rectifier The output from the transformer is fed to the rectifier. It converts A.C. into pulsating D.C. The rectifier may be a half wave or a full wave rectifier. In this project, a bridge rectifier is used because of its merits like good stability and full wave rectification.

Figure 3.2: Internal working of Power Supply

The Bridge rectifier is a circuit, which converts an ac voltage to dc voltage using using both both ha half lf cycle cycless of the input input ac voltag oltage. e. The Bridge Bridge rectifi rectifier er circui circuitt is shown shown in the fig figure ure.. The circuit circuit has four four diodes connect connected ed to form form a bridg bridge. e. The ac input voltage is applied to the diagonally opposite ends of the bridge. The load resistance is connected between the other two ends of the bridge. For the positive half cycle of the input ac voltage, diodes D1 and D3 conduct, wherea whereass diodes diodes D2 and D4 remain remain in the the OFF state. state. The conduc conductin tingg diodes diodes will be in series with the load resistance RL and hence the load current flows through RL. For the negative half cycle of the input ac voltage, diodes D2 and D4 conduct whereas, D1 and D3 remain OFF. The conducting diodes D2 15

RCPIT, Shirpur

and D4 will be in series with the load resistance RL and hence the current flows flo ws throug through h RL in the same directi direction on as in the previo previous us half cycle. cycle. Th Thus us a bi-directional wave is converted into a unidirectional wave.

Figure 3.3: Bridge Rectifier

Filter Capa Ca paci citi tiv ve filte filterr is used used in this this projec project. t. It remo remov ves the the ripp ripple less from from the the output of rectifier and smoothens the D.C. Output received from this filter is constant constant until the mains voltage and load is maintained constant. constant. However, However, if  either of the two is varied, D.C. voltage received at this point changes. Therefore a regulator is applied at the output stage. Voltage regulator As the the na name me itself itself implies implies,, it regul regulate atess the the input input applied applied to it. A voltage oltage regulator is an electrical regulator designed to automatically maintain a constant stant voltag voltagee level. level. In this project, project, pow power er supply of 5V and 12V are required required.. In order to obtain these voltage levels, 7805 and 7812 voltage regulators are to 16

RCPIT, Shirpur

be used. The first number 78 represents positive supply and the numbers 05, 12 represent the required output voltage levels. The L78xx series of three-terminal positive regulators is available in TO-220, TO-220FP, TO-3, D2PAK and DPAK packages and several fixed output voltages, making it useful in a wide range of  applications. These regulators can provide local on-card regulation, eliminating the distributio distribution n problems problems associated associated with single point regulation regulation.. Each Each type type employs internal current limiting, thermal shut-down and safe area protection, making it essentially indestructible. If adequate heat sinking is provided, they can deliver over 1 A output current. Although designed primarily as fixed voltage regulators, these devices can be used with external components to obtain adjustable voltage and currents[8].

3.2 3.2

micr microco ocon ntrol trolle lers rs

Microproc Microprocesso essors rs and microcon microcontrol trollers lers are widely widely used in embedde embedded d systems systems produc products. ts. Microco Microcon ntrolle trollerr is a progr programm ammab able le devic device. e. A microco microcon ntrolle trollerr ha hass a CPU in addition to a fixed amount of RAM, ROM, I/O ports and a timer embedde embedded d all on a single single chip. chip. The fixed amount amount of on-chip on-chip ROM, RAM and number number of I/O ports in microcontrollers microcontrollers makes them ideal for many applications in which cost and space are critical. The Intel Intel 8052 8052 is Harvard Harvard archite architectur cture, e, single single chip chip microcon microcontrol troller ler which which wass develo wa developed ped by Intel Intel in 1980 1980 for for use in embed embedded ded systems systems.. It wa wass popu popular lar in the 1980s and early 1990s, but today it has largely been superseded by a vast range of enhanced devices with 8052-compatible processor cores that are manufactured by more than 20 independent manufacturers including Atmel, Infineon Technologies and Maxim Integrated Products. 8052 is an 8-bit processor, meaning that the CPU can work on only 8 bits of data at a time. time. Data Data larger larger than than 8 bits bits has to be b e brok broken en into into 8-bit 8-bit pieces pieces to be processed by the CPU. 8052 is available in different memory types such as UV-EPROM, Flash and NV-RAM. The present project is implemented on Keil Keil uVisio uVision. n. In order order to program program the device device,, prolo proload ad tool has been used to burn the program program onto the microcontrol microcontroller. ler. The features, features, pin descript description ion of  the microcontroller and the software tools used are discussed in the following sections. FEATURES R  Products •  Compatible with MCS-51 

17

RCPIT, Shirpur

Figure 3.4: Microcotroller

•  8K Bytes of In-System Programmable (ISP) Flash Memory •  Endurance: 1000 Write/Erase Cycles •  4.0V to 5.5V Operating Range •  Fully Static Operation: 0 Hz to 33 MHz •  Three-level Program Memory Lock •  256 x 8-bit Internal RAM •  32 Programmable I/O Lines •  Three 16-bit Timer/Counters •  Eight Interrupt Sources •  Full Duplex UART Serial Channel •  Low-power Idle and Power-down Modes •  Interrupt Recovery from Power-down Mode •  Watchdog Timer •  Dual Data Pointer •  Power-off Flag 18

RCPIT, Shirpur

3.3 3.3

desc descri ript ptio ion n

The AT89S52 is a low-power, high-performance CMOS 8-bit microcontroller with 8K bytes bytes of in-syste in-system m programm programmable able Flash memory. memory. The device is manufacture ufactured d using using Atmel’s Atmel’s high-de high-densit nsity y non nonvo volati latile le memory memory technol technology ogy and is compatible with the industry- standard 80C51 instruction set and pin out. The on-chip Flash allows the program memory to be reprogrammed in-system or by a conventional conventional nonvolatile nonvolatile memory programmer. By combining a versatile 8-bit CPU with in-system programmable Flash on a monolithic chip, the Atmel AT89S52 is a powerful microcontroller which provides a highly-flexible and cost-effe cost-effectiv ctivee solution solution to many many embedde embedded d control control app applica lication tions. s. The AT89S52 T89S52 provides the following standard features: 8K bytes of Flash, 256 bytes of RAM, 32 I/O lines, Watchdog timer, two data pointers, three 16-bit timer/counters, a six-vector two-level interrupt architecture, a full duplex serial port, on-chip oscillator, and clock circuitry. In addition, the AT89S52 is designed with static logic for operation down to zero frequency and supports two software selectable power pow er saving saving modes. The Idle Mode stops stops the CPU while allowing allowing the RAM, timer/counters, serial port, and interrupt system to continue functioning. The Power-down mode saves the RAM contents but freezes the oscillator, disabling all other chip functions until the next interrupt or hardware reset[1].

19

RCPIT, Shirpur

Pin Diagram

Figure 3.5: PIN Diagram

1. VCC Supply voltage. 2. GND Ground. 3.  Port 0 Port 0 is an 8-bit 8-bit open drain drain bidirect bidirection ional al I/O port. port. As an output output port, each each pin can sink eight TTL inputs. inputs. When When 1s are written written to port p ort 0 pins, pins, the pins can be used as high impedance inputs. Port 0 can also be configured to be the multiplexed low order address/data bus during accesses to external program and data memory. In this mode, P0 has internal pullups. Port 0 also receives the code bytes during Flash programming and outputs 20

RCPIT, Shirpur

the code bytes during program verification. External pullups are required during program verification. 4.  Port 1 Port 1 is an 8-bit Port 8-bit bidirect bidirectiona ionall I/O port with interna internall pullups. pullups. The Port 1 ou outpu tputt buff buffer erss can sink/so sink/sourc urcee four four TTL inpu inputs. ts. When When 1s are written written to Port 1 pins, they are pulled high by the internal pullups and can be used as inputs. As inputs, Port 1 pins that are externally being pulled low will source current (IIL) because of the internal pullups. In addition, P1.0 and P1.1 can be configured to be the timer/counter 2 external count input (P1.0/T2) and the timer/counter 2 trigger input (P1.1/T2EX), respectively tively,, as shown shown in the following following table. Po Port rt 1 also receives receives the low-order low-order address bytes during Flash programming and verification. 5.  Port 2 Port 2 is an 8-bit Port 8-bit bidirect bidirectiona ionall I/O port with interna internall pullups. pullups. The Port 2 ou outpu tputt buff buffer erss can sink/so sink/sourc urcee four four TTL inpu inputs. ts. When When 1s are written written to Port 2 pins, they are pulled high by the internal pullups and can be used used as input inputs. s. As inputs inputs,, Po Port rt 2 pins pins that that are are extern externall ally y being being pu pulle lled d low will source current (IIL) because of the internal pullups. Port 2 emits the high-order address byte during fetches from external program memory and during accesses to external data memory that use 16-bit addresses (MOVX @ DPTR). In this application, Port 2 uses strong internal pullups when emitting emitting 1s. During During accesses accesses to external external data memory that use 8-bit addresses (MOVX @ RI), Port 2 emits the contents of the P2 Special Function unction Register. Register. Po Port rt 2 also receive receivess the high-orde high-orderr add address ress bits and some control signals during Flash programming and verification[2]. 6.  Port 3 Port 3 is an 8-bit bidirectional I/O port with internal pullups. The Port 3 output output buffers buffers can sink/sour sink/source ce four TTL inputs. inputs. When 1s are written written to Port 3 pins, they are pulled high by the internal pullups and can be used as inputs. As inputs, Port 3 pins that are externally being pulled low will source source curren currentt (IIL) (IIL) because because of the the pu pullu llups. ps. Port 3 also also serv serves the the funcfunctions of various special features of the AT89S52, as shown in the following table. Port 3 also receives some control signals for Flash programming and verification. 21

RCPIT, Shirpur

7. RST Reset Reset input. input. A high high on this pin for two two machin machinee cycles cycles while while the osciloscillator lator is runni running ng reset resetss the the device device.. This This pin pin driv drives High High for 96 oscill oscillat ator or periods periods after after the Wat Watcchdo hdogg times times ou out. t. The DISRTO DISRTO bit in SFR AUXR (addr (address ess 8EH) can be used used to disable disable this featu feature. re. In the defau default lt state state of bit bit DISR DISRTO, TO, the RESET RESET HIGH HIGH ou outt featu feature re is enab enabled led.. ALE/P ALE/PRO ROG G Address Latch Enable (ALE) is an output pulse for latching the low byte of the the ad addre dress ss du durin ringg acces accesses ses to extern external al memory memory.. This This pin pin is also also the program program pulse input (PROG) (PROG) during during Flash Flash programm programming. ing. In normal normal operation, ALE is emitted at a constant rate of 1/6 the oscillator frequency and may be used for external timing or clocking purposes. Note, however, that one ALE pulse is skipped during each access to external data memory ory. If desired desired,, ALE operati operation on can be disab disabled led by setting setting bit 0 of SFR location 8EH. With the bit set, ALE is active only during a MOVX or MOVC instruction. Otherwise, the pin is weakly pulled high. Setting the ALE-disable bit has no effect if the microcontroller is in external execution mode. 8.   PSEN Program Store Enable (PSEN) is the read strobe to external program memory memory.. When When the AT89S5 T89S522 is execut executing ing code code from from exter external nal progr program am memory memory,, PSEN is activ activated ated twice twice each each machine machine cycle, except except that that two two PSEN activations are skipped during each access to external data memory. 9.   EA/VPP External Access Enable. EA must be strapped to GND in order to enable the device to fetch code from external program memory locations starting at 0000H up to FFFFH. Note, however, that if lock bit 1 is programmed, EA will be internally latched on reset. EA should be strapped to VCC for intern internal al program program executio executions. ns. This pin also receives receives the 12-volt 12-volt programprogramming enable voltage (VPP) during Flash programming. 10.  XTAL1 Input to the inverting oscillator amplifier and input to the internal clock operating circuit. 11.  XTAL2 22

RCPIT, Shirpur

Output Output from the inve invertin rtingg oscillat oscillator or amplifier. amplifier. XTAL1 XTAL1 and XTAL2 XTAL2 are the input and output, respectively, of an inverting amplifier that can be config configur ured ed for for use as an on-c on-chip oscilla oscillato tor, r, as shown shown in Figur Figure. e. Eithe Eitherr a quartz crystal or ceramic resonator may be used. To drive the device from an external clock source, XTAL2 should be left unconnected while XTAL1 is driv driven en,, as sho shown in the the belo below fig figur ure. e. Th Ther eree are are no requ requir irem emen ents ts on the duty cycle of the external clock signal, since the input to the internal clocking circuitry is through a divide-by-two flip-flop, but minimum and maximum voltage high and low time specifications must be observed[3].

23

Chapter 4 ARDUINO/GENUINO UNO Arduino/Genuino Uno is a microcontroller board based on the ATmega328P (data (datashe sheet et). ). It has 14 digital digital input/ input/ou outpu tputt pins pins (of which which 6 can can be used 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 cable or po powe werr it with with a AC-to AC-to-D -DC C ad adapt apter er or ba batte ttery ry to get starte started.. d.. You can tinker with your UNO without worring too much about doing something wrong, worst case scenario you can replace the chip for a few dollars and start over ver again. again. ”Uno” ”Uno” means one in Itali Italian an and wa wass chose chosen n to mark mark the the releas releasee of Arduin Arduinoo Soft Softwa ware re (IDE) 1.0. The Uno board board and versi version on 1.0 of Arduin Arduinoo Software (IDE) were the reference versions of Arduino, now evolved to newer releases. The Uno board is the first in a series of USB Arduino boards, and the reference model for the Arduino platform; for an extensive list of current, past or outdated boards see the Arduino index of boards. Arduino is an open-source platform used for building electronics projects. Arduino consists of both a physical programmable circuit board (often referred to as a microcontroller) and a piece of software, or IDE (Integrated Development Environment) that runs on your computer, used to write and upload computer code to the physica physicall board. board. The Arduino Arduino platform platform has become quite quite popul p opular ar with people just starting out with electronics, and for good reason. Unlike most previous programmable circuit boards, the Arduino does not need a separate piece of hardware (called a programmer) in order to load new code onto the board – you you can simply use a USB cable. cable. Addition Additionally ally,, the Arduino Arduino IDE uses a simpli simplified fied versio version n of C++, C++, making making it easie easierr to learn learn to progr program. am. Finall Finally y, Arduino provides a standard form factor that breaks out the functions of the micro-controller into a more accessible package 24

RCPIT, Shirpur

4.1

What What’’s on on the the boar board d?

There are many varieties of Arduino boards (explained on the next page) that can be used for different purposes. Some boards look a bit different from the one below, but most Arduinos have the majority of these components in common: Power (USB / Barrel Jack)

Figure 4.1: Arduino/Genuino UNO

Every Every Arduino Arduino board needs a way to be connect connected ed to a power source. source. The Arduino UNO can be powered from a USB cable coming from your computer or a wall power supply (like this) that is terminated in a barrel jack. In the picture above the USB connection is labeled (1) and the barrel jack is labeled (2). The USB connectio connection n is also ho how w you you will load code on onto to your Arduino Arduino board. More on how to program with Arduino can be found in our Installing and Programming ming Arduin Arduinoo tutor tutorial ial.. NOTE: NOTE: Do NOT use a pow power er suppl supply y great greater er than than 20 Volts as you you will overpow overpower er (and thereby thereby destro destroy) y) your your Arduino. Arduino. The recomrecommended voltage for most Arduino models is between 6 and 12 Volts[3].

Pins (5V, 3.3V, GND, Analog, Digital, PWM, AREF) The pins on your Arduino are the places where you connect wires to construct a circ circui uitt (pro (proba babl bly y in conj conjuc ucti tion on with with a brea breadbo dboar ard d an and d some some wire wire.. Th They ey usually have black plastic ‘headers’ that allow you to just plug a wire right into the board. board. The Arduino Arduino has severa severall differ differen entt kinds kinds of pins, pins, each each of whic which is labeled on the board and used for different functions. 25

RCPIT, Shirpur

•  GND (3): Short for ‘Ground’. There are several GND pins on the Arduino,

any of which can be used to ground your circuit. •   5V (4) & 3.3V 3.3V (5): (5): As you migh might gu gues ess, s, the the 5V pin suppli supplies es 5 volts olts of 

power, powe r, and the 3.3V pin suppli supplies es 3.3 volts olts of power. power. Most Most of the simple simple components used with the Arduino run happily off of 5 or 3.3 volts. •  Analog (6): The area of pins under the ‘Analog In’ label (A0 through A5

on the UNO) are Analog In pins. These pins can read the signal from an analog sensor (like a temperature sensor) and convert it into a digital value that we can read. •  Digital (7): Across from the analog pins are the digital pins (0 through 13

on the UNO). These pins can be used for both digital input (like telling if  a button is pushed) and digital output (like powering an LED). •  PWM (8): You may have noticed the tilde ( ) next to some of the digital

pins (3, 5, 6, 9, 10, and 11 on the UNO). These pins act as normal digital pins, but can also be used for something called Pulse-Width Modulation (PWM). We have a tutorial on PWM, but for now, think of these pins as being able to simulate analog output (like fading an LED in and out). •  AREF (9): Stands Stands for Analog Referenc Reference. e. Most of the time you can leave leave

this this pin alone. alone. It is someti sometimes mes used to set an extern external al refere referenc ncee voltage oltage (between 0 and 5 Volts) as the upper limit for the analog input pins.

Reset Button Just like the original Nintendo, the Arduino has a reset button (10). Pushing it will temporarily connect the reset pin to ground and restart any code that is loaded on the Arduino. This can be very useful if your code doesn’t repeat, but you want to test it multip multiple le times. times. Unlike Unlike the original original Nintend Nintendoo ho howe weve ver, r, blowing on the Arduino doesn’t usually fix any problems. Power LED Indicator Just beneath and to the right of the word “UNO” on your circuit board, ther there’ e’ss a tin tiny LE LED D next next to the the word ord ‘ON’ ‘ON’ (11) (11).. Th This is LE LED D shou should ld ligh lightt up whenever you plug your Arduino into a power source. If this light doesn’t turn on, there’s a good chance something is wrong. Time to re-check your circuit!

26

RCPIT, Shirpur

TX RX LEDs TX is short short for transm transmit, it, RX is short short for for receiv receive. e. These These markin markings gs ap appear pear quite a bit in electronics to indicate the pins responsible for serial communication. In our case, there are two places on the Arduino UNO where TX and RX appear – once by digital pins 0 and 1, and a second time next to the TX and RX indicator LEDs (12). These LEDs will give us some nice visual indications whenever our Arduino is receiving or transmitting data (like when we’re loading a new program onto the board). Main IC The black thing with all the metal legs is an IC, or Integrated Circuit (13). Think of it as the brains of our Arduino. The main IC on the Arduino is slightly different from board type to board type, but is usually from the ATmega line of IC’s from the ATMEL ATMEL company company.. This can be b e importan important, t, as you may need to know the IC type (along with your board type) before loading up a new program from the Arduino software. This information can usually be found in writing on the top side of the IC. If you want to know more about the difference between various IC’s, reading the datasheets is often a good idea[4]. Voltage Regulator The voltage regulator (14) is not actually something you can (or should) inte interac ractt with with on the Arduin Arduino. o. But it is poten potentially tially useful useful to know know that that it is there there and wha whatt it’s it’s for. for. The volta voltage ge regulat regulator or does exactl exactly y wha whatt it says says – it control controlss the amount amount of voltage voltage that is let into the Arduino Arduino board. board. Think Think of it as a kind of gatekeeper; it will turn away an extra voltage that might harm the circuit. Of course, it has its limits, so don’t hook up your Arduino to anything greater than 20 volts.

27

Chapter 5 THE ARDUINO FAMILY Arduin Arduinoo makes makes severa severall differe differen nt boards, boards, each each with with differ differen entt capab capabili ilitie ties. s. In addition, part of being open source hardware means that others can modify and produce derivatives of Arduino boards that provide even more form factors and functional functionalit ity y. If you’re you’re not sure which which one is right right for your project, chec check k this guide for some helpful hints. Here are a few options that are well-suited to someone new to the world of Arduino.

5.1

Ard Arduin uino Uno (R3 (R3)

The Uno is a great great choice choice for your first Arduino. Arduino. It’s got everythi everything ng you need to get started started,, and nothing nothing you don’t. don’t. It has 14 digital digital input/outpu input/outputt pins (of  which 6 can be used as PWM outputs), 6 analog inputs, a USB connection, a power jack, a reset button and more. 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.

Submersible Submersible pump A submersible pump (or sub pump, electric submersible pump (ESP)) is a device which has a hermetically sealed motor close-coupled to the pump body. The whole whole assemb assembly ly is submer submerged ged in the flu fluid id to be pumped. pumped. The main main advantage of this type of pump is that it prevents pump cavitation, a problem associated with a high elevation difference between pump and the fluid surface. Submersible pumps push fluid to the surface as opposed to jet pumps having to pull fluids. Submersibles are more efficient than jet pumps[5].

28

RCPIT, Shirpur

Figure 5.1: Arduino UNO(R3)

5.2

Featu eature ress

•  Compact, Easy to Install •  High Sealing Performance •  High Quality Hall Effect Sensor •  RoHS Compliant

5.3

Working orking with with Wate Waterr Flow Flow Sensor Sensorss & Arduin Arduino o

Effective water management involves supplying water according to the real requirement, and thus measuring water is very essential step in water management systems. There are many water flow measurement techniques as well as different types of water flow meters used to measure the volume of water flow in pipelin pipelines es bu butt these these all are too costly costly.. This This articl articlee descr describes ibes ideas ideas for desig design n and development of low cost automatic water flow meters, with the help of  readily-available and low-cost water flow sensors. Accurate flow measurement is an essential step both in the terms of qualitative and economic points of view. Flow meters have proven excellent devices for measuring water flow, and now it is very easy to build a water management system using the renowned water flow sensor YF-S201.This sensor sits in line 29

RCPIT, Shirpur

with the water line and contains a pinwheel sensor to measure how much water has move moved d through through it. There There is an integrate integrated d magnetic magnetic Hall-Effect Hall-Effect sensor that outputs outputs an electric electrical al pulse with every every revolutio revolution. n. The YFS201 Hall Effect Water Flow Sensor” comes with three wires: Red/VCC (5-24V DC Input), Black/G Black/GND ND (0V) and Yellow/OUT ellow/OUT (Pulse Output). Output). By counting counting the pulses pulses from the output of the sensor, we can easily calculate the water flow rate (in litre/hour – L/hr) using a suitable conversion formula[6].

Figure 5.2: Flow of Sensors

Level sensors detect the level of liquids and other fluids and fluidized solids, including slurries, granular materials, and powders that exhibit an upper free surface. Substances Substances that flow become essentially horizontal horizontal in their containers containers (or other other ph physi ysica call bou bound ndari aries) es) because because of gra gravity vity wherea whereass most most bulk bulk solids solids pile pile at an angle angle of repos reposee to a peak. peak. Th Thee subs substa tanc ncee to be meas measur ured ed can be insid insidee a contai container ner or can be in its natura naturall form form (e.g., (e.g., a river river or a lake). lake). The level level measurem measuremen entt can be either either contin continuou uouss or point point values. alues. Con Contin tinuou uouss level level sensors measure level within a specified range and determine the exact amount of substance in a certain place, while point-level sensors only indicate whether the substance substance is above above or below the sensing sensing point. point. Generall Generally y the latter latter detect detect levels that are excessively high or low. There are many physical and application variables that affect the selection of the optimal level monitoring method for industrial and commercial processes. The selection criteria include the physical: phase pha se (liquid (liquid,, solid solid or slurry), slurry), temperatu temperature, re, pressure pressure or vacuum, acuum, chemis chemistry try,, 30

RCPIT, Shirpur

dielectric constant of medium, density (specific gravity) of medium, agitation (action), acoustical or electrical noise, vibration, mechanical shock, tank or bin size and shape. Also important are the application constraints: price, accuracy, appearance, response rate, ease of calibration or programming, physical size and mounting of the instrument, monitoring or control of continuous or discrete (point) levels. In short, level sensors are one of the very important sensors and play play very very importan importantt role in variety ariety of consumer consumer// industri industrial al applicat applications ions.. As with other type of sensors, level sensors are available or can be designed using variety of sensing principles. Selection of an appropriate type of sensor suiting to the application requirement is very important.

5.4 5.4

How How to use the the Wat Water er Lev Level Sens Sensor or – Ardui Arduino no

This module is designed mainly for the DIY hobbyist and provide them a lowcost and easy-to-u easy-to-use se water level level detection detection scheme. scheme. The sensor that I will use for this tutorial can measure water level up to 40mm (4cm). This is an analog sensor and the data that we will read will be values from 0 to 1024. In this project, we will build a liquid level sensor circuit with an arduino. This circuit will be able to tell us roughly how much of the sensor is covered by liquid. liquid. Liquid Liquid level level sensors sensors are used for all types of application applications. s. They are extensively used within automobiles, which rely on a substantial amount of different fluids in order to operate to check for how much gas in the car, windshield washer wa sher fluid, oil levles. levles. Basicall Basically y, they are used whenever whenever we want want to measure measure the level level of an any y type type of fluid of a syste system. m. Th Thus, us, they are extrem extremely ely valua valuable ble to be ab able le to learn learn an and d manip manipula ulate te and build build circui circuits ts with. with. The liquid liquid level level sensor we will use is an analog sensor, meaning it outputs an analog voltage in proportio proportion n to the amount amount of liquid liquid the sensor sensor is exposed exposed to. We just connect connect the analog pin, represented by an S, to an analog pin on the arduino board to read the analog analog value value.. As you can see from from the the above above image, image, the sensor sensor has a series series of parallel parallel wires across across the board b oard.. These These wires are what sense the liquid liquid level level that the board is exposed exposed to. If the board board has wa water ter or anoth another er fluid covering all the wire, then it will output a maximum analog value reading. Since analog values read by an arduino range from 0 (lowest reading) to 1023 (highest reading), a board completely submerged with a liquid will have a reading of 1023 by an arduino. If the board is halfway covered, a reading of about 512 512 will will be read read by the ardui arduino. no. If the board board is 1/4 cov covered ered by a liquid liquid,, then then the ardu arduino ino will will read about about 256. And if no liquid liquid is on it at all, all, then then a near near 31

RCPIT, Shirpur

0 reading reading should be obtaine obtained[8 d[8]. ]. With our liquid level level sensor and an arduino, arduino, there are a number of options of what we can do. We can use the sensor, simply, to read and output the analog value obtained. Or we can create a type of alarm indicator status system. For example, we can have a green LED light up when the sensor is completely full (submerged to the top with fluid), indicating that it’s it’s full. full. We can have have a red red LED light light up when the sensor’ sensor’ss liquid liquid level level falls falls below 1/4 level, like how car dashboard LED indicators tell us when our gas tank goes belo b elow w E (empty (empty). ). So with a microcon microcontrol troller ler like the arduino, arduino, there are basically limitless options of how we can incorporate the liquid level sensor. In this circuit, we will build now, we will just do the most basic circuit and simply read and output the analog value read by the arduino.

Components Needed •   Arduino •  Liquid Level Sensor

The liquid level sensor we will use is built by China Harbin Okumatsu Robot Techn echnolo ology gy Co and its product product item is RB-02 RB-02S0 S048. 48. This This part part can easily easily be obtai ob taine ned d on ebay ebay for for most most of the time under under $2 includ including ing shippin shipping. g. It’s It’s very inexpensive. The sensor operates on 5V and needs less than 20mA for operating power current, which means the arduino can easily provide this (so no external power is needed to power it). The liquid level sensor has 3 pins. It’s very basic. The pinout is shown below[7]. 2 of the pins are for power, 1 connecting to the +5V of the arduino and the other other connecting connecting to the ground terminal terminal of the arduino. arduino. The other pin, with an S, is the signal pin. This is the pin that outputs the analog voltage signal in proportio proportion n to the amount amount of the sensor sensor which which is cove covered red with liquid. liquid. This pin connects to an analog pin on the arduino board to be read.

5.5 5.5

Adv Advan anta tage ge

•  Prevents Water Accumulation •  Reduces Soil Erosion •  Provide cleanliness in city

32

RCPIT, Shirpur

Figure 5.3: Connection with Arduino kit

5.6 5.6

Appl Applic icat atio ion n

•  It can be used in future smart city • It can useful for industries industries to monitor their drainage outlet toxicit toxicity y of fluid. •  Emergency flood control.

33

Chapter 6 CONCLUSION 6.1

Conc onclus lusion ion

Undergro Underground und maintenan maintenance ce is challe challengin ngingg problem problem.. Differen Differentt system system are proposed for the maintenance out of which some systems like manhole identification, underground drainage maintenance system and water distribution system are explained. This paper proposes different methods for monitoring and managing underground drainage system with different approaches. It explains various applications like Underground Drainage and Manhole Monitoring System, manhole identification and also for water distribution and monitoring system. In this study, the design of special purpose RFID tags, affixed with a metal surface, long distance reading, and reduces the interference characteristics of  water, wa ter, known as Ground Ground Tag. Also described Water Water WiSe an integr integrated ated platform combining a real-time wireless sensor network with intelligent analytics and modeling tools to better aid water distribution system operation and management with ANN model which is robust and can be used to predict the condition rating of water mains and ANN model is robust and can be used to predict the condition rating of water mains.

34

Bibliography [1] Allen Y. Chan Chang, g, Chan Chang-Su g-Sung ng Yu,Shengu,Sheng-Chi Chi Lin,YinLin,Yin-Yih Yih Chan Chang, g, pei-Chi pei-Chi Ho,” Search Search,, Ident Identifica ification tion and Po Positio sitioning ning of the Undergro Underground und Manhole Manhole with RFID”ISBN: 978-0-7695-3769-6 ,pp: 1899-1903 [2] http://www.thomasathomas.com/Metal detectors work.h tm [3] MandeepKaur, ManjeetSandhu, Neeraj Mohan and Parvinder S. Sandhu “ RFID Technology Principles, Advantages, Limitations & Its Applications” International Journal of Computer and Electrical Engineering, Vol.3, No.1, February, 2011 1793-8163 [4] Christoph Jechlitschek, “A survey paper on quency Identification (RFID) Trends”Available ˜ http://www1.cse.wustl.edu/ jain/cse574 jain/cse5 74- 06/index.html 06/index.html

Radio online

Freat:

[5] Joe Pu Purte rtell ll “Mapp “Mapping ing the Und Under ergro ground und infra infrastr struc uctur ture: e: Levera Leveragin gingg GPS Technology to locate and identify problems” North American Society for Trenchless Technology (NASTT) No-Dig Show 2010 Chicago, Illinois May 2-7, 2010 [6] [6] Mura Murage gesh sh SK an and d Sa San nthos thosha ha Rao Rao “Aut “Autom omat ated ed Inte Intern rnet et of Th Thin ings gs for for Under Und ergro ground und Draina Drainage ge an and d Manho Manhole le Monit Monitori oring ng Syste System m for for Metropo Metropolilitan tan Cities Cities”” Inte Interna rnatio tional nal Journa Journall of Inform Informat ation ion & Compu Computa tatio tion n Techechnolog no logy y. ISSN ISSN 09740974-223 22399 Volume4 olume4,, Number1 Number122 (2014 (2014), ), pp pp.12 .1211 11-- 1220 1220 at http://www.Irphouse.com [7] [7] Whit Whittl tle, e, A. J., J., M. Alle Allen, n, A. Prei Preis, s, an and d M. Iqba Iqbal. l. ”S ”Sen enso sorr Net Networks orks for for Monitoring and Control of Water Distribution Systems.” 6th International Conferen Conference ce on Structur Structural al Health Health Monitori Monitoring ng of Intell Intelligen igentt Infrastr Infrastructu ucture re (SHMII 2013), Hong Kong, December 9-11, 2013 [8] R. R. Dighade, M. S. Kadu, A.M.Pande International Journal of Innovative Research in Science, Engineering and Technology (An ISO 3297) 35

View more...

Comments

Copyright ©2017 KUPDF Inc.
SUPPORT KUPDF