Distance Sensors
380 likes | 807 Vues
Distance Sensors. Kyle Zhang Jeff Peil Kristian Kalaj. Agenda. How Ultrasonics Work. Uses a transducer to convert electrical energy into higher frequency sound waves (ultrasonic) When the echo of the emitted waves returns, it converts the sound back into electrical energy and evaluates.
Distance Sensors
E N D
Presentation Transcript
Distance Sensors Kyle Zhang Jeff Peil Kristian Kalaj
How Ultrasonics Work • Uses a transducer to convert electrical energy into higher frequency sound waves (ultrasonic) • When the echo of the emitted waves returns, it converts the sound back into electrical energy and evaluates http://www.education.rec.ri.cmu.edu/products/nxt_video_trainer2/resources/helpers/nxt_sensors/ultrasonic.html
How We Used Ultrasonics In Lab • A signal is raised high when the sound is sent • The same signal is lowered when the sensor receives the echo of that sound • Counted the # of clock cycles the signal was high to calculate distance
Another Way to Interface with Ultrasonics • An ultrasonic sensor uses the IN/OUT port of an FPGA • Requirements of a typical sensor • 5 volt power supply and ground • One pin from the FPGA that has the ability to work as input and output (example: GPIO)
Things to Be Careful About • Limited Range • ex: 28015-ND sensor is 20mm-3m • Mechanical Echo • Must be filtered out for data to be accurate
Things to Be Careful About (cont.) • Since we are reflecting a sound wave, certain materials may not reflect as well • Density • Sound absorption • Shape of a surface may affect reflection/detection • Sphere • Angles http://www.societyofrobots.com/member_tutorials/node/71
Examples of Ultrasonic Sensors • RB-Dfr-11 • Price: $14.50 • Range: 4 cm to 5m http://www.robotshop.com/media/files/pdf/datasheet-sen0001.pdf • 28015-ND • Price: $29.99 • Range: 20 mm to 3 m http://www.digikey.com/product-detail/en/28015/28015-ND/1774419 • US-T50/R25 • Price: $300 • Range: 0 - 50 cm http://www.wolfautomation.com/assets/15/US-T50R25.pdf
How IR Sensors Work • Emits beam of infrared light, detects reflection • Susceptible to quantity of light in environment • Measures angle of reflection, not time • Outputs an appropriate voltage to represent the distance, but not always http://www.societyofrobots.com/member_tutorials/node/71
IR Behavior Problems • Bad behavior for very close objects • After ‘initial spike,’ non-linear behavior then linear behavior • https://engineering.purdue.edu/ece477/Webs/S11-Grp03/nb/myersar.html
How to Deal with Bad Behavior • Make it stand in the corner! • But seriously…… • Reposition sensor to compensate
Types of IR Sensors • Different Types • Binary/Proximity • Outputs either high or low • Cheap • Good at detecting proximity/threshold • Multiple Bit/Ranging • Output actual distance from sensor • Analog or digital format • More expensive but still relatively cheap
Examples of IR Sensors • TSOP38238 • Price: $1.95 • Range: N/A http://www.adafruit.com/products/157#Description • SHARP GP2Y0A21YK0F • Price: $11.75 • Range: 10cm - 80cm http://www.robotshop.com/en/sharp-gp2y0a21yk0f-ir-range-sensor.html • SHARP GP2Y0A02YK • Price: $15.95 • Range: 20 cm-150 cm http://www.adafruit.com/products/1031?gclid=CKemybT7t7oCFeYWMgod1XgAHQ
IR Pros and Cons • Pros • Cheap • Outputs voltage based on distance • Precise detection of objects • Cons • Outputs voltage based on distance • Non-linear behavior • Susceptible to light influences
Conclusion Ultrasonic vs. IR • Use Ultrasonics when: • You care about distance accuracy • There will be light influences • You have money to spend • Use IRs when: • You want to detect movement or thresholds • You are on a budget • You need precision in what you are detecting
Further Reading • Infrared vs. Ultrasonic • http://www.societyofrobots.com/member_tutorials/node/71 • Parallax Sensor and General Ultrasonic Usage Tips • http://dc254.4shared.com/doc/fiS_Vzyu/preview.htm • IR Tutorials • http://www.intorobotics.com/use-infraredir-sensors-tutorials/