Robotic Control with Bluetooth Wireless Communication

Robotic Control with Bluetooth Wireless Communication ME 224 Fall 2005 Prof. Horacio Espinosa David Macedonia Adam Same David Storch Norbert Wroblews...
Author: Austen May
26 downloads 1 Views 1MB Size
Robotic Control with Bluetooth Wireless Communication ME 224 Fall 2005 Prof. Horacio Espinosa

David Macedonia Adam Same David Storch Norbert Wroblewski

Table of Contents I. Abstract II. Introduction III. Background & Theory BASIC Stamp LabVIEW Bluetooth Parallax Boe-Bot IV. Experimental Procedure & Activities Equipment Activity 1: Actuation Activity 2: Sensing Activity 3: Control Activity 4: Wireless Communication 12 V. Analysis of Results VI. Conclusion VII. References Appendix

2

3 4 5 5 6 6 7 8 9 10 14 15 16 18

I.

Abstract

Our final project was meant to tie together some of the techniques that we learned throughout the ME 224 course. The goal was to establish wireless communication to control the movement of a Parallax Boe-Bot. To accomplish this, we needed to tie together multiple different programs and pieces of hardware. The first step was to assemble the Boe-Bot and center its servo motors. We were then introduced to BASIC Stamp 2.0 programming, and used it to control the movement of the servos through serial communication. Once we had learned how to manipulate the robot’s motion through BASIC Stamp, we wrote a LabVIEW program to acquire data for the calibration of a gyroscope positioned on the Boe-Bot. The next step was to integrate the eb500 wireless card and the Boe-Bot’s BASIC Stamp, and then establish communication between the BASIC Stamp and Windows HyperTerminal. This allowed us to use HyperTerminal to wirelessly control the motion of the robot. Finally, we created a LabVIEW vi file that could be linked to Bluetooth to manipulate the robot in real time. We encountered many difficulties during this project, mainly because we were integrating so many different pieces of technology. The true challenge was not in the actual programming, but in establishing communication between the different systems. Our group was forced to strike a balance between perfecting the intricate details of BASIC Stamp and LabVIEW programs, and stepping back to examine the larger picture of how each part of the project was to be incorporated into the BoeBot’s overall control system. The group found the most success in establishing wireless communication. We were able to use simple BASIC Stamp commands to determine that the eb500 card was functioning with the Board of Education. We could use text inputs in HyperTerminal to wirelessly drive the Boe-Bot. The greatest troubles were encountered when attempting to use an Analog-to-Digital converter to achieve wireless feedback. This feature greatly complicated the BASIC Stamp and LabVIEW programming, and we were ultimately unable to accomplish this goal within the allotted time period. We also ran into problems with our LabVIEW control program; the movement of the robot is not as smooth as when it is controlled directly with HyperTerminal. In the end, we accomplished a lot in the way of establishing wireless communication and creating a LabVIEW user interface. However, we were also left with many unresolved issues. This project was an interesting medium through which to integrate many of the techniques learned during the course.

3

II.

Introduction

Throughout our studies during ME 224, we have examined many areas of electrical systems. We began by using breadboards and the function generator to create simple circuits with resistors, capacitors, and LEDs. From there, we studied signal conditioning with op-amps and data acquisition with LabVIEW and the DAQ card. We later applied this information to experiments involving temperature control and thermal diffusion. This project is meant to utilize our knowledge of LabVIEW programming, as well as to introduce the concept of wireless communication. Our objectives were: • Design and implement an experiment to realize the control of a commercially available robot. • Enhance the knowledge of LabVIEW, Data acquisition, Feedback control, and MEMS sensing. • Get an understanding of wireless communication using Bluetooth technology. The methodology of this project can be separated into four sections: Sensing:

Calibration of the MEMS gyroscope to obtain the information of angular motion.

Actuation: Assembling the Boe-Bot, centering the servo motors, and programming to control the Boe-Bot’s motion. Control:

