Automated Guided Vehicle Using Line Following Detection.

(1)

AUTOMATED GUIDED VEHICLE USING LINE FOLLOWING DETECTION

MOHD KHAIRULZAMAN BIN A RAHMAN

This report is submitted in partial fulfillment of the requirements for the award of Bachelor of Electronic Engineering ( Industrial Electronics ) With Honours.

Faculty of Electronic and Computer Engineering Universiti Teknikal Malaysia Melaka


(2)

ii

UNIVERSTI TEKNIKAL MALAYSIA MELAKA

FAKULTI KEJURUTERAAN ELEKTRONIK DAN KEJURUTERAAN KOMPUTER BORANG PENGESAHAN STATUS LAPORAN

PROJEK SARJANA MUDA II

Tajuk Projek : AUTOMATED GUIDED VEHICLE USING LINE FOLLOWING DETECTION

Sesi

Pengajian : 2008/2009

Saya MOHD KHAIRULZAMAN BIN A RAHMAN . (HURUF BESAR)

mengaku membenarkan Laporan Projek Sarjana Muda ini disimpan di Perpustakaan dengan syarat-syarat kegunaan seperti berikut:

1. Laporan adalah hakmilik Universiti Teknikal Malaysia Melaka.

2. Perpustakaan dibenarkan membuat salinan untuk tujuan pengajian sahaja.

3. Perpustakaan dibenarkan membuat salinan laporan ini sebagai bahan pertukaran antara institusi pengajian tinggi.

4. Sila tandakan ( ) :

SULIT*

(Mengandungi maklumat yang berdarjah keselamatan atau kepentingan Malaysia seperti yang termaktub di dalam AKTA RAHSIA RASMI 1972)

TERHAD* (Mengandungi maklumat terhad yang telah ditentukan oleh organisasi/badan di mana penyelidikan dijalankan)

TIDAK TERHAD

Disahkan oleh:

__________________________ ___________________________________

(TANDATANGAN PENULIS) (COP DAN TANDATANGAN PENYELIA)

Alamat Tetap: 164 JALAN JELUTONG FELDA BUKIT TONGKAT 86000 KLUANG JOHOR


(3)

“I hereby declare that this report is the result of my own work expect for quotes as cited in the references.”

Signature :...

Author :MOHD KHAIRULZAMAN BIN A RAHMAN Date :...


(4)

iv

“I hereby declare that I have read this report and in my opinion this report is sufficient in terms of the scope and quality for the award of Bachelor of Electronic Engineering

( Industrial Electronics ) With Honours.”

Signature :...

Supervisor‟s Name :PN NORIHAN ABDUL HAMID


(5)

v

Dedicated to my beloved family especially my mother and father and also to my friends.


(6)

vi

ACKNOWLEDGEMENTS

First of all I want to thank God because blesses me with strength and will to finish this project until the very end so I can finish my project. I want to say thank you to my supervisor, Puan Norihan Abdul Hamid that has contribute much in my project. Thank you for supporting me in material, ideas and suggestion. Thank you to all of my friends that always supporting me, understand the pressure and helping me finish my project. To my dad and mom also my family, they always support me and given me an advise when I need it most. And lastly to anybody who contribute in these project lecturers, persons and everyone involve direct or indirectly in this project. Thank you.


(7)

vii

ABSTRACT

The aim of this project is to develop an Automated Guided Vehicle (AGV) using line following detection. AGV is an automatically controlled vehicle that is often used in material transportation in an automated production line or in an automatic storage and retrieval system. This typical project consist of the hardware (the vehicle consist of mechanical device) while controlled by electronics part and some algorithm. It will also need to complete the process of technical survey, design, analysis, parts machining, assembly as well as testing and refinement of an AGV. The AGV is driven by a servo motor, guided by sensors and position controlled by an array of three Infra Red sensors and controller by PIC16F877A.This project is develop from the problem of the stored and production line system, time taken and human energy. The main objective of this project is to overcome this problem by develop an automated guided vehicle using line following detection. For this project, the motor is powered using L293D IC with power source about 4.8V for this project. For the motor part will classified as left and right motor. For sensor part, we will be using three pairs of IR sensors which will be attached to the bottom of the robot. These 3 sensors will be classified as left sensor, middle sensor and right sensor.


