"I acknowledge indeed that I have read this report and on my opinion this report is sufficient from scope and quality for requirements for the Bachelor The Degree of Electronic Engineering (Industrial Electronic) " Signature Author Date : 28 February 2005
WALL FOLLOWING MOBILE ROBOT ROSLINAMARIA BINTI HJ ABDUL RAHMAN This Report Is Submitted In Partial Fulfilment Of Requirements For The Bachelor The Degree Of Electronic Engineering (Industrial Electronic) Fakulti Kejuruteraan Elektronik dan Kejuruteraan Komputer Kolej Universiti Tek:nikal Kebangsaan Malaysia March 2005
u "I hereby declare that this report authored by me except for the summary and excerpt in which I have clarify the sources " Signature Author Date ~ : Roslinamaria binti Hj Abdul Rahman : 28 February 2005
ll1 To my late father Hj Abdul Rahman bin Roslan, My mum, Hjh. Rosnah binti Bakrin, My brother and family, Rosely bin Hj. Abdul Rahman, My sister and family, Roslinawati binti Hj. Abdul Rahman and My love Mohamad Zaihan bin Borhan
IV APPRECIATION Nobody gets anywhere without help from many different people along the way. I am no exception to this. I would like to take this opportunity to thank my family especially to my late father Hj Abdul Rahman bin Roslan (28 November 2004, 15 Syawa/1425) who been my inspiration, my mother Hjh. Rosnah binti Bakrin to be supportive women, my fiancee Mohamad Zaihan Borhan to encourage me. I would like to thank Mr. Soo Yew Guan for all his support. He was able to use the right words that sparked the wall following mobile robot inside me. He has been, and he always is my adviser in this project. I would like to thank to all my friends that has been very helpful in providing information and support.
v ABSTRACT Robot is a machine that works automatically and can do some ~ that human can do. Mobile robot is especially design to operate in environment such as automated assembly halls, factories or warehouse. Mobile robot an intelligent machine that developed to think and function according to the instruction. In this project, a wall-following mobile robot has been designed. The wall-following control problem is characterized by moving the robot along a wall in a desired direction while maintaining a constant distance to the wall. There are several reasons why autonomous mobile robots must be able to follow walls or in a more general sense, to follow the contours of an object. This depends of course on the type of mobile robot and its application. Robots operating in an unknown, unstructured environment (usually outdoors) use their sensors to perceive the surrounding and replan their motions or trajectories accordingly. (Perspective information is very important in unstructured environment and for vision system. Random navigation does not seem like a very elegant way to master a wall so the choice is wallfollowing mobile robot).
Vl ABSTRAK Robot adalah satu mesin dimana ia boleh berketja secara automatik dan boleh melakukan tugas yang mana manusia boleh lakukan dimana keistimewaan robot direkabentuk dengan atau mengikuti suasana seperti mengautomasikan pemasangan ruang depan, k:ilang atau gudang. Robot mudah alih adalah mesin yang bijak yang dibangunkan untuk berftkir dan berfungsi mengikut arahan. Di dalam projek ini, robot mudah alih mengikut dinding telah dicipta. Masalah pergerakan mengikut dinding boleh disifatkan sebagai robot yang bergerak menyusuri dinding mengikut kehendak arahan serta mengawal jarak dengan dinding. Terdapat pelbagai sebab mengapa robot ini dicipta. Ini bergantung kepada jenis dan aplikasinya. Robot beroperasi di dalam suasana tidak diketahui menggunakan sensor untuk mencapai maklumat keadaan sekeliling. (Perspektif informasi adalah amat penting di dalam suasana yang tidak distrukturkan dan untu.k sistem penglihatan. Pergerakan secara rambang tidak beberapa kelihatan menarik untuk menguasai dinding maka pilihan yang baik ialah wall-following mobile robot. Cara yang paling mudah untuk menjelaskan penciptaan projek ini ialah dengan membayangkan manusia betjalan dengan keadaan mata yang tertutup ataupun buta. Dengan meletakkan sebelah tangan kepada dinding dan terus menyusuri dinding tersebut hingga mencapai arab tuju.
VII CONTENT CHAPTER TITLE. PAGE Project Title Declaration Dedication Appreciation Abstract (English Version) Abstract (Malay Version) u ill IV v VI List of Content List of Figure List of Table List of Appendix List of Short forms VII X Xll Xll1 XlV Chapter 1 1.0 1.1 1.2 Introduction Project Objectives and Scope of Work Problem Statements 1 3 5
Vlll Chapter 2 2.0 Literature Review 6 Chapter 3 3.0 3.1 3.2 3.3 3.4 3.5 3.6 Project Methodology and Data Analysis 12 The infrared (IR) Sensors Transmitter and Receiver 13 Low Power Dual Voltage Regulator (LM393) 16 The PIC16F84A Brain 18 The Motor Drive Circuit 20 Making Prototype 22 Direct Current (DC) Motor 23 Chapter4 4.0 4.1 4.2 4.3 Project Finding 25 Program PIC16F84A for Wall Following Mobile Robot 32 Circuit Description 35 Robot Power Supplies 37 Chapter 5 5.0 5.1 5.2 5.3 Conclusion 38 Application 39 Improvements and Suggestion 40 Summary 41
lx Reference 42 Appendix A AppendixB Appendix C 43 51 58
X LIST OF FIGURE NO TITLE. PAGE 1.1 Flow Chart Scope of Work 4 2.1 DR X Prototype 7 2.2 The Robot Approaches The Doorway 8 2.3 The robot passes the doorway 8 2.4 The robot turns left 90 degrees 9 2.5 The robot moves forward into the doorway 9 2.6 The robot is almost through the doorway 9 2.7 The robot is through the doorway 10 2.8 DR X Robot 10 3.1 Schematic for Infrared Sensor (Transmitter) 13 3.2 Infrared Set-up 14 3.3 Schematic for Infrared Sensor (Receiver) 15 3.4 Block Diagram Infrared Sensor Circuit 15 3.5 PIC 16F84A Pin Configuration 17 3.6 Equivalent Circuit 17 3.7 Circuit Diagram for PIC 16F84A 18 3.8 Pin Diagram for PIC16F84A 18 3.9 Twin Motor Drive Circuit 20 3.10 Permanent-magnet DC Motor Operation 23 4.1 Prototype Wall Following Mobile Robot 25 4.2 Voltage versus Length 26 4.3 Timing Diagram for The Ideal IR Receiver Good IR Signal 27 4.4 Good IR Signal 28 4.5 Weakness IR Signal 29
XI 4.6 Block Diagram from IR Receiver 30 4.7 IR Sensor Triggered PIC 31 4.8 Flow Charts for Programming 32 4.9 Circuit for Wall Following MobiJe Robot 36 4.10 Voltage Regulator Circuit 37
xu LIST OF TABLE NO TITLE PAGE 3.1 Motor Action Contro1 21
XIII LIST OF APPENDIX NO TITLE PAGE A Wall-following Control for Two-Wheeled Mobile Robot, Proceeding of the IEEE, International Conference on Robotics and Automation, Hochiminh City, Vietnam May 2002 43 B c Wall-following Control of a Mobile Robot, Proceeding of the 1992 IEEE, International Conference on Robotics and Automation, Nice, France May 1992 51 Wall-following using angle information measured by a single ultrasonic Transducer, Proceeding of the 1998 IEEE, International Conference on Robotics and Automation, Leuren Belgium, May 1998 58
XIV LIST OF SHORT FORMS PIC IR LED k m Hz PC v Amp Op-amp n J.l. AID DC AC 110 KUTKM EEPROM TIL CMOS Programmable Integrated Circuit Infrared Light Emitter Diode kilo mili Hertz Printed circuit Volts Ampere Operational Amplifier ohm DllCro Analog to Digital Direct current Alternate current Input I Output Kolej Universiti Tek:nikal Kebangsaan Malaysia Electronic Erasable Programmable Read of Memory Transistor-transistor Logic Complementary Metal-Oxide Semiconductor
1 CHAPTER I INTRODUCTION For this surveillance robot, the main purpose is only to stroll follows the wall, in order to detect intruders, using reflects an Infrared (IR) or movement following behavior. It is not desired to have the robot following waljs too closely or having all the space covered, since the main purpose is just to look around for motion or Infrared sources, keeping as far as possible from all walls. The robot keeps itself faraway from walls by having the capability of adapting its behaviors, in order to be able to enter and explore narrow spaces and to adapt easily to differently reflective environments. In surveillance robots, result expected is to get an overall behavior, which permits an efficient coverage and exploration of the entire space where it should wander about, without the problems of getting indefinitely stuck in particular confusing situations that may occur seldom. Wall-following mobile robot is a small three-wheel robot that follows the walls, which it senses with its active infrared sensors. Each rear wheel has its own motor where the single front wheel is not powered. The robot steers like a tank by rotating the rear wheels in opposite direction. The sensors are built with infrared LED's, which are running at 36kHz and two 36kHz remote control receiver modules. When an object reflects the 36kHz IR lights from the LEDs, one of the receiver modules will be triggered, and the
CHAPTER I INTRODUCTION For this surveillance robot, the main purpose is only to stroll follows the wall, in order to detect intruders, using reflects an Infrared (IR) or movement following behavior. It is not desired to have the robot following walls too closely or having all the space covered, since the main purpose is just to look around for motion or Infrared sources, keeping as far as possible from all walls. The robot keeps itself faraway from walls by having the capability of adapting its behaviors, in order to be able to enter and explore narrow spaces and to adapt easily to differently reflective environments. In surveillance robots, result expected is to get an overall behavior, which permits an efficient coverage and exploration of the entire space where it should wander about, without the problems of getting indefmitely stuck in particular confusing situations that may occur seldom. Wall-following mobile robot is a small three-wheel robot that follows the walls, which it senses with its active infrared sensors. Each rear wheel has its own motor where the single front wheel is not powered. The robot steers like a tank by rotating the rear wheels in opposite direction. The sensors are built with infrared LED's, which are running at 36kHz and two 36kHz remote control receiver modules. When an object reflects the 36kHz IR lights from the LEDs, one of the receiver modules will be triggered, and the
2 PIC16F84A micro controller will steer the robot by reversing one of the motors and turn to the right if the front sensor detect. If left front sensor robot will go forward
3 1.1 Project Objectives And Scope Of Work The objectives of the robot are to study and investigate the ranging sensor and the integration technique using IR sensor for the wall-following mobile robot and to implement about simple wall-following algorithm then after implement simple wallfollowing algorithm, designing on wall-follov.ring mobile robot on micro controller PIC Basic. The progress to design wall-following mobile robot it is divide to three major processes and there are designing on micro controller, design the circuit and lastly develop the platform to produce the prototype of wall-following mobile robot. Firstly the process is design micro controller referred to the planning of movement the wall-following mobile robot after design the micro controller then the. simple algorithm will implement to the micro controller using PIC Basic by assembler language. The next process is designing on the circuitry of the robot. In this process there are get on develop the prototype of the robot, which is from designing on circuitry, and develop the platform. On designing the circuit for wall following after design the circuit it will test on PROTEUS simulator to look after the problem on designing that circuit. If the design nothing problem on the design circuit, the design circuit will transferred to printed-circuit (PC) boards. In this progress started the planning and layout must create to transfer circuit into PC board. Then component assembly and PC board soldering is the next process. Develop the platform is the final construction to produce the prototype of wall-following mobile robot.
4 Create Simple Algorithm Design Program for micro controller No Burn Program to PIC Design circuit on Protoboard Construct circuit on PCB Yes No No Analysis problem & produced result Develop Prototype Figure 1.1: Flow Chart Scope of Work
5 1.2 Problem Statements The problem in wall-following mobile robot has been study in this project is the movement control target of the robot to sense the wall. The biggest problem facing a robot nowadays is overall system reliability. A robot might face any combination of the following failure modes, firstly mechanical failures, these might range from temporarily jammed movements to wedged gear trains or a serious mechanical breakdown. Secondly is electrically failures, hope it is safe to assume that the computer itself will not fail but loose connections of motors and sensors are a commonly problem. Finally sensor unreliability, sensor will provide noisy data (data that is sometimes accurate, sometimes not) or data that simply incorrect (transmitter fails to detect and trigger motor). The first two of the above problems can be minimized with careful design, but the final category, sensor unreliability, warrants a closer look. Here is a brief analysis of the sensor problem.
6 CHAPTER2 LITERATURE REVIEW These robots are design by Mike Linnen at April 4, 2002 [5]. This can be accomplished by using the front and rear sensor. The arrangement of sensor positioning at left side on body of robot. For a mobile robot, wall following is a useful motion in structured environments and can be employed for obstacle avoidance. In many mobile robot ultra sonic range sensor are used for wall following. With these robots, the range from robot to wall is commonly measured by an ultrasonic sensor and used for motion control. However from the point of view of vehicle motion control, the direction angle to the wall is more useful and suitable information to realize wall following. So Mike Linnen [5] set out to build and program a maze robot to follow one wall. He chooses to use a differential drive system on a round body. This would allow him to control the robot rather easily and prevent it from getting hung up on maze walls. Mike Linnen [ 5] mounted two ultrasonic sensors on a single shaft on top of a servomotor. The sensors were positioned 90 apart. The servomotor allowed the robot to look parallel wall at the same time. In order to tell if the robot was getting closer or further away from a wall a minimum of two sensor readings would have to be taken over a period of time while the robot was moving. Mike Linnen [5] had some difficulty in fine-tuning the reactions needed to prevent the robot from touching the walls. Mike Linnen [5] quickly realized that this sensor arrangement had some shortcomings. He needed to
7 be able to look at a wall and determine if the robot was parallel to it without moving forward. :--.... \, ~ Top View...... _,.... Figure 2.1: DR X Prototype Mike Linnen [ 5] found out some other advantages of this sensor arrangement. While the robot was following a wall and it approached a doorway of the maze the first sensor would detect the opening (doorway) very easily. Once the second sensor detected the doorway he knew the robot was directly in front of the entranceway. A 90 turn towards the entranceway would position the robot perfectly for passage through the door. Passage through the door would also be easily detected. As the robot moved forward, both sensors could detect the door jam. The robot could successfully determine when a door was found and navigate through the door rather easily. The following drawings show the robot navigating through a doorway.
8 Well Figure 2.2: The robot approaches the doorway. W all W all Figure 2.3: The robot passes the doorway.