Using LabVIEW to control the navigation of the robot along a predefined path.

Wireless Communication:

Implementing the Bluetooth wireless modules to avoid the usage of wires.

The paths the robot was required to follow can be found in Appendix A. References available to the group included the Parallax and EmbeddedBlue manuals, the reports generated by student groups from previous years, and the knowledge of our classmates. Indeed, the success of each group was due in part to our ability to collaborate and discuss the different aspects of the project that each had completed.

4

III.

Background & Theory

BASIC Stamp: The Parallax BASIC Stamp is a microcontroller with a small BASIC interpreter. BASIC is a simple language to learn and use, and so the BASIC Stamp has long been a favorite among electronics hobbyists and students alike. The low cost of these microcontrollers are perfect for prototyping and controlling applications. Our project incorporates the BS2 variant of the Stamp. It operates at 20 kHz and can handle 4,000 instructions per second. Figure 1: BASIC Stamp The control of a robot is just one of the many possible applications of the Basic Stamp technology. Other projects we have found online include Door Entry Card Readers, Weather Stations, Electronic Compasses, The TI82 interface, Water Volume Meters, and even Garage Door Openers. We will be using the basic stamp to control the pulse received by pins 12 and 13, the pins connected to the servo motors of our Boe-Bot. By programming a series of pulses sent to the motors, we hope to be able to maneuver our Boe-Bot. LabVIEW: LabVIEW is a platform and development environment for a visual programming language. Originally developed for the Apple Macintosh in 1986, LabVIEW is used for data acquisition, instrument control, and industrial automation. LabVIEW is considered to be dataflow language. Unlike traditional languages, LabVIEW and other dataflow languages do not determined by execute commands in sequence. Rather, the program is executed once all the inputs are available to a node. LabVIEW allows for multiple nodes to be working at once, therefore the program is capable of parallel processing and execution. Therefore, if a program requires multiple solutions to be calculated by input data, LabVIEW is a quick and efficient solution. The major advantage of data-flow is that it can be represented in a graphical setting. The program is represented much like an electrical circuit with nodes set as icons, and the data flowing between them as represented as wires. Complex systems can be reduced with the use of sub-VIs, iconic representations of programs which take input data and compute a result which is further used in the program. As a result, programs that would take up several screens can be reduced into neat representations. We will be using LabVIEW to get feed back from our gyroscope in order to calibrate the servo motors. Our ultimate goal is to be able to wirelessly control our robot using commands in LabVIEW.

5

Bluetooth Electronic devices that exist today use several different methods of communicating with one another. These include using a wide array of cables, wires, connectors, plugs, and other means. Wireless communications were developed to simplify the way electronic devices communicate, and reduce the wires attached to them making them easier for us to use. Bluetooth is a standard for wireless technology, created and developed by a group of electronics manufacturers to enable their electronic equipment to make their own connections without wires or user commands. It does this using a chip that can be plugged into whatever device is utilizing the technology. Instead of carrying information through a cable, the Bluetooth chip transmits the information at a unique frequency which is recognized and received by a receiver chip that connected to a receiver device such as a computer. Bluetooth technology is very advantageous to electronic devices today. The wireless feature enables the user the freedom to avoid being tied down with excess cabling. It is also very inexpensive. A Bluetooth chip only costs around five dollars, combined with the fact that it does not consume a great deal of power means that it is very logical to be implemented in modern wireless devices and can function anywhere. Bluetooth also reduces user interface since it initiates conversation with its fellow devices automatically. Lastly, Bluetooth is universal, streamlining across many major hardware companies and devices. Bluetooth can be applied to nearly every device made by almost every company. We will be using Bluetooth to communicate with our Boe-Bot wirelessly. A Bluetooth chip is plugged into the wireless card connected to the Boe-Bot, and it transmits signals to the receiver, attached to the computer through a USB cable. Using Bluetooth, we will not be constrained by wires and our Boe-Bot theoretically should be able to be controlled in real time. The only limitation our Boe-Bot has is range, because the distance from which the chip and the receiver can interact is limited. Parallax Boe-Bot The Boe-Bot is a popular programmable robot made by Parallax Inc. Its distinguishing feature is the Board of Education (BOE), which acts as the robot’s controller board and is pre-assembled in the kit. The BOE contains the Basic Stamp II controller chip, which allows the robot to communicate with the popular and easy to use programming language Basic Stamp. It also contains connections enabling a wireless card to be plugged into it, as well as a connection to the computer. A switch is located on the board with three different settings: 0, 1, 2 to correspond to off, Basic stamp, and servo motion respectively. Using the Board of Education, the Boe-Bot can perform a large range of functions. In this project, we will be using it to travel along four set paths. The robot itself is quite small: about five inches long, 4 inches wide, and 3 inches tall. Its base is an aluminum chassis that serves as a platform for the servo motors

