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.

Ultrasonic Transducer Alarm

Status
Not open for further replies.
Without a filter, the transistor will turn on and turn off exactly like the gate does.
 
please ask questions.
I think that is what he was doing. No need to get snooty.

And as I stated, I was not sure about the formula. I found it on the net, it stated C as being speed of light, as wavelength formula is lambda x freq = C (speed of light) I can see the relationship.
Since Doppler works in the electro magnetic spectrum as well as sound. I am sure there may be several ways to calc doppler shift.
 
3) The speed of the person divided by the speed of sound in air (about 300 m/s) determines the Doppler shift. The round trip distance for the sound is actually increasing/decreasing at twice the rate of the person's movement. So if the person is moving at 1 m/s the Doppler shift is 2/300. Multiply this figure by 40 kHz and you have a shift (40,000*2/300), about 270 Hz. (1 m/s is probably the fastest you'll see someone move indoors; 0.05 m/s is probably a good lower bound, or 13 Hz.)

Isn't the doppler shift calculated as follows:

f_prime = f_0 (1/(1+v/c)) where v is speed of the person and c is speed of sound?
 
I think that is what he was doing. No need to get snooty.

And as I stated, I was not sure about the formula. I found it on the net, it stated C as being speed of light, as wavelength formula is lambda x freq = C (speed of light) I can see the relationship.
Since Doppler works in the electro magnetic spectrum as well as sound. I am sure there may be several ways to calc doppler shift.

c is the speed of light if your are dealing with light and speed of sound if you are dealing with sound... i think :)
 
Without a filter, the transistor will turn on and turn off exactly like the gate does.

Okay I understand that. And I am glad you brought this up (although I was going to bring it up after I sorted all of this preliminary understanding stuff first).

How do I keep the alarm on once it is triggered instead of just going on and off with the gate (as audioguru said). Is that what the filter is for?

I am leaving work now so I won't be on until later tonight but I am loving this discussion :)
 
Last edited:
I thought the XOR gate only outputed high when inputs differed and remained low when inputs were equal.
I see where you need more explanation. The XOR is fast and outputs the instantaneous state of the two signals. If the two signals are a different frequency, the waveform at the XOR output will vary between 0 (when the two signals are in phase) and 1 (when they are out of phase). At other times, the output will be 40 KHz of varying duty cycle.

The rate at which this variation occurs is the difference between the frequencies.

A low pass filter on the output of the XOR (at about 500 Hz) will stop the 40 kHz, leaving you with a sine wave equal to the difference between the frequencies.

If you then apply it to a high pass at about 20 Hz, then it will reject slowly occurring changes in the environment.

After the filtering, you have a sine wave that should contain only object movements. Apply it to a Schmitt trigger and you have something a micro can use.

I didn't look up the Doppler formula, just worked it out on a napkin, so yours is a lot better. Be sure to account for the two paths; I think that each would have its own shift.

Thanks for being more patient than I was.:eek:
 
The output of the Schmitt trigger is a digital signal at a frequency related to the speed of the moving object. I've assumed that you'll want to apply it to a PIC so that you can make some sense of it.

You'll want to reduce false triggers (don't trigger on a lone pulse), latch an alarm condition, drive your indicators, stop the alarm (maybe a coded keypad), etc.
 
Not to disparage what my esteem colleague Mneary has suggested, but I have issues with this whole concept, as I see it being a little more difficult than you may anticipate, as you have many things to take into account.

Would it not be simpler to simply detect the loss of your transmitted signal at the receive end as opposed to measuring shifts in frequency. Perhaps an IR light transmitter, and IR receive.

For example: Signal present, all is well and no alarm. Signal momentarily gone, circuit replies hey what gives? Sound alarm.

I think this would be a much easier approach. :)
 
They make baby wandering alarms that detect a loss of signal:
1) When the baby wanders 1m behind metal shelves.
2) When a group of people come by.
3) When the battery runs down.
 
Yes, there are many simpler ways... some are very good. I guess I got carried away with the Doppler idea.
 
Yes, there are many simpler ways... some are very good. I guess I got carried away with the Doppler idea.

It is really quite cool, but maybe for a more seasoned individual :)

What I mean is someone with more experience in electronics...
 
Last edited:
Yeah I have been drawing pictures all day trying to understand all these concepts. It is getting a little more complicated than I would like but I am still enjoying having to think really hard about all these things to make sure I understand how they work.

I have IR LED's and IR detector LED's. Which one would require more power? Also, wouldn't the IR solution not be good in well lit conditions (day time, indoor lights, etc.)?

The thing now is that I really want to understand how to use these ultrasonic transducers since it is becoming difficult to understand. I WILL NOT BE DEFEATED! The thing that bugs me is that there are circuits online (I believe someone posted one from that old magazine) that are not that complex. They only use transistors. How is it that these circuits work!? I think that now that we have traveled the "complex" path... lets try and head down a "simpler" path. With that said, let me start again:

So I have these ultrasonic transducers that I want to use to create an alarm. Anyone have a rough, very general idea of how I should go about doing this (no comparators, gates, or schmidtt stuff :)).
 
You can still use your Usonic devices. Send carrier from TX to RX. If someone walks by RX level drops below a threshold and triggers a person walking by condition.
It would be something like ~~~~~~----~~~~ where the dashes are break in carrier.

It would not be a mere go/no go condition as the soundwaves would be bouncing around, so you would have to look for a drop in RX signal level, rather than 1 or 0.

Something like that. Get what I mean?
 
You can still use your Usonic devices. Send carrier from TX to RX. If someone walks by RX level drops below a threshold and triggers a person walking by condition.
It would be something like ~~~~~~----~~~~ where the dashes are break in carrier.

It would not be a mere go/no go condition as the soundwaves would be bouncing around, so you would have to look for a drop in RX signal level, rather than 1 or 0.

Something like that. Get what I mean?

But will this work with a setup that has both usonic transducers on the same side? I do not want to have to put one pointing at the other. I want everything to be in one enclosure (one usonic transducer next to the other).
 
But will this work with a setup that has both usonic transducers on the same side? I do not want to have to put one pointing at the other. I want everything to be in one enclosure (one usonic transducer next to the other).

It could still work. You would have to shield tx from coupling to rx, then just detect reflected signal, and when it falls lower than static condition, someone has walked by.

Here is a basic functional block I came up with. it is by no means a design, just a concept drawing.
 

Attachments

  • Sonicalrm.jpg
    Sonicalrm.jpg
    19.6 KB · Views: 168
I just noticed something. This circuit that I was referring to that only uses transistors is used in a different configuration than what I want. The transducers are pointed at each other and when someone steps inbetween, the signal is interrupted. This is not what I want so maybe what I want is too much :rolleyes:

**broken link removed**
 
Well, maybe my first image was not clear, and I have never built such a thing, but you should be able to keep TX and RX in one unit. You will just have to test for smaller RX changes.

Assuming Signal has a wall or some such to reflect. I dunno.
 

Attachments

  • Sonicalrm1.gif
    Sonicalrm1.gif
    9.2 KB · Views: 245
Last edited:
You might be right mneary. I was just looking at my concept and people may be sonic reflectors instead of absorbers in which case the circuit might have to detect an increase in RX power. Anyways, I think I am out of suggestions :)
 
Why not build one similar to an ultrasonic range finder?
The Tx unit sends a pulse which hits the opposite wall and the Rx unit receives the echo. You would sound the alarm if you didn't receive a return pulse, or the pulse came back too soon or the pulse came back too late.
If there is no wall to reflect off, then you would simply sound the alarm whenever you received a return echo from any distance. This would be easier to implement than the first example.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top