07-12-2011 10:47 AM
Hello Everbody,
I need some help in acquring time to beep from a application. Im using acquire sound vi and looking for maximum amplitude and the corresponding time, but the real problem is data is too much to look into is there any technique by which the amount of data can be reduced and acquire time to beep.
Regards
shaik
07-13-2011 09:22 AM - edited 07-13-2011 09:25 AM
Hi Shaik,
So is it the "relative" time from when the code begins running until a beep occurs that you are looking for? Or are you looking for an "absolute" time when a beep occured (14:52:39 for example)?
There are timing functions we can employ in LabVIEW, and a million and one ways to use them. Often I see people start measuring the number of milli seconds from when the code started running until an event, and then performing a subtraction on the information or other basic maths. Alternatively we could start getting clever and time stamping the data points we are reading. again, it comes down to relative ro absolute time.
Too much data to view or work with? need to reduced that data to something manageable?.... DIAdem to the rescue! But I don't think we need to employ this software environment in this particular case.
If you have a cosssal amount of data points then I will make the assumption that you are making measurements from your microphone at a set frequency whilst waiting for a beep? Perhaps not? But if you are there are way we can program around that.
I assume you are using National Instruments hardware? If so, then it's probably working on the DAQmx driver? There are loads of examples on our website and in the LabVIEW example finder that will allow you to trigger your measurements when the beep begins. That way you aren't left with loads of useless measurements in the "waiting" period before the beep occcurs.
Perhaps you could fill us in with as much detail about which versions of software and hardware you are using, and any LabVIEW toolkits or modules you have access to? It would be great if you could attach the code you mentioned as well.
Thanks for your time Shaik, I look forward to helping out.
07-18-2011 05:12 AM
Hello Rhys,
Sorry for late reply, I want to measure beep at relative time. The hardware I am using is a microphone which is connected to sound card of my PC ( see attachment for data sheet). I have done some compression but the problem is the data I am getting is in absolute time. and is the technique right. please have a look at it.
Regards
shaik
07-21-2011 08:05 AM
Hi Shaik,
Thanks for posting the code. I wasn't able to see how the report is being put together though, I'm afraid. In the code you are using the Microsoft Office Report express VI, which requires a report template. Yours is located on your machine at this location: C:\Users\lab\Desktop\Time to beep1.xlt
The Express VIs that you are using pass the 'dynamic' data type between eachother (dark blue wire), which doesn't have a timestamp associated with it. However, the waveform data type does carry a time stamp (it's hard to argue if waveform is it's own data type in LabVIEW, as it is in fact a cluster of different data types).
So solutions to the problem would be to either use functions that output the waveform data type, or use the 'Build Waveform' function in LabVIEW and wire in an absolute time stamp along with your dynamic data. Alternatively you could replace the MS Office Report express VI with a Write to Measurement File express VI. In the setup of the write-to-measurement file VI we can choose to record time data along side each of our measurements.
Thanks, all the best with your work!