6

and BOE. It contains holes and grooves for other electronic equipment that the user wants to secure to the Boe-Bot. Two large wheels fit into the servo motors and held in place by a small screw. The rear wheel is a polyethylene ball with a hole drilled through the middle. It is attached to the robot with a cotter pin. The servo motors are attached to the underside of the chassis, and runs from a power supply that uses 4 AA batteries. The robot also has a breadboard for additional circuitry. The wireless card and Bluetooth adaptor were not part of the Boe-Bot kit, and were purchased separately.

IV.

Experimental Procedure & Activities

The equipment used during this project was: •

• • • • •

Parallax Boe-Bot kit o cart o servo motors o wheels o Board of Education/BASIC Stamp o BASIC Stamp Editor 2.0 o serial cable DBT-120 USB Bluetooth adapter A7 Engineering EmbeddedBlue eb500 Wireless Card LabVIEW 7.1 and DAQ Windows HyperTerminal Analog Devices ADXRS150EB Gyroscopic Sensor

Our Boe-Bot was pre-assembled at the outset of the project. The cart served as the base of the robot. The two large wheels were attached to the servo motors. The Board of Education (BOE) was screwed to the top of the cart, and the servo motors were wired to pins 12 (Left) and 13 (Right). On the BOE was a small breadboard with a BASIC Stamp chip.

Figure 1: Fully-assembled Boe-Bot

7

Activity 1: Actuation The first step after receiving the Boe-Bot was to center its servo motors. We detached the wheels from the servos, and then removed the servos from the cart. Centering was accomplished by sending a “stop” pulse to the BASIC Stamp: ' Robotics with the Boe-Bot - CenterServoP12.bs2 ' This program sends 1.5 ms pulses to the servo connected to ' P12 for manual centering. ' {$STAMP BS2} ' {$PBASIC 2.5} DEBUG "Program Running!" DO PULSOUT 12,750 PAUSE 20 LOOP The PULSOUT command of 750 results in a pulse width of 1.5 ms. This pulse is meant to give an angular velocity of zero to the servo motors. The servos initially rotated when the CenterServo program was run. We then rotated the potentiometer of each motor until rotation stopped, ensuring that a PULSOUT command of 750 was related to a velocity of zero.

Figure 2: Centering the servo motors

Activity 2: Sensing

8

Following the centering of the servo motors, it was time to calibrate the gyroscope. The goal of calibration was to obtain an equation relating gyroscope voltage to angular velocity. First, we wrote a LabVIEW program to collect and organize data gyroscope voltage data from the DAQ card. We then developed a BASIC Stamp program that rotated the robot for a certain number of counts at different angular velocities. The LabVIEW and BASIC Stamp programs for calibration can be found in Appendices B and C, respectively. Full calibration data can be found in Appendix D. We received the following plot of voltage versus time: Voltage vs. Time 5.0 4.5

Gyroscope Output Voltage (V)

4.0 3.5 3.0 2.5 2.0 1.5 1.0 0.5 0.0 0