(8)

viii

ABSTRAK

Projek ini bertujuan untuk merekabentuk kenderaan automatik menggunakan kaedah pengesanan melalui garisan. Projek ini kebanyakkan digunakan didalam sistem penghantaran barang-barang secara automatik pada laluan penghasilan, sistem penyimpanan dan pengambilan semula. Projek ini terdiri daripada penghasilan perkakasan yang dikawal oleh bahagian elektronik dan algoritma. Penghasilan projek ini melalui beberapa langkah seperti pencarian maklumat teknikal, merekabentuk dan menganalisis bahagian mekanikal serta elektronik, menguji dan menyelesaikan masalah pada bahagian mekanikal dan elektronik. Kenderaan automatik ini digerakkan oleh motor servo, dikawal dan ditentukan arah melalui pengesanan oleh susunan sensor inframerah dan dikawal menggunakan PIC16F877A. Penghasilan projek ini disebabkan oleh masalah yang berlaku pada sistem penghantaran barang-barang dan penyimpanan serta pengambilan semula. Tujuan utama penghasilan projek ini adalah untuk menyelesaikan masalah tersebut melalui penghasilan kenderaan automatik menggunakan kaedah pengesanan garisan. Projek ini akan menggunakan IC L293D untuk mengawal motor servo dengan bekalan kuasa sebanyak 4.8 Voltan dan dibahagikan kepada 2 bahagian iaitu motor kanan dan kiri. Pada bahagian sensor terdiri daripada tiga pasang inframerah yang dikawal oleh litar pembanding yang bersambung dengan pusat kawalan utama iaitu PIC16F877A.


(9)

ix

CONTENTS

CHAPTER TOPIC PAGE

PROJECT TITLE i

REPORT STATUS CERTIFICATION ii

DECLARATION iii

SUPERVISOR CERTIFICATION iv

DEDICATION v

ACKNOWLEDGEMENTS vi

ABSTRACT vii

ABSTRAK viii

CONTENTS ix

LIST OF TABLE xiv

LIST OF FIGURE xv


(10)

x

I INTRODUCTION

1.1 Overview 1

1.2 Objectives 3

1.3 Problem Statement 3

1.4 Overview Of Project Methodology 4

II LITERATURE REVIEW

2.1 Overview 5

2.2 Example Of The Line Following Robot 8

2.2.1 Sandwich 8

2.2.1.1 Method Used By Sandwich 9

2.2.2 Desktop Line Following Robot 10

2.2.2.1 Method Used By Desktop

Line Following Robot 11

2.2.3 Line Following Van 13

2.2.3.1 Method Used By Line Following 13

Van

2.3 Devices And Components 16


(11)

xi 2.3.1.1 Servo Motor Control 16

2.3.2 Infrared Sensor 19

2.3.3 Microcontroller 20

2.3.3.1 PIC16F877A 21

2.3.4 Comparator LM324 24

2.3.4.1 Unique Characteristics 24

2.3.4.2 Advantages 25

2.3.5 Motor Driver L293d 25

III PROJECT METHODOLOGY

3.1 Introduction 26

3.2 Circuits 31

3.2.1 Infrared Sensor Circuit 31

3.2.2 Motor Driver Circuit 33

3.2.3 Microcontroller Circuit 34

3.3 Components Selection 35

3.3.1 Capacitor 35

3.3.2 Infrared 37


(12)

xii

3.3.4 Microcontroller PIC16F877A 38

3.3.5 Voltage Regulator LM7805 41

3.4 Software 42

3.4.1 Eagle Software 43

3.5 Programming Develop Software 45

3.5.1 MPLAB IDE 45

3.6 Circuits Installation 46

3.6.1 Preparing the Components 46

3.6.2 Testing the Components 47

3.6.3 Making the Printed Circuit Board 48

3.6.4 Components Installation into 49

Printed Circuit Board

IV RESULT AND DISCUSSION

