ishan5590 Posted December 2, 2014 Report Share Posted December 2, 2014 Hi everyone, I have learnt a lot about LabVIEW programming from this website and this forum. However, this is my first post on the forum. So I have managed to get a signal, which is in time domain, with the amplitude in volts. It looks like the in the picture attached. The above signal is the raw signal, and the one below is a cropped section of the part of the above signal I am interested in. The increase in amplitude seen in the cropped section is an "echo" of the transmitted signal. The cropped signal starts again from time=0, but that can be taken care by simply adding the time, at which this signal was cropped. The task is to find at what "time" does the echo occur. Since the "echo" is spread over a considerably large distance over the x axis (time axis). I need to process the signal with some algorithm so that the echo can be measured at one reference point everytime, which represent the position of the echo on x axis. I am trying to use a peak detector VI and I am getting the value of indexes, where the peak is occurring. However, only peak detection is certainly not reliable. Any inputs on what methods or combination of methods could be used for this task?? Any help would be greatly appreciated!! Regards Ishan Quote Link to comment
infinitenothing Posted December 3, 2014 Report Share Posted December 3, 2014 (edited) You're going to have to give us some more examples of the echo so we know what to look for. If it always looks the same you can use the cross correlation of a "good looking" echo segment vs the waveform you want to search. The x location of the peak of the cross correlation will tell you where they line up (the start of your echo). http://paulbourke.net/miscellaneous/correlate/ Edited December 3, 2014 by infinitenothing Quote Link to comment
Jordan Kuehn Posted December 3, 2014 Report Share Posted December 3, 2014 Here is a simple snippet that I have used for a similar task before. There are many many ways to process the data, but with signals like what you have I've found that selecting a nominal location for where the 'reflection' should be as well as a window size to search in, you can pretty directly find what you are looking for. The peak may not be what you want, but this is a starting point. You have good SNR so that helps a lot. 1 Quote Link to comment
Gary Rubin Posted December 3, 2014 Report Share Posted December 3, 2014 Look into "matched filter" Quote Link to comment
ishan5590 Posted December 3, 2014 Author Report Share Posted December 3, 2014 Hi, Thank you for the quick reply guys. However, i dont think i was able to explain myself earlier. My problem at the moment is not really the technical part of "how" to do a certain thing in labview. It is more of a problem with the algorithm. SO i will try and explain my explain properly. @Jordan Kuehn: The information you gave was quite helpful. I am actually doing something similar. I am using the peak detector VI and logging time value of each peak. (attached picture VI). But this information is not reliable. In the files attached with this message, you will see 3 graphs. These are three different measurments taken at exactly same input parameters. But since my signal is an echo, and it is not in an controlled environment right now, as it should be, I am getting variations in each of the three outputs, for exactly the same input. For eg. Currently if i take the time value of the highest peak as my time value. Then it is not a reliable value because the time at which highest peak occurs changes, even though the input is the same. Now, I need to develop an algorithm, where i can use certain characteristics or combination of characteristics of the signal (eg. amplitude or peaks or anything else) and measure find a time value which is steady. I hope I was able to explain my problem better now. Any help in this direction is highly appreciated. Thank you infinitenothing and Gary Rubin for your responses. Quote Link to comment
Mellroth Posted December 3, 2014 Report Share Posted December 3, 2014 What about this: 1. First find the chirp by edge trigger or peak detect etc. 2. Define window, either manually or through an algorithm that can detect when echo is finished, and get only that data. 3. Remove the DC component of the windowed data. 4. Measure the time between zero crossings /Jonas Quote Link to comment
Gary Rubin Posted December 3, 2014 Report Share Posted December 3, 2014 I really think you want to use a matched filter. It's basically the cross-correlation that infinitenothing mentioned, and is very standard in radar signal processing to find the time of arrival of an echo even in the presence of noise and clutter. You just need to have a copy of the signal that you originally sent out. It can be implemented as a sliding point-by-point multiply in the time domain or in the frequency domain as a vector multiply (with some FFTs involved). Some googling on Matched Filter should get you there pretty quickly. Gary 1 Quote Link to comment
ishan5590 Posted December 3, 2014 Author Report Share Posted December 3, 2014 Thanks a lot Gary! I don't really know how a matched filter works. But I will definitely find out and try to implement it the way you said! thank you everybody! Ishan Quote Link to comment
infinitenothing Posted December 3, 2014 Report Share Posted December 3, 2014 (edited) Your peak detection may work better if you increase the peak width setting. The sine waves are flat at the top and don't look all that peaky if you just look at a narrow section. Edited December 3, 2014 by infinitenothing Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.