1. Trang chủ
  2. » Kỹ Thuật - Công Nghệ

McGraw-Hill - The Robot Builder''''s Bonanza Episode 2 Part 9 pps

35 311 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 35
Dung lượng 452,52 KB

Các công cụ chuyển đổi và chỉnh sửa cho tài liệu này

Nội dung

informa-From Here Using a brain with your robot Chapter 28, “An Overview of Robot ‘Brains’” Connecting sensors to a robot Chapter 29, “Interfacing with Computers and computer or microcon

Trang 1

sound to quickly and efficiently navigate through dark caves So accurate is their “sonar”that bats can sense tiny insects flying a dozen or more feet away.

Similarly, robots don’t always need light-sensitive vision systems You may want to sider using an alternative system, either instead of or in addition to light-sensitive vision.The following sections outline some affordable technologies you can easily use

con-ULTRASONICS

Like a cave bat, your robot can use high-frequency sounds to navigate its surroundings.Ultrasonic transducers are common in Polaroid instant cameras, electronic tape-measuringdevices, automotive backup alarms, and security systems All work by sending out a high-fre-quency burst of sound, then measuring the amount of time it takes to receive the reflected sound

FIGURE 37.14 When projected onto a flat surface, the beams

from the diffracted laser light form a regular grid.

FIGURE 37.13 A penlight laser,

diffraction ing, filter, and video camera can be used to create a low- cost machine vision system.

Trang 2

grat-Ultrasonic systems are designed to determine distance between the transducer and anobject in front of it More accurate versions can “map” an area to create a type of topo-graphical image, showing the relative distances of several nearby objects along a kind of3-D plane Such ultrasonic systems are regularly used in the medical field Some trans-ducers are designed to be used in pairs—one transducer to emit a series of short ultrason-

ic bursts, another transducer to receive the sound Other transducers, such as the kind used

on Polaroid cameras and electronic tape-measuring devices, combine the transmitter andreceiver into one unit

An important aspect of ultrasonic imagery is that high sound frequencies disperse lessreadily than do low-frequency ones That is, the sound wave produced by a high-frequen-

cy source spreads out much less broadly than the sound wave from a low-frequency source.This phenomenon improves the accuracy of ultrasonic systems Both DigiKey and AllElectronics, among others, have been known to carry new and surplus ultrasonic compo-nents suitable for robot experimenters See Chapters 36 and 38 for more information onusing ultrasonic sensors to guide your robots

RADAR

Radar systems work on the same basic principle as ultrasonics, but instead of quency sound they use a high-frequency radio wave Most people know about the high-powered radar equipment used in aviation, but lower-powered versions are commonly used

high-fre-in security systems, automatic door openers, automotive backup alarms, and of course,speed-measuring devices used by the police

Radar is less commonly found on robotics systems because it costs more than sonics But radar has the advantage that radar it is less affected by wind, temperature, anddistance For example, radar can be used up to several miles away; ultrasonics is usefulonly up to about 10 or 20 meters

The typical PIR sensor is equipped with a Fresnel lens to focus infrared light from afairly wide area onto the pea-sized surface of the detector In a robotics vision application,you can replace the Fresnel lens with a telephoto lens arrangement that permits the detec-tor to view only a small area at a time Mounted onto a movable platform, the sensor coulddetect the instantaneous variations of infrared radiation of whatever objects are in front ofthe robot See Chapter 36, “Collision Avoidance and Detection,” for more information onthe use of PIR sensors

Trang 3

robot knows it has touched some object in front of it Based on this information, the robotcan stop and negotiate a different path to its destination.

To be useful, the robot’s touch sensors must be mounted where they will come into tact with the objects in their surroundings For example, you can mount four switchesalong the bottom periphery of a square-shaped robot so contact with any object will trig-ger one of the switches Mechanical switches are triggered only on physical contact;switches that use reflected infrared light or capacitance can be triggered by the proximity

con-of objects Noncontact switches are useful if the robot might be damaged by running into

an object, or vice versa See Chapter 35, “Adding the Sense of Touch,” for more tion on tactile sensors

informa-From Here

Using a brain with your robot Chapter 28, “An Overview of Robot ‘Brains’”

Connecting sensors to a robot Chapter 29, “Interfacing with Computers and computer or microcontroller Microcontrollers”

Using touch to guide your robot Chapter 35, “Adding the Sense of Touch”

Getting your robot from point Chapter 38, “Navigating through Space”

A to point B

Trang 4

The projects and discussion in this chapter focus on navigating your robot throughspace—not the outer-space kind, but the space between two chairs in your living room,between your bedroom and the hall bathroom, or outside your home by the pool Robotssuddenly become useful once they can master their surroundings, and being able to wendtheir way through their surrounds is the first step toward that mastery.

The techniques used to provide such navigation are varied: path-track systems, infraredbeacons, ultrasonic rangers, compass bearings, dead reckoning, and more

A Game of Goals

A helpful way to look at robot navigation is to think of it as a game, like soccer The aim

of soccer is for the members of one team to kick the ball into a goal That goal is guarded

by a member of the other team, so it’s not all that easy to get the ball into the goal.Similarly, for a robot a lot stands between it and its goal of getting from one place to anoth-

er Those obstacles include humans, chairs, cats, a puddle of water, an electrical cord—justabout anything can prevent a robot from successfully traversing a room or yard

To go from point A to point B, your robot will consider the following process (as shown

Trang 5

1. Retrieve instruction of goal: get to point B This can come from an internal stimulus(battery is getting low; must get to power recharge station) or from a programmed orexternal command.

2. Determine where point B is in relation to current position (point A), and determine apath to point B This requires obtaining the current position using known landmarks orreferences

3. Avoid obstacles along the way If an immovable obstacle is encountered, move aroundthe obstacle and recalculate the path to get to point B

Go to Point B

Locate Point B

Obstacle in way?

Move around obstacle

No Yes

Read wheel odometers

Errors in travel?

No

Yes Correct for

FIGURE 38.1 Navigation through open space requires

that the robot be programmed not only to achieve the “goal” of a specific task but to self-correct for possible obstacles.

Trang 6

4. Correct for errors in navigation (“in-path error correction”) caused by such things aswheel slippage This can be accomplished by periodically reassessing current positionusing known landmarks or references.

5. Optionally, time out (give up) if goal is not reached within a specific period of time ordistance traveled

Notice the intervening issues that can retard or inhibit the robot from reaching its goal

If there are any immovable obstacles in the way the robot must steer around them Thismeans its predefined path to get from point A to point B must be recalculated Position andnavigation errors are normal and are to be expected You can reduce the effects of error byhaving the robot periodically reassess its position This can be accomplished by using anumber of referencing schemes, such as mapping, active beacons, or landmarks Moreabout these later in the chapter

People don’t like to admit failure, but a robot is just a machine and doesn’t know (orcare) that it failed to reach its intended destination You should account for the possibilitythat the robot may never get to point B This can be accomplished by using time-outs,which entails either determining the maximum reasonable time to accomplish the goal or,better yet, the maximum reasonable distance that should be traveled to reach the goal.You can build other fail-safes into the system as well, including a program override ifthe robot can no longer reassess its current location using known landmarks or references

In such a scenario, this could mean its sensors have gone kaput or that the landmarks orreferences are no longer functioning or accurate One course of action is to have the robotshut down and wait to be bailed out by its human master

Following a Predefined Path: Line Tracing

Perhaps the simplest navigation system for mobile robots involves following some fined path that’s marked on the ground The path can be a black or white line painted on ahard-surfaced floor, a wire buried beneath a carpet, a physical track, or any of several othermethods This type of robot navigation is used in some factories The reflective tapemethod is preferred because the track can easily be changed without ripping up the floor.You can readily incorporate a tape-track navigation system in your robot The line-trac-ing feature can be the robot’s only means of semi-intelligent action, or it can be just onepart of a more sophisticated machine You could, for example, use the tape to help guide arobot back to its battery charger nest

prede-With a line-tracing robot, you place a piece of white or reflective tape on the floor Forthe best results, the floor should be hard, like wood, concrete, or linoleum, and not carpet-

ed One or more optical sensors are placed on the robot These sensors incorporate aninfrared LED and an infrared phototransistor When the transistor turns on it sees the lightfrom the LED reflected off the tape Obviously, the darker the floor the better because thetape shows up against the background

In a working robot, mount the LED and phototransistors in a suitable enclosure, asdescribed more fully in Chapter 36, “Collision Avoidance and Detection.” Or, use a

FOLLOWING A PREDEFINED PATH: LINE TRACING 621

Trang 7

commercially available LED-phototransistor pair (again, see Chapter 36) Mount thedetectors on the bottom of the robot, as shown in Fig 38.2, in which two detectors havebeen placed a little farther apart than the width of the tape I used 1/4-inch art tape in theprototype for this book and placed the sensors 1/2 inch from one another.

Fig 38.3 shows the basic sensor circuit and how the LED and phototransistor are wired.Feel free to experiment with the value of R2; it determines the sensitivity of the photo-transistor Fig 38.4 shows the sensor and comparator circuit that forms the basis of theline-tracing system Refer to this figure often because this circuit is used in many otherapplications

You can use the schematics in Fig 38.5 and Fig 38.6 to build a complete line-tracingsystem (refer to the parts lists in Tables 38.1 and 38.2) You can build the circuit using justthree IC packages: an LM339 quad comparator, a 7486 quad Exclusive OR gate, and a

7400 quad NAND gate Before using the robot, block the phototransistors so they don’treceive any light Rotate the shaft of the set-point pots until the relays kick in, then back

White or reflective strip on ground

Front view

Left LED-Phototransistor

Right LED-Phototransistor

FIGURE 38.2 Placement of the left and right phototransistor-LED

pair for the line-tracing robot.

+5V

R2 10K R1

FIGURE 38.3 The basic

LED-photo-transistor wiring gram.

Trang 8

dia-FOLLOWING A PREDEFINED PATH: LINE TRACING 623

5

2

R2 10K

R3 10K

R1 270Ω

R4 10K

FIGURE 38.4 Connecting the LED and phototransistor to an LM339

quad comparator IC The output of the comparator switches between HIGH and LOW depends on the amount of light falling on the phototransistor Note the addition of the 10K “pullup” resistor on the output of the comparator This is needed to assure proper HIGH/LOW action.

5

2

12 3

1

2 3

4 5 6

R2 10K R1

R5 10K +5V

R6 10K

R7 10K

R8 10K

FIGURE 38.5 Wiring diagram for the line-tracing robot The outputs of the 7400 are

rout-ed to the relays in Figure 38.6.

Trang 9

RL1

M1

D1 1N4003

+V

+5V

From Detector # 1

From Detector# 2

FIGURE 38.6 Motor direction and control relays for the line-tracing

robot You can substitute the relays for purely

electron-ic control; refer to Chap 18.

TABLE 38.1 PARTS LIST FOR LINE TRACER.

IC1 LM339 Quad Comparator ICIC2 7486 Quad Exclusive OR Gate ICIC3 7400 Quad NAND Gate ICQ1,Q2 Infrared-sensitive phototransistorsR1,R4 270-ohm resistor

R2,R5,R7,R8 10K resistorR3,R6 10K potentiometerLED1,2 Infrared light-emitting diodeMisc Infrared filter for phototransistor (if needed)

All resistors are 5–10% tolerance.

TABLE 38.2 PARTS LIST FOR RELAY CONTROL.

RL1,RL2 DPDT fast-acting relay; contacts rated 2 amps or moreD1, D2 1N4003 diodes

Trang 10

off again You may have to experiment with the settings of the set point pots as you try outthe system.

Depending on which motors you use and the switching speed of the relays, you mayfind your robot waddling its way down the track, overcorrecting for its errors every time.You can help minimize this by using faster-acting relays Another approach is to vary thegap between the two sensors By making it wide, the robot won’t be turning back and forth

as much to correct for small errors I have also found that you can minimize this so-called

overshoot effect by carefully adjusting the set-point pots.

You’ll hardly ever see a railroad track with a turn tighter than about 8° There is goodreason for this If the turn is made any tighter, the train cars can’t stay on the track, and thewhole thing derails There is a similar limitation in line-tracing robots The lines cannot betighter than about 10° to 15°, depending on the robot’s turning radius, or the thing can’tact fast enough when it crosses over the line The robot will skip the line and go off course.The actual turn radius will depend entirely on the robot If you need your robot to turnvery tight, small corners, build it small If your robot has a brain, whether it is a computer

or central microprocessor, you can use it instead of the direct connection to the relays formotor control The output of the comparators, when used with a 5 volt supply, is compat-ible with computer and microprocessor circuitry, as long as you follow the interface guide-lines provided in Chapter 29 The two sensors require only two bits of an eight-bit port

Wall FollowingRobots that can follow walls are similar to those that can trace a line Like the line, the wall

is used to provide the robot with navigation orientation One benefit of wall-followingrobots is that you can use them without having to paint any lines or lay down tape.Depending on the robot’s design, the machine can even maneuver around small obstacles(doorstops, door frame molding, radiator pipes, etc.)

VARIATIONS OF WALL FOLLOWING

Wall following can be accomplished with any of four methods:

Contact The robot uses a mechanical switch, or a stiff wire that is connected to a switch, to sense contact with the wall, as shown in Fig 38.7a This is by far the simplest

method, but the switch is prone to mechanical damage over time

Noncontact, active sensor The robot uses active proximity sensors, such as infrared or

ultrasonic, to determine its distance from the wall No physical contact with the wall isneeded In a typical noncontact system, two sensors are used to judge when the robot is

parallel to the wall (see Fig 38.7b).

Noncontact, passive sensor The robot uses passive sensors, such as linear Hall effect switches, to judge distance from a specially prepared wall (Fig 38.7c) In the case of

Hall effect switches, you could outfit the baseboard or wall with an electrical wirethrough which a low-voltage alternating current is fed When the robot is in the prox-imity of the switches the sensors will pick up the induced magnetic field provided by

WALL FOLLOWING 625

Trang 11

the alternating current Or, if the baseboard is metal the Hall effect sensor (when riggedwith a small magnet on its opposite side) could detect proximity to a wall.

“Soft-contact.” The robot uses mechanical means to detect contact with the wall, but the

contact is “softened” by using pliable materials For example, you can use a lightweight

foam wheel as a “wall roller,” as shown in Fig 38.7d The benefit of soft contact is that

mechanical failure is reduced or eliminated because the contact with the wall is madethrough an elastic or pliable medium

In all cases, upon encountering a wall the robot goes into a controlled program phase tofollow the wall in order to get to its destination In a simple contact system, the robot mayback up a short moment after touching the wall, then swing in a long arc toward the wallagain This process is repeated, and the net effect is that the robot “follows the wall.”With the other methods, the preferred approach is for the robot to maintain proper dis-tance from the wall Only when proximity to the wall is lost does the robot go into a “findwall” mode This entails arcing the robot toward the anticipated direction of the wall Whencontact is made, the robot alters course slightly and starts a new arc A typical pattern ofmovement is shown in Fig 38.8

Switch

Ultrasonic orinfrared

FIGURE 38.7 Ways to follow the wall include: a.

Contact switch; b Noncontact active sensor (such as infrared); c Noncontact

passive sensor (e.g., Hall effect sensor and magnetic, electromagnetic, or fer-

rous metal wall/baseboard); and d “Soft

contact” using pliable material such as foam rollers.

Trang 12

ULTRASONIC WALL FOLLOWING

A simple ultrasonic wall follower can use two ultrasonic transmitter/receiver pairs Each mitter and receiver is mounted several inches apart to avoid cross talk Two transmitter/receiv-

trans-er pairs are used to help the robot travel parallel to the wall Suitable ultrasonic transmitttrans-er andreceiver circuits are detailed in Chapter 36, “Collision Avoidance and Detection.”

Because the robot will likely be close to the wall (within a few inches), you will want

to drive the transmitters at very low power and use only moderate amplification, if any, forthe receiver You can drive the transmitters at very low power by reducing the voltage tothe transmitter

WALL FOLLOWING 627

Wall

FIGURE 38.8 A wall-following robot that merely

“feels” its way around the room might make wide, sweeping arcs The arc movement is easily accomplished in a typical two- wheeled robot by running one motor slower than the other.

Trang 13

SOFT-CONTACT FOLLOWING WITH FOAM WHEEL

Soft-contact wall following with a roller wheel offers you some interesting possibilities Infact, you may be able to substantially simplify the sensors and control electronics by plac-ing an idler roller made of soft foam as an outrigger to the robot and then having the robotconstantly steer inward toward the wall This can be done simply by running the inwardwheel (the wheel on the side of the wall) a little slower than the other The foam idler rollerwill prevent the robot from hitting the wall

DEALING WITH DOORWAYS AND OBJECTS

Merely following a wall is, in essence, not that difficult The task becomes more lenging when you want the robot to maneuver around obstacles or skip past doorways Thisrequires additional sensors, perhaps whiskers or other touch sensors in the forward portion

chal-of the robot These are used to detect corners as well This is especially important whenyou are constructing a robot that has a simple inward-arc behavior toward following walls.Without the ability to sense a wall straight ahead, the robot may become hopelessly trapped

in a corner

Open doorways that lead into other rooms can be sensed using a longer-range

ultrason-ic transducer Here, the long-range ultrasonultrason-ic detects that the robot is far from any wall andplaces the machine in a “go straight” mode Ideally, the robot should time the duration ofthis mode to account for the maximum distance of an open doorway If a wall is not detect-

ed within X seconds, the robot should go into a “look for wall” mode

Odometry: The Art of Dead ReckoningHop into your car Note the reading on the odometer Now drive straight down the road forexactly one minute, paying no attention to the speedometer or anything else (of course,keep your eyes on the road!) Again note the reading on the odometer The information onthe odometer can be used to tell you where you are Suppose it says one mile You knowthat if you turn the car around exactly 180° and travel back one mile, at whatever speed,you’ll reach home again

This is the essence of odometry, reading the motion of a robot’s wheels to determinehow far it’s gone Odometry is perhaps the most common method for determining where

a robot is at any given time It’s cheap and easy to implement and is fairly accurate overshort distances Odometry is similar to the “dead reckoning” navigation used by sea cap-tains and pilots before the age of satellites, radar, and other electronic schemes Hence,odometry is also referred to in robot literature as dead reckoning

Unlike your car, robots don’t have speedometers connected to their transmissions

or front wheels to drive the odometer Instead, a robot’s “odometer” is typically devised using optical or magnetic sensors Let’s take a look at how each kind is used in

a robot

Trang 14

OPTICAL ENCODERS

You can use a small disc fashioned around the hub of a drive wheel, or even the shaft of adrive motor, as an optical shaft encoder (described in “Anatomy of a Shaft Encoder,” inChapter 18) The disc can be either the reflectance or the slotted type:

With a reflectance disc, infrared light strikes the disc and is reflected back to a

pho-todetector

With a slotted disc, infrared light is alternately blocked and passed and is picked up on

the other side by a photodetector

With either method, a pulse is generated each time the photodetector senses the light

MAGNETIC ENCODERS

You can construct a magnetic encoder using a Hall effect switch (a semiconductor tive to magnetic fields) and one or more magnets A pulse is generated each time a mag-net passes by the Hall effect switch A variation on the theme uses a metal gear and a spe-cial Hall effect sensor that is sensitive to the variations in the magnetic influence produced

sensi-by the gear (see Fig 38.9)

A bias magnet is placed behind the Hall effect sensor A pulse is generated each time atooth of the gear passes in front of the sensor The technique provides more pulses on eachrevolution of the wheel or motor shaft, and without having to use separate magnets on therim of the wheel or wheel shaft

THE FUNCTION OF ENCODERS IN ODOMETRY

As the wheel or motor shaft turns, the encoder (optical or magnetic) produces a series ofpulses relative to the distance the robot travels Assume the wheel is 3 inches in diameter(9.42 inches in circumference), and the encoder wheel has 32 slots Each pulse of theencoder represents 0.294 inches of travel (9.42/32) If the robot senses 10 pulses, it knows

it has moved 2.94 inches

If the robot uses the traditional two-wheel drive approach, you attach optical encoders

to both wheels This is necessary because the drive wheels of a robot are bound to turn at

ODOMETRY: THE ART OF DEAD RECKONING 629

Hall effect sensor

Ferrous metal gear

Bias magnet

FIGURE 38.9 A Hall effect sensor

outfitted with a small “bias” mag- net and sensitive to the changes in magnetic flux caused by a rotat- ing ferrous metal gear.

Trang 15

slightly different speeds over time By integrating the results of both optical encoders, it’spossible to determine where the robot really is as opposed to where it should be (see Fig.38.10) As well, if one wheel rolls over a cord or other small lump, its rotation will be hin-dered This can cause the robot to veer off course, possibly by as much as 3° to 5° or more.Again, the encoders will detect this change.

It’s best to make odometry measurements using a microcontroller that is outfitted with

a pulse accumulator or counter input These kinds of inputs independently count the

num-ber of pulses received since the last time they were reset To take an odometry reading, youclear the accumulator or counter and then start the motors Your software need not moni-tor the accumulator or counter Stop the motors, and then read the value in the accumula-tor or counter Multiply the number of pulses by the known distance of travel for eachpulse (This will vary depending on the construction of your robot; consider the diameter

of the wheels and the number of pulses of the encoder per revolution.)

If the number of pulses from both encoders is the same, you can assume that the robot eled in a straight line, and you have only to multiple the number of pulses by the distance perpulse For example, if there are 1055 pulses in the accumulator-counter, and if each pulse rep-resents 0.294 inches of travel, then the robot has moved 310.17 inches straight forward

trav-ERRORS IN ODOMETRY

In a perfect world, robots would not need anything more than an odometer to determineexactly where they were at any given time Unfortunately, robots live and work in a worldthat is far from perfect; as a result, their odometers are far from accurate Over a 20- to 30-foot range, for example, it’s not uncommon for the average odometer to misrepresent theposition of the robot by as much as half a foot or more!

Why the discrepancy? First and foremost: wheels slip As a wheel turns, it is bound toslip, especially if the surface is hard and smooth, like a kitchen floor Wheels slip even

Obstacle underone wheel

FIGURE 38.10 The relative number of

“counts” from each encoder of the typical two- wheeled robot can be used

to indicate deviation in travel If an encoder shows that one wheel turned a fewer number of times than the other wheel, then

it can be assumed the robot did not travel in a straight line.

Trang 16

more when they turn The wheel encoder may register a certain number of pulses, butbecause of slip the actual distance of travel will be less Certain robot drive designs aremore prone to error than others Robots with tracks are steered using slip—lots of it Theencoders will register pulses, but the robot will not actually be moving in proportion.There are less subtle reasons for odometry error If you’re even a hundredth of an inchoff when measuring the diameter of the wheel, the error will be compounded over long dis-tances If the robot is equipped with soft or pneumatic wheels, the weight of the robot candeform the wheels, thereby changing their effective diameter.

Because of odometry errors, it is necessary to combine it with other navigation niques, such as active beacons, distance mapping, or landmark recognition All three aredetailed later in this chapter

tech-Compass BearingsBesides the stars, the magnetic compass has served as humankind’s principal navigationaid over long distances You know how it works: a needle points to the magnetic north pole

of the earth Once you know which way is north, you can more easily reorient yourself inyour travels

Robots can use compasses as well, and a number of electronic and electromechanicalcompasses are available for use in hobby robots One of the least expensive is theDinsmore 1490, from Dinsmore Instrument Co The 1490 looks like an overfed transistor,with 12 leads protruding from its underside The leads are in four groups of three; eachgroup represents a major compass heading: north, south, east, and west The three leads ineach group are for power, ground, and signal A Dinsmore 1490, mounted on a circuitboard, is shown in Fig 38.11

The 1490 provides eight directions of heading information (N, S, E, W, SE, SW, NE,NW) by measuring the earth’s magnetic field It does this by using miniature Hall effectsensors and a rotating compass needle (similar to ordinary compasses) The sensor is said

to be internally designed to respond to directional changes much like a liquid-filled pass It turns to the indicated direction from a 90° displacement in approximately 2.5 sec-onds The manufacturer’s specification sheet claims that the unit can operate with up to 12°

com-of tilt with acceptable error, but it is important to note that any tilting from center willcause a corresponding loss in accuracy

Fig 38.12 shows the circuit diagram for the 1490, which uses four inputs to a

comput-er or microcontrollcomput-er Note the use of pullup resistors With this setup, your robot candetermine its orientation with an accuracy of about 45° (less if the 1490 compass is tilted).Dinsmore also makes an analog-output compass that exhibits better accuracy

Another option is the Vector 2X and 2XG These units use magneto-inductive sensorsfor sensing magnetic fields The Vector 2X/2XG provides either compass heading oruncalibrated magnetic field data This information is output via a three-wire serial formatand is compatible with Motorola SPI and National Semiconductor Microwire interfacestandards Position data can be provided either 2.5 or 5 times per second

Vector claims accuracy of ±2° The 2X is meant to be used in level applications Themore pricey 2XG has a built-in gimbal mechanism that keeps the active magnetic-inductiveelement level, even when the rest of the unit is tilted The gimbal allows tilt up to 12°

COMPASS BEARINGS 631

Trang 17

FIGURE 38.11 The Dinsmore 1490 digital compass provides simple bearings

for a robot The sensor is accurate to about 45°.

1

2 3 +5 vdc

Output 10K

1 2 3

1 2 3

1 2

1

3

1=+V 2=Gnd 3=Output

FIGURE 38.12 Circuit diagram for using the

Dinsmore 1490 digital compass.

When used with a 5 vdc supply, the four outputs can be connected directly to a microcontroller One or two outputs can be activated at a time; if two are activated, the sensor

is reading between the four pass points (e.g., N and W outputs denotes NW position).

Ngày đăng: 10/08/2014, 04:22

TỪ KHÓA LIÊN QUAN