4.1 Introduction 50

4.2 Result Analysis 50

4.2.1 Infrared Sensor Circuit 51 4.2.2 Sensor Detection And Response 53


(13)

xiii

4.2.2.1 Robot Movement 55

4.2.3 Coordinating the Motor and Sensor 57

4.2.4 Robot on Track 58

4.2.5 Layout of The Chassis Mobile Robot 59

4.3 DISCUSSION 62

V CONCLUSION AND RECOMMENDATION

5.1 CONCLUSION 63

5.2 Problem Statement 64

5.3 Recommendation 64

5.4 Future Improvement 65

REFERENCE 66


(14)

LIST OF TABLE

NO TITLE PAGE

2.1 Features of Atmel ATmega8 for Desktop Line Following Robot 11 2.2 Summary of the comparison of Stepper Motors and Servomotors 17

3.1 Component List For Line Following Robot 47

4.1 Sensor Detection And Response 54

4.2 Combination Of The Wheels To Move The Robot In The 57 Desired Direction


(15)

xv

LIST OF FIGURE

NO TITLE PAGE

1.1 Block Diagram Of Line Following Mobile Robot 2

2.1 Application of Mobile Robot 7

2.2 Model of Sandwich Line Following Robot 9

2.3 White LED as a Headlight Between Cadmium-sulfide Photoresistors 9 2.4 Bottom View and Side View of the Desktop Line Following Robot 10 2.5 Output Current and LED Current and Ambient Light 12

2.6 H-Bridge for Turning Motor 14

2.7 Schematic of the Photo-Transistor Sensor Circuit 15

2.8 Connection and operation servomotor 18

2.9 Basic Prinsiple of IR Sensor 20


(16)

xvi

2.11 L293D IC 25

3.1 Flow Chart of the Project Methodology 27

3.2 Sensor Placement View from Top Of The Robot 29

3.3 Distance between Two Sensors 30

3.4 Infrared Sensor Circuit 30

3.5 Motor Driver Circuit 31

3.6 Microcontroller Circuit with PIC16F877A 32

3.7 Type Of Capacitor 34

3.8 Symbol of the Capacitor 34

3.9 Infrared Sensor 35

3.10 Symbol Of Diode 36

3.11 Picture of PIC 16F877A 37

3.12 Pin Assignment For LM7805 39

3.13 Block Diagram of Voltage Regulator 40

3.14 Medium Used to Make The Schematic Circuit 43

3.15 Medium Used to Make The PCB Layout and Example of PCB Layout 44

3.16 Method for Programming PIC 45

3.17 Window interface in MPLAB IDE For Making Source Code. 46

3.18 InfraRed Sensor Circuit Testing 48


(17)

xvii 3.20 Components Installation into Printed Circuit Board 49

4.1 The Infrared Sensor Circuit. 51

4.2 Sensor Placement View from Top Of The Robot 52

4.3 Circuit Simulation On Breadboard Without Power Supply 52 4.4 Circuit Simulation On Breadboard With Power Supply 53

4.5 All Sensor Detect The Black Line 55

4.6 Centre Sensor Detect the Line 55

4.7 Right Sensor Detect the Line 56

4.8 Left Sensor Detect the Line 56

4.9 The Line Following Robot at Line Following Track 58

4.10 Chassis of the Mobile Robot from Top View 59

4.11 Top View of Line Following Robot 60

4.12 Bottom View of Line Following Robot 60

4.13 Side View of Line Following Robot 61


(18)

xviii

LIST OF APPENDIX

NO TITLE PAGE

A Datasheet L293D 67

B Datasheet LM324 72

C Datasheet PIC16F87XA 77

D Source Code of Line Following Robot 83


(19)

CHAPTER I

INTRODUCTION

1.1 Overview

In our life, some problem occurs on material transportation, storage and retrieval system. This is because we don‟t have automated system in our factory or our house, so we have to create an automated line system that can make our life more easily. For storing system, we can make the easy way to store the item using line mobile robot. Nowadays some factory used human power to store their item or component at warehouse. For production line system, usually we have used human power to place some component on tray at production line. After that, we can reduce our time for store the item or object. That because in factory, worker still needs to fine the empty place to put their item. It will take more time to find the empty place. By using line mobile robot, we just need to put the thing on that robot then the mobile robot will automatically move to the empty place that we can put our item


