LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

dual tone measurement through labview

Hi all,

 

   I'm quite new to Labview, I require assistance if possible in the field of analyzing the dual tone frequency being inputed through a microphone and I want Labview to output a amplitude/frequency graph but its keeps giving me an amplitude/time graph.

 

    I also require labview to give out what number is being pressed via a visual output. maybe an LED. How would I acquire that?

0 Kudos
Message 1 of 12
(3,708 Views)

Are you using an FFT function within your code?

 

Once you have that, you should have two peaks on your graph.  You will need to detect them.  When you say "dual tone measurement", are you talking about the tones made by a dial-tone phone when a particular button is pressed?  If you have the frequency values for the two peaks detected, you could use a look-up table to determine which phone button corresponds to that combination of tones.

0 Kudos
Message 2 of 12
(3,702 Views)

Yes I am talking about the two distinct peaks in the amplitude when a button is being pressed, although I am just generating the tone through some website tone generator. I've encountered an error with the Filter VI (under Express) and it won't run the VI saying that there's an error in the "subVI".

I would much rather have the labview output some sort of LED display as an output. This is a project I am doing with some others, but we have no knowledge in labview

0 Kudos
Message 3 of 12
(3,699 Views)

What does the error say?  Does it have an error number?  Post a VI.

0 Kudos
Message 4 of 12
(3,694 Views)

The subVI is not executable. You must fix all errors in the subVI before this VI can run.

 

Attached is the VI. If I don't attach the Filter VI, the program works when I have a tone running through it, but with the Filter VI it doesn't run and the above error shows up. SubVI is not executable.

0 Kudos
Message 5 of 12
(3,671 Views)

I see the same thing using LV 11.0.1f2.  What version of LabVIEW are you using?

 

I have no explanation for it.  Hopefully someone from NI can comment on your VI.  If I convert the Express VI to a regular VI (right click/open front panel) it says "This VI claims to be a part of a library, but that library does not claim to own this VI."  And also "This VI is connected with a library that does not include the VI. The VI might have been deleted from the library. Add the VI to the library again or select File»Disconnect from Library."

 

What you can do is don't use the express VI.  Go to the Signal Processing >>  Filter palette and pick one of the filters from there.  You will want to use an Express VI to convert the dynamic datatype to a waveform datatype.

0 Kudos
Message 6 of 12
(3,654 Views)

Okay. I'm going to try that, unfortunately I don't have access to the DAQ assistant Express VI outside of the university lab, I'm trying to improvise by testing it via the acquire sound.vi to get the signal through a headphone jack through my phone. But it doesn't seem to work. Do you know what I can do instead of this? I have attached the VI as well here. I've never used this VI either.

0 Kudos
Message 7 of 12
(3,651 Views)

I'm getting this error now.

 

Error 4800 occurred at Acquire Sound->Acquire.vi

 

Possible reason(s):

LabVIEW: (Hex 0x12C0) Selected Device is Invalid

 

 

0 Kudos
Message 8 of 12
(3,648 Views)

Hello Xerom,

 

I took a look at the VI you provided, and it appears that the Filter express VI has had its directory modified or been corrupted in some fashion.  I haven't tested this, but it's also possible that the VI was created in LabVIEW Full and then opened and re-saved in LabVIEW Base, as this Express VI's library is not accessible with the Base license - do you know what version you're using? It sounds like you may be working on a few development computers.

 

As for the DAQ Assistant, the DAQmx drivers are free to download and can be found here:

 

NI Drivers: NI-DAQmx

http://www.ni.com/nisearch/app/main/p/bot/no/ap/tech/lang/en/pg/1/sn/catnav:du,n8:3478.41.181.5495,s... )

 

Error 4800 typically indicates that the microphone being used is not being detected by the drivers you're using; I would confirm that the device is showing up in the Windows Device manager as a valid input device (or similar if on a different operating system) before attempting to access it in LabVIEW.  It is also possible that the parameters or sampling rates you've set aren't supported by the hardware or drivers. 

 

Regards,

 

 

Tom L.
0 Kudos
Message 9 of 12
(3,617 Views)

Your acquire VI works okay for me except for one thing.  The conversion from the dynamic data to the waveform is choosing channel 1 (in the Express VI properties) which doesn't exist.  So the waveform is empty along with the graph after the filter.

 

But your error message is coming from the first Express VI.  Open up the property dialog on that and try reselecting the sound card and channel.

 

Note:  I went back and opened up your original VI in LabVIEW 2012 and am still seeing errors about the Express Filter VI about not being executable and the underlying subVI being a part of a library.

 

I found only one message thread by way of google discussing this issue.

http://forums.ni.com/t5/LabVIEW/SubVI-filter-not-executable-Undefined-error/td-p/1996701

I tried going through the steps there and nothing seemed to work.

 

I went back to LV 2009 and was able to create a Filter express VI there without errors.  I then saved and opened in LV 2012.  Still no errors.  Then I went into your VI (still in LV 2012) and was able to lay down a new Filter Express VI without an error.  I deleted the old and rewired everything.  That modified VI is attached.

 

I think there is a bug with this Express VI (possibly others) that was not there in LV2009, but is there in LV 2011 and 2012.  (I haven't tried LV2010.)

 

I think someone from NI needs to investigate the original VI you posted as well as read the linked to message thread and comment into both.

0 Kudos
Message 10 of 12
(3,612 Views)