The magazine of the Melbourne PC User Group

Robotics — The Literature
Major Keary

Until recently there has been little literature on robotics at the practical application level. However, there is now a flow of books that includes something for everybody: students from late primary to tertiary; teachers; and adults who may be interested in robotics because they have student children, as a mind-exercising recreational activity, or an enjoyable way to learn programming basics.

How to Build a Robot

This slim volume from Oxford is designed for children at the senior end of primary school and the junior end of high school. It is also a remarkably good introduction for adults with an interest in the subject, especially if they either want to encourage their children (or students), or equip themselves to answer questions. It contains a wealth of information (great for Trivial Pursuitists) and includes some simple projects for children. It doesn't really lay down the instructions for building a robot per se, but talks about the factors that have to be considered and describes some of the early examples of robotics. The writing style is breezy without patronising young readers; the author manages to introduce interesting facts without being tedious, and supports the text with simple, but effective, drawings.
 
I came across a couple of factual discrepancies; the term, robot was not "made up" by Karel Capek, but came from a Czech word (also in Polish and Ukrainian), robota, which means 'forced labour'. That, however, doesn't affect the book's worth - it's just fodder for pedants. There is a wealth of historical background presented in a casual, fun manner that is bound to make it stick. A delightful book that shouldn't be missed.
 
A number of simple, and safe, experiments are described for children who want hands-on projects. An inexpensive title that deserves a place in any library that serves the needs of children.
Clive Gifford: How to Build a Robot
ISBN 0-19-910741-6
Published by Oxford, 96 pp., 
RRP $13.95 incl. GST

Robots for Kids

This Morgan Kaufmann title has not been written for children, and is not a manual for building robots. It does contain useful information about planning and designing robots, but the main purpose is to discuss
- and promote - the use of robotics in education, especially to encourage an early interest in science and maths.

The book contains papers contributed by twenty-five authors and seven interesting views written by children from ages seven to twelve. 
It is an excellent resource for educationalists, documenting what is being done and discussing practical aspects of real world applications of robotics in education. The lists of references are quite extensive. Any adult with an interest in education, especially the encouragement of boys to become involved in the sciences, should find this absorbing reading.
 
Even though the papers have a formal style about them, they make for easy and interesting reading.

Druin and Hendler (eds.): Robots for Kids
ISBN 1-55860-597-5
Published by Morgan Kaufmann, 
377 pp., 
RRP $105.05 incl. GST

O'Reilly on Mindstorms

One the first books - if not the very first book - on Mindstorms was published by O'Reilly, is still in print, and its relevance is alive and well. In the preface the author writes, "A vibrant, inventive online community sprang up around Mindstorms robots. In some ways this book is an introduction to the most important developments in that community - alternate [sic] programming environments and advanced building techniques. But this book goes farther than that, painting a backdrop of the theories and practices of mobile robotics." He then goes on to say, "at the same time [as enjoying the fun of building a robot] you're learning a lot about ... how to write programs ... ".

The book strikes a good balance between constructional and programming aspects of Mindstorms. The alternative programming languages described are pbFORTH, legOS, and NQC. The use of those languages is not just mentioned, but explained with illustrative code. Furthermore, there are many references to online resources for Windows, Mac, and Linux users.

I was taken by the discussion of subsumption architecture, "a radically different paradigm for robot progamming developed by Rodney Brooks at MIT", which departs from the traditional method of trying to emulate human thought processes. It's pretty serious stuff, but the author manages to handle the subject in plain language. Indeed, the style throughout is casual without patronising the reader.
 
This title is designed for those who have used Mindstorms and want to go beyond the limits imposed by the LEGO native programming environment. There is even a chapter on making your own sensors and actuators. Five construction projects are used, with plenty of images, to illustrate programming and mechanical concepts. An excellent overall coverage.

Jonathon Knudsen: 
The Unofficial Guide to LEGO Mindstorms Robots
ISBN 1-56592-692-7
Published by O'Reilly, 247 pp., 
RRP $75.00 incl. GST

A Guide to Mindstorms

LEGO's Robotics Invention System (RIS) comes in kit form, the core of which is a programmable brick called RCX (Robotic Command Explorer). Batteries power the RCX-which has a miniature monitor - and programs can be downloaded from a PC by means of an infrared transmitter (part of the kit). Sufficient components (motors, sensors, gears, etc.) are included to enable construction - and programming - of various robots. Additional components can be purchased either separately or as supplementary kits and the book contains useful information about them.
 