(20)

2 Some example in production line, the operator need manually take some component or semi-product at pick-up place when at their point is empty. It will take more time to move from their point to the pick-up place and can reduce the outputs. To solve this problem we have use automated line mobile robot system, where the operator only need to pressed some button then the line mobile robot will reach at their point with the component.

This project is to making the automated guided vehicle (AGV) using line following detection. This AGV usually used in material transportation in an automated production line or in an automatic storage and retrieval system. This typical project consist of the hardware (the vehicle consist of mechanical device) while controlled by electronics part and some algorithm. For this project, we used the PIC to integrated the sensor and the motor as shown in figure 1.1


(21)

3 1.2 Objectives

The objectives of this project are:

I. To design and implement the automated guided vehicle using line following detection.

II. To learn PIC programming and how to implement it on the hardware installation.

III. To understand the concept of electrical DC motor system and sensor for detect the line.

IV. To construct and design the wiring system and connectivity and also the mechanical part.

1.3 Problem Statement

As we know, there are many method used for transportation in production and storage system in factory. Some factory used manual method whereby the used human to complete task in their storage system. For example in storage system and production line usually we have used human power to carry some component at production line. This will need more time, more consumption reduce the outputs.

For storage and retrieval system, we also need to used more human energy to carry the an item. By using the mobile robot system, we used less human power for our storage and retrieval system. It is because the worker no needs to carry heavy store item, but only carry and put at the mobile robot and mobile robot will automatically move to the empty place.


(22)

4 1.4 Overview Of Project Methodology

Basically, the scope of this project will divided to 3 levels. The level are beginning level intermediate level and finishing level. At all level we have do certain work like Choosing the project title, searching for literature review and analyze the project scope, designing the model and the PIC programming, PIC simulation, listing the parts and components for the model, building the model, building the connection between the PIC and the sensor and motor circuit, trouble-shooting and data analysis


(23)

CHAPTER II

LITERATURE REVIEW

This chapter discusses about the background research and concept of the project and will explain further of the project‟s perspective and methods used in research.

2.1 Overview

Nowadays, many method used to line following detection. For example using phototransistors, IR sensor or ultrasonic sensor. Each method have their own advantages and disadvantages.

The mobile robot also can determine by their system like autonomous or automated system. Autonomous robots are robots which can perform desired tasks in unstructured environments without continuous human guidance. Many kinds of


(24)

6 robots have some degree of autonomy. Different robots can be autonomous in different ways. A high degree of autonomy is particularly desirable in fields such as space exploration, cleaning floors, mowing lawns, and waste water treatment.

One important area of robotics research is to enable the robot to cope with its environment whether this is on land, underwater, in the air, underground, or in space. A fully autonomous robot has the ability to

I. Gain information about the environment.

II. Work for an extended period without human intervention.

III. Move either all or part of itself throughout its operating environment without human assistance.

IV. Avoid situations that are harmful to people, property, or itself unless those are part of its design specifications.

An autonomous robot may also learn or gain new capabilities like adjusting strategies for accomplishing its task or adapting to changing surroundings. Autonomous robots still require regular maintenance, as do other machines [3].

Beside that line follower is a machine that can follow a path. The path can be visible like a black line on a white surface (or vice-versa) or it can be invisible like a magnetic field [2].

For example from William Dubel say [1] a common task for a robot is to follow a predetermined path. One popular way to mark a path is with a high contrast line, such as black electrical tape on a light colored surface. When deciding on the type of line to create, consider the type of sensor that will detect it, as well as how easy it is to apply. In describing reliable line tracking, most of the work is in the sensor arrangement and programming.


(1)

CHAPTER I

INTRODUCTION

1.1 Overview

In our life, some problem occurs on material transportation, storage and

retrieval system. This is because we don‟t have automated system in our factory or

