Quote:
|
Originally Posted by chantilly_team
I realised that a lot you guys are advicing us to use a physical / mechanical sensor, but in the project, we need to have an electronic sensor of some kind, to measure distance. If that distance is more than or less a specific value (say 4 feet), then it should trigger something.
|
Your robot is going to be more than 4 feet from the ground? I'm curious to know what exactly you're trying to build here.
With a threshhold distance on the order of a meter, an ultrasonic rangefinder sounds fine for your application. You can find simple ones that give a digital output pulse proportional in length to the distance, requiring the controller to both initiate and measure that pulse (typically using interrupts), and you can find fancier and more expensive ones that constantly provide a nice analog voltage representing the distance. Search the web for "ultrasonic rangefinder" and you'll find lots to choose from.