10

20

30

40

50

60

70

80

Time (s)

Figure 3: Gyroscope Calibration: Voltages for Changing Pulse Width As one can see from our BASIC Stamp calibration program, each spike in voltage corresponds to a different angular velocity. Both servo motors of the Boe-Bot were given pulse widths in increments of five from 650 to 850. The gyroscope voltage was sent through the DAQ card to LabVIEW every 100 milliseconds, and successively written to a spreadsheet file. Between each rotation, the robot would pause, allowing the gyroscope to reset. To find the angular velocity, we manually measured the speed of rotation of the Boe-Bot for each PULSOUT command. This was accomplished by determining the time taken for the robot to move through a certain number of rotations. Once we obtained the corresponding velocities for each pulse width, we could plot gyroscope voltage as a function of angular velocity. The results of this are shown in Figure 4.

9

Voltage vs. Angular Velocity 5.0 4.5

y = -0.6962x + 2.4705

4.0

R2 = 0.9993

3.5

Vout

3.0 2.5 2.0 1.5 1.0 0.5 0.0 -4.0

-3.0

-2.0

-1.0

0.0

1.0

2.0

3.0

4.0

Angular Velocity (rad/s)

Figure 4: Gyroscope Calibration: Voltage vs. Angular Velocity The servos were found to have zero rotation around 2.56 V, and max velocity at 0.5 V and 4.5 V. The equation obtained from Figure 4 using a linear curve fit was: y = -0.6962x + 2.4705 This equation obtained an R2 value of 0.9993. Integrating this equation, we obtain a relationship between voltage and angular position: V = .3481• Θ2 + 2.4705 • Θ This correlation can be used in a LabVIEW program to determine the real-time angular position of the Boe-Bot. Theoretically, this information can be used to provide feedback related to the robot’s real-time motion. Activity 3: Control Having found the relationship between the voltage and the angular velocity, and knowing the pulse range required for each servo motor to move, we started working on controlling our robot. During calibration we learned how to control the servo rotation using BASIC Stamp. In the program we were able to specify the length of the pulse that was sent to each servo motor, which determined the angular velocity of the wheel. By having the pulse length as a dependent variable in a “for” loop, we were able to set the counter, which allowed us to control the duration and speed of rotation of each wheel.

10

With this in mind we determined the most efficient pulse rates for certain actions (moving forward, moving backwards, turning left, and turning right). We noticed that towards the higher pulse rates (going up towards 850, and down towards 650) the speed of the servo motors approached a limit. We determined it was inefficient to drive the motors at full speed, and so chose pulse widths of 700 and 800 (pin 12, pin 13 respectively) configuration for forward motion, and widths of 725 and 725 for rotation. These pulse widths were chosen because they showed little variance in distance traveled for a set amount of time, while maintaining a reasonable speed (greater than 90% of max speed). Pulse 12 650 675 700 725 750 772 800 825 850

Pulse 13 850 825 800 772 750 725 695 670 650

distance 1 54.10 53.00 49.30 30.00 0.00 28.70 49.60 52.00 52.60

distance 2 54.20 53.60 49.50 30.00 0.00 28.70 49.70 52.00 52.90

distance 3 54.80 53.00 49.90 29.70 0.00 28.80 49.20 52.40 52.90

average 54.37 53.20 49.57 29.90 0.00 28.73 49.50 52.13 52.80

time (seconds) 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00

velocity (cm/sec) 18.12 17.73 16.52 9.97 0.00 9.58 16.50 17.38 17.60

A similar test was done on the rotation of the robot at different pulses, with the most reliable pulses being chosen as our standard for operation during the next few phases of design. With a set velocity and turning speed we were able to write a preliminary LabVIEW program for the controlling parameters of the robot, which can be found in Appendix E: RobotControl.vi. In this program, the user can choose up to five sets of directions (distance “X” at angle “Y”). When the program was run, the outputs included the necessary pulse lengths for pins 12 and 13, as well as the number of iterations needed in the “for” loop:

Figure 5: RobotControl.vi Front Panel

11

The user could then read the output data and type it into the appropriate locations in the BASIC Stamp control program. With this program we were able to navigate the Boe-Bot along any of the four pre-determined paths, or theoretically, any arbitrary path made of straight lines and angles. An example of these programs can be found in Appendix F. However, due to the nature of those four paths, it was not until later that we learned that this method of programming had major limitations. For example, backwards motion was impossible, as were clockwise turns. The biggest shortcoming of the program was that it did not communicate directly with BASIC Stamp, and therefore could not control the robot in real time. Our next goal was to create a LabVIEW program that communicated changes in command with BASIC Stamp. The exchange of information between the two programs relies on Bluetooth communication, which will be discussed in-depth in following sections. We utilized a LabVIEW program that replicated a 9-button keypad on the Front Panel. The user interface allows the operator to depress a button corresponding to the desired motion command. A series of nested True/False statements ensures that the correct numeric command (0 through 8) is associated with the depression of each button. LabVIEW outputs the numeric command to Bluetooth and eventually to the BASIC Stamp, and also displays the appropriate pulse widths on indicators. The LabVIEW program can be found in Appendix G. We were able to establish and maintain a wireless connection; however, we were not able to fluidly control the robot. In contrast to the smooth movement achieved using HyperTerminal, the LabVIEW control results in a pause between each command that leads to a very jerky motion. Activity 4: Wireless Communication We began working with Bluetooth technology by testing the communication between the wireless adapter and BASIC Stamp. We created a connection in HyperTerminal that was specific to the COM port being used by our DBT-120 adapter and our group’s eb500 wireless card. This involved installing the Bluetooth driver, establishing a connection to the wireless card, and determining the outgoing COM port from the computer to the wireless system. By using the receive.bs2 program provided by A7 Engineering, we verified the wireless connection by typing text into HyperTerminal and seeing it reflected in BASIC Stamp’s debug window:

12

'{$STAMP BS2} szData VAR Byte(20) 'Wait for the eb500 radio to be ready PAUSE 1000 Main: SERIN 0,84,[STR szData\20\CR] DEBUG STR szData,CR GOTO Main

Figure 5: Communication between HyperTerminal and BASIC Stamp Once we were certain that HyperTerminal could communicate effectively with BASIC Stamp, we developed a BASIC Stamp program that could control the Boe-Bot’s motion using numeric inputs from the keyboard. We began with a simple program that could move the robot forward, backward, and turn left and right using the number keys 1, 2, 3, and 4. We took advantage of the BRANCH command within BASIC Stamp to link each number key to a motion instruction. We then modified the program to allow for better control over the Boe-Bot’s motion. The new program allows the user to type on the 9-button keypad on the right side of a desktop keyboard and employ nine different motion instructions: 1 = Slow Left Turn 4 = Medium Left Turn 7 = Quick Left Turn 8 = Forward 9 = Quick Right Turn 6 = Medium Right Turn 3 = Slow Right Turn 2 = Backward 5 = Hold Position

Figure 6: Numeric Key Pad Control

13

The reason for enabling the user to choose between three different speeds of rotation was to provide greater flexibility in movement and easier correction when examining the Boe-Bot’s feedback. The entire BASIC Stamp program can be found in Appendix H. Our final challenge was to integrate wireless control into the LabVIEW program described in the above section. LabVIEW could recognize the eb500 card through the Bluetooth Service Discovery sub-vi. We used the Bluetooth Open Connection and Bluetooth Write sub-vi’s to send the user-input commands through the wireless system to the BASIC Stamp. The commands were in the form of nine buttons on the LabVIEW Front Panel as shown below:

Figure 7: LabVIEW User Graphical Interface This program involves the same type of command input as HyperTerminal, but instead of using the keyboard, the user clicks on the LabVIEW buttons. In contrast to the smooth control achieved using HyperTerminal, the LabVIEW program caused the Boe-Bot to move with a jerky motion.

