In building a balancing robot you need a gyroscope unit and an accelerometer unit in order to get it to balance. But I also wanted it to be reasonably low in cost with high performance and easily interfaced to a MCU. Some of the other solutions are prohibitively expensive, even if they may work well. Also the solution I had in mind had to be fairly small and use up little space and use up little power too. So when Analog Devices recently came out with their ADXRS150 and ADXRS300 piezo-gyroscope integrated circuit, I now had a solution that had low cost and low power with high performance too. The gyro is very small at about 5mm square (about 0.3 inches square). You can see the small combo gyro PCB mounted vertically in the center section on the balancing robot photo below.
I also took advantage of the small size and combined an Analog Devices accelerometer integrated circuit on the same PCB to maximize performance. Plus there are no moving parts per se to complicate the issue. All the good stuff is contained inside the chips. Using the two Analog Devices ADXRS150 and ADXL202 we can build a combo PCB for under $100.00 in parts. In this case at the Analog Devices web site, they are selling the gyro for about $39.90 in singles and the accelerometer for about $29.90 in singles. I know that the Express PCB service charges about $62 for three mini-boards, so one board costs about $20, then we have about $20 for all the other parts, since the PCB uses up only a small portion of the whole PCB blank, you can put in a few other needed layouts for other things on the same PCB and cut them out later as you need them. I usually use a scroll saw to cut out the small PCBs. In some cases you could obtain samples of these chips, or as they start to fill in the vendor pipeline, you'll be able to get them at better prices through the vendors and distributors.
Microstrain sells a number of different gyro modules starting at $295 up to around $1495.
The old classic approach is to obtain RC hobby model aircraft gyros and use them. These gyros run in cost from about $69.00 on up to several hundred dollars, depending on the model or type. A source to check out is Tower Hobbies or maybe a RC specialty store like Helicopter World. Sometimes Servo City has RC model plane Gyros too.
Then the most basic method is to use a potentiometer with a pole or pendulum attached to it. You feed the wiper output from the potentiometer to an ADC and then you can determine your position or tilt angle. This is the standard classic approach to balancing robots that balance a pole on top of them. But you could invert it as well. Usually you would still have to have some kind of a reference to the floor or tabletop for the robot to know where the floor is. But you could trail a potentiometer with a small arm touching the floor behind the robot for this purpose as well.
Although a RC hobby gyroscope is cost effective, it is a bit difficult to interface to a MCU. The gyro is designed for RC model airplane servos that work with a 1 to 2ms-width pulse train. Thus 1.5ms is neutral, 1ms full one way and 2ms full the other way. Using a MCU you have to transmit the 1.5ms neutral signal to the gyro, then receive the pulses from the gyro and translate them into something more meaningful for you to use. The next problem is you basically have to have the MCU stop for up to 2ms to read a pulse width, before you can do something with it. Depending on the MCU you might have to have the MCU send the the 1.5ms pulse as well, eating up even more time. That 2ms may be very critical to other things going on. But if we use the gyro chip, we can use a ADC (analog digital converter) to convert the analog voltage level to a numerical value much faster, plus you could, in some cases, start the ADC to get a value, and come back later for the result. We can now reduce the time to get a numerical value down to microseconds instead of milliseconds. Thus we get better accuracy, and faster performance. If you use a high performance DSP processor, you may be able to get this down to less than a microsecond to read a voltage level.
The more expensive gyroscope systems, unfortunately, tend to be prohibitively expensive. So although they are really neat solutions, I didn't pursue them any further.
Without going into all the engineering gobblygook, the basic way the ADXRS150 or 300 gyroscope IC's work, is they output a 2.5 volt level at rest. If the gyro is tilted one way or the other, then it will output up to a +/- voltage change from reference. This is an analog level that you need to feed into an analog digital converter (ADC) for a MCU to use. The ADXRS150 has about a 12.5mv per degree of sensitivity, for up to about 150 degrees per second of tilting. This can be adjusted some more as needed too. The voltage change is proportional to the speed or rate of the tilt angle. The faster the robot tilts the larger the change in voltage. The ADXRS300, as a higher performance device, gives about 300 degrees per second of tilting.
The following sequence of photos illustrate the voltage change when the gryo is titled. (the photos are an exaggeration as I couldn't tilt and snap the photo fast enough)
Above: Gryo is at rest
Above: Gryo titled forward
Above: Gryo titled backwards
This short MPEG video also shows the oscilliscope measurements of the gyro circuit at rest, tilted one way, and then tilted the other way.
If you want more information about the chips, please go to the Analog Devices website and download the spec sheets and documentation on the chips. Also get the documentation on the accelerometer evaluation board as well. I expect Analog Devices to have an evaluation board for the gyroscope IC pretty soon as well.
转载声明:凡文章出处为www.RoboticFan.com的,系本站的原创文章。其它媒体在注明出处为RoboticFan.com并给出原始链接后可以自由转载,否则将视为侵权!
| 上一篇:机器人技术介绍 下一篇:机器人——源自维基百科的定义(英) |