our house, so we have to create an automated line system that can make our life more easily. For storing system, we can make the easy way to store the item using line mobile robot. Nowadays some factory used human power to store their item or component at warehouse. For production line system, usually we have used human power to place some component on tray at production line. After that, we can reduce our time for store the item or object. That because in factory, worker still needs to fine the empty place to put their item. It will take more time to find the empty place. By using line mobile robot, we just need to put the thing on that robot then the mobile robot will automatically move to the empty place that we can put our item


(2)

2 Some example in production line, the operator need manually take some component or semi-product at pick-up place when at their point is empty. It will take more time to move from their point to the pick-up place and can reduce the outputs. To solve this problem we have use automated line mobile robot system, where the operator only need to pressed some button then the line mobile robot will reach at their point with the component.

This project is to making the automated guided vehicle (AGV) using line following detection. This AGV usually used in material transportation in an automated production line or in an automatic storage and retrieval system. This typical project consist of the hardware (the vehicle consist of mechanical device) while controlled by electronics part and some algorithm. For this project, we used the PIC to integrated the sensor and the motor as shown in figure 1.1


(3)

1.2 Objectives

The objectives of this project are:

I. To design and implement the automated guided vehicle using line following detection.

II. To learn PIC programming and how to implement it on the hardware installation.

III. To understand the concept of electrical DC motor system and sensor for detect the line.

IV. To construct and design the wiring system and connectivity and also the mechanical part.

1.3 Problem Statement

As we know, there are many method used for transportation in production and storage system in factory. Some factory used manual method whereby the used human to complete task in their storage system. For example in storage system and production line usually we have used human power to carry some component at production line. This will need more time, more consumption reduce the outputs.

For storage and retrieval system, we also need to used more human energy to carry the an item. By using the mobile robot system, we used less human power for our storage and retrieval system. It is because the worker no needs to carry heavy store item, but only carry and put at the mobile robot and mobile robot will automatically move to the empty place.


(4)

4 1.4 Overview Of Project Methodology

Basically, the scope of this project will divided to 3 levels. The level are beginning level intermediate level and finishing level. At all level we have do certain work like Choosing the project title, searching for literature review and analyze the project scope, designing the model and the PIC programming, PIC simulation, listing the parts and components for the model, building the model, building the connection between the PIC and the sensor and motor circuit, trouble-shooting and data analysis


(5)

CHAPTER II

LITERATURE REVIEW

This chapter discusses about the background research and concept of the

project and will explain further of the project‟s perspective and methods used in

research.

2.1 Overview

Nowadays, many method used to line following detection. For example using phototransistors, IR sensor or ultrasonic sensor. Each method have their own advantages and disadvantages.

The mobile robot also can determine by their system like autonomous or automated system. Autonomous robots are robots which can perform desired tasks in unstructured environments without continuous human guidance. Many kinds of


(6)

6 robots have some degree of autonomy. Different robots can be autonomous in different ways. A high degree of autonomy is particularly desirable in fields such as space exploration, cleaning floors, mowing lawns, and waste water treatment.

One important area of robotics research is to enable the robot to cope with its environment whether this is on land, underwater, in the air, underground, or in space. A fully autonomous robot has the ability to

I. Gain information about the environment.

II. Work for an extended period without human intervention.

III. Move either all or part of itself throughout its operating environment without human assistance.

IV. Avoid situations that are harmful to people, property, or itself unless those are part of its design specifications.

An autonomous robot may also learn or gain new capabilities like adjusting strategies for accomplishing its task or adapting to changing surroundings. Autonomous robots still require regular maintenance, as do other machines [3].

Beside that line follower is a machine that can follow a path. The path can be visible like a black line on a white surface (or vice-versa) or it can be invisible like a magnetic field [2].

For example from William Dubel say [1] a common task for a robot is to follow a predetermined path. One popular way to mark a path is with a high contrast line, such as black electrical tape on a light colored surface. When deciding on the type of line to create, consider the type of sensor that will detect it, as well as how easy it is to apply. In describing reliable line tracking, most of the work is in the sensor arrangement and programming.