V.

Analysis of Results

The group achieved varying levels of success with the different parts of this project. In the early stages, we were quite pleased with our progress. The assembly and actuation of the Boe-Bot went as planned, and we were able to gain a good understanding of the workings of the robot as we worked with its servo motors and learned its programming language. Our calibration results easily fit to a linear function with an R2 value that was very close to one, convincing us that the calibration stage of the project was done correctly. We encountered difficulty when we began working with the Bluetooth wireless communication, but took these challenges in stride. Using a completely new piece of technology with few given resources was a new concept to all members of the group. We were very pleased with our success in establishing wireless 14

communication between the Boe-Bot and HyperTerminal. The BASIC Stamp program we developed to manipulate the Boe-Bot with the keypad through HyperTerminal works almost flawlessly, the limiting factor being the strength of the connection between the DBT-120 and the eb500 card. The results from using HyperTerminal were quite better than we had expected. During this stage, we were able to showcase our knowledge of how different pulse widths can be used to finetune the movement of the Boe-Bot. The group was less pleased with a few other aspects of the project. We had moderate success controlling the Boe-Bot with LabVIEW. Our program allows the user to press a button corresponding to a motion command, and the robot does respond. However, the motion of the robot is very jerky, and there is a one-second delay between the issuance of the command and the response of the robot. Due to time constraints, we were unable to ultimately discover and correct this flaw. One possibility for this drawback is that the BASIC Stamp is being over-loaded with data sent over the wireless connection. Another source of the glitch could be in the LabVIEW program itself; perhaps the program is configured such that it is connecting to the Bluetooth card each time the “for” loop is executed. The group is anxious to hear how other students have configured their programs and to discover how we can improve our LabVIEW control. We are also disappointed that we were unable to get wireless feedback from the gyroscope. In theory, we would use an analog-to-digital converter to switch the analog output voltage from the gyroscope to a digital value. This digital value could then be sent via Bluetooth to LabVIEW. After calibration of the ADC, we would have an expression to convert digital values back to gyroscope voltage. We could then continually collect feedback data and use the equation obtained during calibration to integrate these voltages and establish the true angular position of the Boe-Bot. The group attempted to transmit gyroscope data using a National Semiconductor ADC0804LCN chip, but with no success. A test of the ADC chip, meant to display digital values as a set of binary LEDs, produced no result. Due to time constraints, we were forced to abandon our quest for wireless feedback and focus on controlling the motion of the Boe-Bot.

VI.

Conclusion

We successfully tied together a lot of ideas and techniques that we had learned throughout the course of ME 224. Our group successfully assembled, centered, and calibrated a Boe-Bot, and used Bluetooth technology to communicate with and manipulate the motion of the robot. We used some techniques, such as LabVIEW programming, that we had been working on throughout the quarter. We also became familiar with a number of new aspects of technology, like BASIC Stamp, HyperTerminal, and Bluetooth. Although we were unable to incorporate wireless feedback in this project, we did accomplish our goal of learning more about the benefit of feedback systems, the need for analog-to-digital conversion, and how calibration of a component can help to integrate it into a control system.

15

The group has some ideas for future study of the topics involved in this project. For one, it would be interesting to see if, given what we now know about wireless communication, obtaining feedback is possible. Future project groups may be able to establish wireless communication faster than we did if they examine the steps that we took. Armed with that extra time, they may be able to accomplish what we could not. Another interesting thing would be to incorporate some other features onto the Boe-Bot. For example, the goal of the project could be to control the BoeBot wirelessly with LabVIEW and make it pop a balloon or collect objects around the room. As we learn more about how to move the Boe-Bot, future students can use that knowledge, expanding the possibilities of what can be accomplished during the few short weeks of this project.

16