The author has developed an alternative programming language to RCX, which comes with the LEGO kit. Even though RCX is reasonably easy to use, NQC (Not Quite C) is more useful and has the added advantage of introducing users to programming in C. A companion CD contains implementations of NQC for Windows, Mac, and Linux.

The Definitive Guide to LEGO Mindstorms covers both programming and construction aspects of RIS versions 1 and 1.5. The primary focus is on mechanical design, but robots have to be programmed and the fundamentals of that aspect are dealt with in detail. The book begins with a chapter that explains the RCX programming environment, how programs are created, and how they are downloaded to the RCX. The author's NQC language and compiler is briefly introduced, with mention of RCX code (Mindstorms comes with a proper manual that covers RCX coding). Chapter two is devoted to the RCX and those components with which it interacts (motors and sensors).
 
Chapter three is an NQC language tutorial. Further detailed documentation is contained on the companion CD. The NQC programming language is quite easy to use, and plenty of examples are provided for the new user.
 
Chapter 4 discusses construction issues in a very practical manner and is supported by excellent illustrations. 
All the components are described, with advice on which is appropriate for which kind of application. Topics include frames, gears, pulleys, levers, differentials, bracing, and ratchets. Structural failure is a problem frequently encountered by inexperienced users because they underestimate the need for adequate structural strength.
 
The following fifteen chapters deal with projects, starting with the simple and advancing through increasing degrees of complexity. The informative discussions of mechanical issues are very well presented. The necessary NQC programs, with explanations, are provided with descriptions of construction procedures. RCX code examples are also provided in these chapters.

Appendices contain an NQC quick reference, a discussion of progamming tools, and information about Mindstorms sets and supplementary parts.

The book is, in its own right, a very good introduction to programming for children and adults. It is, of course, aimed at users of Mindstorms, and for them this is an essential resource and ongoing reference. Very well presented; the author manages to communicate a lot of quite technical information in readable language that won't overwhelm the reader. Highly recommended.

Dave Baum: Definitive Guide to LEGO Mindstorms
ISBN 1-893-115-09-7
Published by Apress, 385 pp. + CD, 
RRP $52.95 incl. GST

Mindstorms Projects

The author of Creative Projects with LEGO Mindstorms, Benjamin Erwin, has had a long involvement with the product and one of ROBOLAB's developers. In particular he has been active at a professional level in the use of robotics as a teaching tool.
 
The book is a valuable resource for teachers, students, and parents of students (from early secondary school upwards). Teachers who are interested in the educational application of robotics will find it an excellent introduction to Mindstorms, both at programming and mechanical-cum-constructional levels. Students, whether their interest in robotics is recreational or part of a school curriculum, should find the projects interesting and instructive. For parents the book provides a manual that will enable them to help younger users, and to appreciate the value of robotics as both a recreational and educational activity.

A companion CD contains step-by-step building instructions for the projects; programs in NQC, Visual Basic, and ROBOLAB; video clips of robots in action; the latest version of NQC, RCXcc, and a GUI for NQC; and a demo version of ROBOLAB. I was impressed by the good use made of the CD; much of the detail about construction of the book's projects is contained in HTML files, thus saving valuable - and more expensive - book space.

The text is supported by diagrams, colour illustrations, and photographs showing important mechanical detail.
 
There are thirty project ideas ranging from simple to complex. Generally the programming examples are in LEGO's RCX code, but a part of the book - Advanced Programming - contains chapters dedicated to Visual Basic, ROBOLAB, and NQC. That part of the book also contains some projects that require advanced programming techniques. There is also a discussion of inter-robot communication, which is achieved by infra-red devices.

Incidentally, VBA - which comes with MS Office - is sufficient for programming the RCX, but requires the presence of a file, spirit.ocx.

Apart from the detailed coverage of programming, the discussion of various mechanical arrangements is very good. Even if one does not intend to construct robots, the book makes interesting reading.
 
This title is well-presented and visually pleasing. The tutorial style is suited to those who are looking for guidance to hands-on LEGO robotic projects, and teachers or students where robotics is being used as an educational tool.

