ebook img

Embedded Robotics: Mobile Robot Design and Applications with Embedded Systems PDF

427 Pages·2003·36.839 MB·English
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Embedded Robotics: Mobile Robot Design and Applications with Embedded Systems

Embedded Robotics Springer-Verlag Berlin Heidelberg GmbH Thomas Braunl EMBEDDED ROBOTICS Mobile Robot Design and Applications with Embedded Systems With 203 Figures, 33 in color, and 24 Tables Springer Thomas Braunl School of Electrical, Electronic and Computer Engineering The University of Weste m Australia 35 Stirling Highway Crawley, Perth, W A 6009 Australia Cataloging-in-Publication Data applied for Bibliographic information published by the Deutsche Bibliothek Die Deutsche Bibliothek lists this publication in the Deutsche Nationalbibliografie; detailed bibliographic data is available in the Internet at <http://dnb.ddb.de> ACM Subject Classification (1998): I.2.9, C.3 ISBN 978-3-662-05101-6 ISBN 978-3-662-05099-6 (eBook) DOI 10.1007/978-3-662-05099-6 This work is subject to copyright. All rights are reserved, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilm or in any other way, and storage in data banks. Duplication of this publication or parts thereof is permitted only under the provisions of the German Copyright Law of September 9,1965, in its current version, and permission for use must always be obtained from Springer-Verlag Berlin Heidelberg GmbH. Violations are liable for prosecution under the German Copyright Law. http://www.springer.de © Springer-Verlag Berlin Heidelberg 2003 Originally published by Springer-Verlag Berlin Heidelberg New York in 2003 Softcover reprint of the hardcover 1s t edition 2003 The use of general descriptive names, trademarks, etc. in this publication does not imply, even in the absence of a specific statement, that such names are exempt from the relevant protective laws and regulations and therefore free for general use. Typesetting: Camera-ready by the author Cover Design: KiinkelLopka, Heidelberg Printed on acid-free paper 45/3111SR-54321 SPIN 11375340 PREFACE I t all started with a new robot lab course I had developed to accompany my robotics lectures. We already had three large, heavy, and expensive mobile robots for research projects, but nothing simple and safe, which we could give to students to practice on for an introductory course. We selected a mobile robot kit based on an 8-bit controller, and used it for the first couple of years of this course. This gave students not only the enjoy ment of working with real robots but, more importantly, hands-on experience with control systems, real-time systems, concurrency, fault tolerance, sensor and motor technology, etc. It was a very successful lab and was greatly enjoyed by the students. Typical tasks were, for example, driving straight, finding a light source, or following a leading vehicle. Since the robots were rather inexpensive, it was possible to furnish a whole lab with them and to con duct multi-robot experiments as well. Simplicity, however, had its drawbacks. The robot mechanics was unreli able, the sensors were quite poor, and extendability and processing power were very limited. What we wanted to use was a similar robot at an advanced level. The processing power had to be reasonably fast, it should use precision motors and sensors, and - most challenging - the robot had to be able to do on-board image processing. This had never been accomplished before on a robot of such a small size (about 12cm x 9cm x 14cm). Appropriately, the robot project was called "EyeBot". It consisted of a full 32-bit controller ("EyeCon"), interfacing directly to a digital camera ("Eye Cam") and a large graphics display for visual feedback. A row of user buttons below the LCD was included as "soft keys" to allow a simple user interface, which most other mobile robots lack. The processing power of the controller is about 1,000 times faster than for robots based on most 8-bit controllers (25MHz processor speed vs. IMHz, 32-bit data width vs. 8-bit, compiled C code vs. interpretation) and this does not even take into account special CPU features like the "time processor unit" (TPU). The EyeBot family today includes several driving robots with differential steering, tracked vehicles, omni-directional vehicles, balancing robots, six-leg ged walkers, biped android walkers, a flying robot, and a simulation system ("EyeSim"). EyeCon controllers are used in several other projects, with and v Preface without mobile robots. Numerous universities use EyeCons to drive their own mobile robot creations. We use boxed EyeCons for experiments in a second year course in Embedded Systems as part of the Electrical Engineering, Infor mation Technology, and Mechatronics curriculums. And one lonely EyeCon controller sits on a pole on Rottnest Island offthe coast of Western Australia, taking care of a local weather station. Acknowledgements While the controller hardware and robot mechanics were developed commer cially, several universities and numerous students contributed to the EyeBot software collection. The universities involved in the EyeBot project are: University of Stuttgart, Germany University of Kaiserslautern, Germany Rochester Institute of Technology, USA The University of Auckland, New Zealand The University of Manitoba, Winnipeg, Canada The University of Western Australia, Perth, Australia The author would like to thank the following students, technicians, and colleagues: Gerrit Heitsch, Thomas Lampart, J6rg Henne, Frank Sautter, Elliot Nicholls, Joon Ng, Jesse Pepper, Richard Meager, Gordon Menck, Andrew McCandless, Nathan Scott, Ivan Neubronner, Waldemar Spadt, Petter Reinholdtsen, Birgit Graf, Michael Kasper, Jacky Baltes, Peter Lawrence, Nan Schaller, Walter Bankes, Barb Linn, Jason Foo, Alistair Sutherland, Joshua Petitt, Axel Waggershauser, Alexandra Unkelbach, Martin Wicke, Tee Yee Ng, Tong An, Adrian Boeing, Courtney Smith, Nicholas Stamatiou, Jonathan Purdie, Jippy Jungpakdee, Daniel Venkitachalam, Tommy Cristobal, Sean Ong, and Klaus Schmitt. Thanks for proofreading the manuscript and numerous suggestions go to Adrian Boeing, Michael Kasper, Sandra Passamani, Joshua Petitt, Klaus Schmitt, Anthony Zaknich, and everyone at Springer-Verlag. Contributions A number of colleagues and former students contributed to this book. The author would like to thank everyone for their effort in putting the material together. JACKY BALTES The University of Manitoba, Winnipeg, contributed to the section on PID control and to the sections on camera inter faces, ADRIAN BOEING The University of Western Australia, Perth, authored the chapter on the evolution of walking gaits and coauthored the chapter on genetic algorithms, VI Preface CHRISTOPH BRAUNSCHADEL FH Koblenz, contributed data plots to the sec tions on on/off control and PID control, BIRGIT GRAF Fraunhofer IP A, Stuttgart, coauthored the chapter on robot soccer, YVES HWANG The University of Western Australia, Perth, coauthored the chapter on genetic programming, PHILIPPE LECLERCQ The University of Western Australia, Perth, contributed to the section on color segmentation, JOSHUA PETITT The University of Western Australia, Perth, contributed to the section on DC motors, KLAUS SCHMITT University of Kaiserslautern, coauthored the chapter on the RoBIOS operating system, ALISTAIR SUTHERLAND The University of Western Australia, Perth, co authored the chapter on balancing robots, NICHOLAS TAY DSTO, Canberra, coauthored the chapter on map genera tion, DANIEL VENKITACHALAM The University of Western Australia, Perth, coau thored the chapters on genetic algorithms and behavior based systems and contributed to the chapter on neural net works, AxEL W AGGERSHAUSER University of Kaiserslautern, contributed to the sec tion on simulation parameter files. Additional Material Hardware and mechanics of the "EyeCon" controller and various robots ofthe EyeBot family are available from JOKER ROBOTICS and its distributors: http://joker-robotics.com All system software discussed in this book, the RoBIOS operating system, C/C++ compilers for Linux and Windows, system tools, image processing tools, simulation system, and a large collection of example programs are avail able free from: http://robotics.ee.uwa.edu.au/eyebot/ Lecturers who adopt this book for a course can receive a full set of the author's course notes (PowerPoint slides), tutorials, and labs from this website. And finally, if you have developed some robot application programs you would like to share, please feel free to submit them to our website. Perth, Australia, June 2003 Thomas Braunl VII CONTENTS PART I: EMBEDDED SYSTEMS 1 Introduction 3 1.1 Mobile Robots ................................................... 4 1.2 Embedded Controllers ............................................. 7 1.3 Interfaces ...................................................... 10 1.4 References ..................................................... 13 2 Programming Tools 15 2.1 System Installation ............................................... 15 2.2 Compiler for C and C++ .......................................... 16 2.3 Assembler ..................................................... 18 2.4 Debugging ..................................................... 20 2.5 Download and Upload ............................................ 22 2.6 References ..................................................... 23 3 RoBIOS Operating System 25 3.1 RoBIOS Structure ............................................... 25 3.2 Monitor Program ................................................ 28 3.3 System Function and Device Driver Library ........................... 34 3.4 Hardware Description Table ....................................... 36 3.5 Boot Procedure ................................................. 40 3.6 References ..................................................... 41 4 Multitasking 43 4.1 Cooperative Multitasking ......................................... 43 4.2 Preemptive Multitasking .......................................... 45 4.3 Synchronization ................................................. 47 4.4 Scheduling ..................................................... 51 4.5 Interrupts and Timer-Activated Tasks ................................ 54 4.6 References ..................................................... 56 5 Sensors 57 5.1 Sensor Categories ............................................... 58 5.2 Binary Sensor. .................................................. 59 5.3 Analog vs. Digital Sensors ........................................ 59 5.4 Shaft Encoder ................................................... 60 5.5 AID Converter .................................................. 62 IX Contents 5.6 Position Sensitive Device ......................................... 62 5.7 Compass ....................................................... 65 5.8 Gyroscope, Accelerometer, Inclinometer ............................. 67 5.9 Digital Camera .................................................. 70 5.10 References..................................................... 81 6 }\ctuators 83 6.1 DC Motors ..................................................... 83 6.2 H-Bridge ...................................................... 86 6.3 Pulse Width Modulation .......................................... 88 6.4 Stepper Motors .................................................. 90 6.5 Servos ........................................................ 91 6.6 References ..................................................... 92 7 Control 93 7.1 On-Off Control ................................................. 93 7.2 PID Control .................................................... 98 7.3 Velocity Control and Position Control .............................. 104 7.4 Multiple Motors - Driving Straight ................................ 105 7.5 V-Omega Interface ............................................. 108 7.6 References .................................................... 110 8 Real-Time Image Processing 111 8.1 Camera Interface ............................................... 111 8.2 Auto-Brightness ................................................ 113 8.3 Edge Detection ................................................. 114 8.4 Motion Detection ............................................... 116 8.5 Color Space ................................................... 117 8.6 Color Object Detection .......................................... 119 8.7 Image Segmentation ............................................ 124 8.8 Image Coordinates versus World Coordinates ........................ 126 8.9 References .................................................... 128 9 Wireless Communication 131 9.1 Communication Model .......................................... 132 9.2 Messages ..................................................... 134 9.3 Fault-Tolerant Self-Configuration .................................. 135 9.4 UserInterface and Remote Control. ................................ 137 9.5 Sample Application Program ...................................... 140 9.6 References ........................................ ............ 141 x Contents PART II: MOBILE ROBOT DESIGN 10 Driving Robots 145 10.1 Single Wheel Drive ............................................. 145 10.2 Differential Drive ............................................... 146 10.3 Tracked Robots ................................................ 150 10.4 Synchro-Drive ................................................. 151 10.5 Ackennann Steering ............................................ 153 10.6 Model Cars as Robots ........................................... 154 10.7 Localization ................................................... 155 10.8 Navigation .................................................... 160 10.9 Software Architecture ........................................... 167 10.10 References .................................................... 168 11 Omni-Directional Robots 171 11.1 Mecanum Wheels .............................................. 171 11.2 Omni-Directional Kinematics ..................................... 172 11.3 Omni-Directional Robot Design ................................... 175 11.4 Driving Program ............................................... 175 11.5 References .................................................... 177 12 Balancing Robots 179 12.1 Simulation .................................................... 179 12.2 Inverted Pendulum Robot ........................................ 180 12.3 Double Inverted Pendulum ....................................... 183 12.4 References .................................................... 184 13 Walking Robots 187 13.1 Six-Legged Robot Design ........................................ 187 13.2 Biped Robot Design ............................................. 190 13.3 Sensors for Walking Robots ...................................... 193 13.4 Static Balance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194 13.5 Dynamic Balance ............................................... 197 13.6 References .................................................... 202 14 Autonomous Planes 205 14.1 Application ................................................... 205 14.2 Control System and Sensors ...................................... 208 14.3 Flight Program ................................................. 209 14.4 References .................................................... 213 15 EyeSim Simulator 215 15.1 Mobile Robot Simulators ......................................... 215 15.2 EyeSim UserInterface ........................................... 216 15.3 Sensor-Actuator Modeling ....................................... 218 15.4 Multiple Robot Simulation ....................................... 220 15.5 Sample Application ............................................. 221 15.6 Environment Representations ..................................... 222 15.7 Parameter Files ................................................ 225 15.8 References .................................................... 229 XI

See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.