VII. References Ahmadi, Alex; Hoffman, John; Huertas, Andres; Meruani, Azeem; Singer, Simcha. “Robotic Control with Gyroscopic Sensing.” Final Project – ME 224, Prof. Horacio Espinosa. 06 June 2004. Armstrong, Kendra; Eccles, Nick; Maguire, Cary; Taam, Alex; Williams, Paul. “Final Project Report.” Final Project – ME 224, Prof. Horacio Espinosa. 09 June 2005. “Bluetooth.” . 30 November 2005. “Bluetooth.” . 01 December 2005 “Boe-Bot Robot.” . 01 December 2005. “Comparing ARobot and Boe-Bot.” . 01 December 2005. “LabVIEW.” . 01 December 2005. Lovsin, James; Morales, Erica; Sheehan, Dan; Widzer, Josh. “Path Following Robot with Gyroscopic Sensing.” Final Project – ME 224, Prof. Horacio Espinosa. 10 June 2005. “What is Bluetooth?” . 30 November 2005.

17

Appendix A: Pre-Determined Robot Paths

18

Appendix B: LabVIEW Program – Gyroscope Calibration

19

Appendix C: BASIC Stamp Program – Gyroscope Calibration ' {$STAMP BS2} ' {$PBASIC 2.5} DEBUG "PROGRAM RUNNING" counter VAR Word y VAR Word x VAR Word PAUSE 10000 FOR y = 130 TO 150 FOR counter = 1 TO 500 X = 5 * y PULSOUT 12, X PULSOUT 13, X PAUSE 20 NEXT PAUSE 3000 NEXT PAUSE 1000 FOR y = 150 TO 170 FOR counter = 1 TO 500 X = 5 * y PULSOUT 12, X PULSOUT 13, X PAUSE 20 NEXT PAUSE 3000 NEXT DEBUG "Program Finished"

20

Appendix D – Gyroscope Calibration Data Pulse 650 655 660 665 670 675 680 685 690 695 700 705 710 715 720 725 730 735 740 745 750 755 760 765 770 775 780 785 790 795 800 805 810 815 820 825 830 835 840 845 850

Voltage .370 .386 .376 .422 .402 .434 .462 .479 .508 .555 .621 .708 .816 .927 1.109 1.343 1.600 1.899 2.210 2.445 2.445 2.450 2.450 2.685 2.982 3.282 3.559 3.958 4.096 4.192 4.260 4.329 4.324 4.395 4.385 4.414 4.461 4.488 4.484 4.462 4.480

Time (s) 4.20 4.30 4.20 6.50 6.50 6.50 6.60 6.60 6.80 6.90 7.10 7.30 7.80 8.30 9.40 7.70 10.30 7.60 4.30 0.00 0.00 0.00 4.50 5.60 8.40 6.80 8.90 8.10 5.00 7.30 9.30 6.80 6.70 6.70 6.60 6.60 6.60 6.60 6.60 6.50 6.50

rotations 2.00 2.00 2.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 2.00 2.00 1.00 0.25 0.00 0.00 0.00 0.50 1.00 2.00 2.00 3.00 3.00 2.00 3.00 4.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00 3.00

21

radians 12.566 12.566 12.566 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 12.566 12.566 6.283 1.571 0.000 0.000 0.000 3.142 6.283 12.566 12.566 18.850 18.850 12.566 18.850 25.133 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850 18.850

rads/sec 2.992 2.922 2.992 2.900 2.900 2.900 2.900 2.856 2.772 2.732 2.655 2.582 2.417 2.271 2.005 1.632 1.220 0.827 0.365 0.000 0.000 0.000 0.698 1.122 1.496 1.848 2.118 2.327 2.513 2.582 2.702 2.772 2.813 2.813 2.856 2.856 2.856 2.856 2.856 2.900 2.900