Benjamin Erwin: Creative Projects with LEGO Mindstorms
ISBN 0-201-70895-7
Published by Addison-Wesley, 
303 pp. + CD, RRP $59.95 incl. GST

Advanced Mindstorms

In this title, Extreme Mindstorms, Dave Baum is joined by three other authors to provide an advanced guide that includes in-depth discussions of an expanding range of programming options.
 
Since the publication of the Definitive Guide there has been a new version, RIS 2.0; LEGO has made the RIS 2.0 SDK, which includes the RCX 2.0 firmware, publicly available for beta testing. The SDK also contains complete technical documentation. LEGO's willingness to place information in the public domain has enabled the authors to explain the internals of the RCX and develop improved programming environments.

As the subtitle says, this is "An Advanced Guide", and is an ideal text for teachers and students (senior secondary and tertiary) who are using Mindstorms as an educational tool. For anyone who wants to prototype some automated device-a task for which LEGO is well suited-this book should be a valuable resource.
 
A tutorial style is used, supported by projects, to present advanced programming techniques using legOS and pbFORTH. The treatment is thorough and makes the book well worth considering as an introduction to programming in general.

Apart from programming, a part of the book is dedicated to Homebrew Sensors. Sensors are of two types, passive and powered. Touch and temperature are examples of passive sensors; light and rotation are examples of powered sensors. As with the rest of the book, the subject is dealt with thoroughly and in a practical way. Straightforward design, readily available materials, and simple methods of construction are described in detail and supported by ample illustrations. Programming examples are also provided.

An impressive text. Not for the novice, but an essential resource for anyone who wants to get a good grasp on advanced programming techniques for sophisticated robotic projects.

Baum, Gasperi, Hempel, and Villa: Extreme Mindstorms
ISBN 1-893115-84-4
Published by Apress, 347 pp., 
RRP $62.95 incl. GST

Mindstorms for Dummies

This is a good introduction for novices. Part 1 begins at the beginning: opening the box and identifying the array of components. Part 2 is about building various projects, providing clear step-by-step instructions. Part 3 introduces programming. Having put a robot together one needs to program it, and this part of the book is a good tutorial covering the LEGO native programming system. It is designed for novices and should give that level of user the confidence to move on to more powerful programming environments.

Part 4 introduces more complex projects that involve sensors and other features, such as playing music.
 
Appendices contain useful information and some troubleshooting advice. 

A companion CD contains useful material, including colour images of all the book's illustrations (a sensible way of getting around the limitations of black and white hard copy), and four programming applications: Gordon's Brick Programmer, NQC, pbFORTH, and RcxCC. The book does not have much to say about the alternative programming environments, but the CD has links to URLs where further information can be found.
 
A good introduction for novices of any age.

Meadhra and Stouffer: LEGO Mindstorms for Dummies
ISBN 0-7645-0767-2
Published by IDG, 371 pp. + CD, 
RRP $49.95 incl. GST

Ideas for Mindstorms

The LEGO Mindstorms Idea Book is large-format (250 x 200 mm) and much of the space is given over to illustrations, some of which are in colour. The monochrome images are of good quality and show all the necessary detail; the publisher has also put colour versions on a Web site, http://www.nostarch.com/?robotics, which also has links to other useful sites.

A number of projects are described with tabulated lists of the parts needed. They begin with the simple and work through stages of increasing complexity. The instructions for each model begins with a discussion of the mechanical theory, which is a useful resource for teachers who use robotics as an educational tool. The focus is on assembly, and in that respect the instructions and illustrations are very good. Some projects do have a bit more programming detail than others, but overall the programming side is treated with notable economy of words. There seems to be an assumption of knowledge on the part of the reader, or a reliance on the manual that comes with the LEGO kits.
 
An appendix contains a useful NQC reference in chart form. It is not supported by any significant discussion of NQC, but is a handy supplement to the more complete accounts found in other titles.

The strength of this book is its attention to constructional and mechanical detail. For that it is well worth having.

Joe Nagata: LEGO Mindstorms Idea Book
ISBN 1-886411-40-9
Published by No Starch Press, 
RRP $49.95 incl. GST

Reprinted from the September 2001 issue of PC Update, the magazine of Melbourne PC User Group, Australia