Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
Status
Not open for further replies.

throbscottle

Well-Known Member
I was pondering it would be cool to create a, lets call it a "toy" and suppose it's a bear or a doll or something, which can detect passers by and turn it's head as though it's watching them. Ok maybe it's just creepy.
Is there some kind of sensor, or way of making a sensor, which can detect approximately where something is in 2 dimensions, without resorting to image processing or expensive radar type stuff?
I'm thinking something like a line of IR sensors with a narrow angle of view, kind of like an inside out PIR sensor. Maybe that could translate to a voltage ramp up or down depending on direction.
Any thoughts on this, or maybe a better way?
 
The Sharp proximity sensors might be a solution. Might need to sweep it on a servo and use a pic to find nearest point.

Mike.
 
Should be possible with an ultrasonic transmitter with two receivers. Send a pulse, and then compare the timing between the return signal in both receivers
 
Mike: I'll investigate, never heard of them.
Dougy: sounds like a really good solution. Now I just need to learn a whole bunch of new stuff!
 
If you take a standard rc servo, pull the feedback pot, then replace the pot with 2 x photresistors wired in series with the cenre going to what was the pot wiper, then connect the servo to a servo tester you'll have a light seeker, the servo will try and position itself so the photocells have the same resistance or light falling on them (if the servo tester is centred), putting the photocells in long tubes will make them directional. Obviously it wornt work in a dark room.
Putting thw photcells on one way round would make the bot 'look' away from you and the other would look at you.
 
Last edited:
Would it be sensitive enough, do you think, to detect a passer-by 2 or 3 meters away? Definitely the most straightforward idea if it will work!

And there was me going down the ultra-sound route and contemplating that I would need a phase-discriminator (or something like that) and wondering how to implement it!

It also occurred to me that it could have range sensitivity (if that's the right term), so if you get within a certain distance it puts up one hand, then the other, and finally looks away. One thing at a time though...
 
I've never tried it so I dont kmow, I stole the idea from someone who did this to build a solar tracker and it worked well, servo's tend to be very accurate so I'm inclined to say it will work well.
The drawback however would be the light level, the feedback pot in a servo is probably about 10k, the ambient light on the photocells would need to be bright enough to be similar, the input impedance of the servo chip will start to dominate and mess things up under a certain light level.

Easiest way to do it disceretly is 2 mic's, the mic triggers a 555 for 0.1 sec or so, one 555 triggers a h bridge or relay for the motor to go one way, and the other vice versa, nad you need to reset one 555 from the other so they both dont trigger at the same time and short the supply.
 
Easiest way to do it disceretly is 2 mic's, the mic triggers a 555 for 0.1 sec or so, one 555 triggers a h bridge or relay for the motor to go one way, and the other vice versa, nad you need to reset one 555 from the other so they both dont trigger at the same time and short the supply.
Oh of course. I would never have thought of that! Much easier!
Interesting, cheaper to buy ultrasonic rangefinder modules off fleabay than it is to buy the individual transducers. So annoying. Oh no I stand corrected, I can get 2 pairs for £1.55.
Though I'm now thinking the same thing would work with IR transmit/receive LED's
I see servo's are pretty cheap, and I have some old LDR's so I can play with that route.
 
If you configure a 555 as an astable you can use that to trigger the ping i/p on both ultrasound modules, then use the reflection o/p from the 2 modules to trigger the 555's at 0.1 sec to operate the 2 motors as above.
This doesnt take distance into account, but you dont really need to, all you need is the motor to turn the device towards the echo.
The only problem with modules like the sr04 is that range is usuall a lot less than a meter, I'dve thought you'd need 3 meters or more.
 
Yeah, I was thinking at least 5 meters.
I thought that old TV remotes which were ultrasonic had a good range - mind you I suppose the returning signal is a small reflection of the original. If I just get the transducers on their own I could amp up the output of the receivers though.
 
You can still get the receiver/detector units, but its probably cheaper to get a sr04 module off ebay which has them and a microcontroller allready onboard, if you dont use the module you could pull the transducers off.
Another source if you have any connection with vehicles is car security systems, cars from the late 90's on often have a ultrasonic transducers at the top of the a pillar by the sun visor, you can just snip them off a junker, they are normally shoved into the trim with a kinda tie clip gizmo.
 
True, the "2 pairs" listing has changed price.
No chance of getting any off a vehicle!

I suppose the thing to do now is get some bits and get experimenting. Thanks for the help :)
 
Dont forget a youtube vid when you've gorrit working.
 
My hearing aids turn my head to the person speaking the loudest on one of its settings.
It has microphones for left front, right front, left rear and right rear.
It gets confused and I also get confused sometimes when the person over there is louder than the person over here.

Our ears do not have front and rear sensors so I guess front and rear sounds produce a different frequency response that is copied by my hearing aids.
 
It's really remarkable how you can tell how sounds are behind you. Never thought about it before today!
 
Fascinating. But I have just ordered 2 ultrasonic modules (the 700mm ones) servos and 556 dual timers. I'll see if one of the modules can be used as it is, I'll just take the raw pulse output instead of the range output. That way I can still also use it's rangefinding to get the near distance reactions (raise hand, look away). I'll just hack the other one to work as receive only.
 
Thats interesting.
Vehicle parking sensors work as rx/tx on each sensor, but if the range is really close they switch to tx on one and rx on the other, as it takes a while for the ultrasonic tx to stop vibrating and producing ultrasound after the tx cycle has finished, limiting the minimum range.
Theres a couple of ic's on those ultrasound ranging boards, ones probably an op amp wired to the rx cell, so probably one of the pins on said op amps goes to a logic 1 when the cell 'hears' something, giving you the hack signal point.
 
5 m is a loooong way away for any sensor without a well-tuned lens. Worse for ultrasonics, 10 m round trip. +/-10 degrees of arc (a tight window for an IR phototransistor) is 1.7 m at 5 m distance. Yes, you can detect the relative signal strengths to a pretty fine resolution, but how much with the target be obscured by ambient effects? Is this for indoor or outdoor use?

ak
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top