deg/sec 171.429 167.442 171.429 166.154 166.154 166.154 166.154 163.636 158.824 156.522 152.113 147.945 138.462 130.120 114.894 93.506 69.903 47.368 20.930 0.000 0.000 0.000 40.000 64.286 85.714 105.882 121.348 133.333 144.000 147.945 154.839 158.824 161.194 161.194 163.636 163.636 163.636 163.636 163.636 166.154 166.154

Appendix E: RobotControl.vi

22

Appendix F: BASIC Stamp Program – Parallelogram Path ' {$STAMP BS2} ' {$PBASIC 2.5} DEBUG "PROGRAM RUNNING" counter VAR Word PAUSE 5000 'first angle 'FOR counter = 1 TO 122 ' PULSOUT 12, 725 ' PULSOUT 13, 725 ' PAUSE 20 'NEXT 'first displacement FOR counter = 1 TO 123 PULSOUT 12, 700 PULSOUT 13, 800 PAUSE 20 NEXT PAUSE 50 'second angle FOR counter = 1 TO 20 PULSOUT 12, 725 PULSOUT 13, 725 PAUSE 20 NEXT PAUSE 50 'second displacement FOR counter = 1 TO 123 PULSOUT 12, 700 PULSOUT 13, 800 PAUSE 20 NEXT PAUSE 50 'third angle FOR counter = 1 TO 59

23

PULSOUT 12, 725 PULSOUT 13, 725 PAUSE 20 NEXT PAUSE 50 'third displacement FOR counter = 1 TO 123 PULSOUT 12, 700 PULSOUT 13, 800 PAUSE 20 NEXT PAUSE 50 'fourth angle FOR counter = 1 TO 20 PULSOUT 12, 725 PULSOUT 13, 725 PAUSE 20 NEXT PAUSE 50 'fourth displacement FOR counter = 1 TO 123 PULSOUT 12, 700 PULSOUT 13, 800 PAUSE 20 NEXT PAUSE 50 'fifth angle FOR counter = 1 TO 59 PULSOUT 12, 725 PULSOUT 13, 725 PAUSE 20 NEXT PAUSE 50

24

Appendix G: Final LabVIEW Wireless Boe-Bot Control Program

Block Diagram: False = button not pressed (both pulses = 750)

25

Block Diagram: True = button pressed (proper command and pulse widths given as outputs)

26

Appendix H: Final BASIC Stamp program – Multiple-Speed Control '{$STAMP BS2} LOW 12 LOW 13 LMotor CON 12 RMotor CON 13 CmdData VAR Byte DEBUG "connecting",CR Connect: PAUSE 1000 SEROUT 1,84,["con 00:OC:84:00:0C:A6",CR] DEBUG "connected, attempt commands",CR Main: SERIN 0,84,[DEC1 CmdData] DEBUG DEC1 CmdData BRANCH CmdData,[Hold, slowleft, back, slowright, left, hold, right, fastleft, go, fastright] GOTO Main slowleft: PULSOUT LMotor,725 PULSOUT RMotor,725 SEROUT 1,84,["slow left "] GOTO Main back: PULSOUT LMotor,650 PULSOUT RMotor,850 SEROUT 1,84,["retreat! "] GOTO Main slowright: PULSOUT LMotor,775 PULSOUT RMotor,775 SEROUT 1,84,["slow right "] GOTO Main left: PULSOUT LMotor,688 PULSOUT RMotor,688 SEROUT 1,84,["left "] GOTO Main

27

right: PULSOUT LMotor,813 PULSOUT RMotor,813 SEROUT 1,84,["right "] GOTO Main fastleft: PULSOUT LMotor,650 PULSOUT RMotor,650 SEROUT 1,84,["quick left "] GOTO Main go: PULSOUT LMotor,850 PULSOUT RMotor,650 SEROUT 1,84,["go! "] GOTO Main fastright: PULSOUT LMotor,850 PULSOUT RMotor,850 SEROUT 1,84,["quick right "] GOTO Main Hold: SEROUT 1,84,["hold position "] GOTO Main

28