LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

CVI and DTMF

Is it possible to generate and detect DTMF signals with a 6070E card?  All the examples found at the NI web site are labview based.  Does anything exist in CVI?
0 Kudos
Message 1 of 12
(4,767 Views)

Hi Joncombat,

 

You should be able to do this with your 6070E card.  Unfortunately, I did not find any CVI examples through my search either.  

Regards,


h_baker
National Instruments
Applications Engineer
0 Kudos
Message 2 of 12
(4,747 Views)
I could solve this issue with support equipment but why purchase/build hardware when it can be done with software and existing equipment.
0 Kudos
Message 3 of 12
(4,695 Views)

From looking at that labview example DTMF is a combination of two tones. Here is a starter application that combines two sine waves of different frequencies. You can combine this technique with DAQmx to output a DTMF signal. Let me know if you have any questions, also if you get done with your project, and no one has created one yet...a DTMF example for CVI would be a perfect fit in the community.

 

 http://decibel.ni.com/content/docs/DOC-5472

Richard S -- National Instruments -- (former) Applications Engineer -- Data Acquisition with TestStand
0 Kudos
Message 4 of 12
(4,664 Views)
I have the resultant file but how can I send the data in the file to "Dev2/ao0" of the 6070E card?  I can generate various frequencies with the card but I do not know how to send data in an array to the card.
0 Kudos
Message 5 of 12
(4,645 Views)

 

 

Open up the example finder by going to Help » Find Examples inside of CVI. Then looking at the example ContGen-IntClk.c inside of the function GenSineWave around line 229 you will see that in the example they are building an array:

 

 

for(;i<numElements;++i) sineWave[i] = amplitude*sin(PI/180.0*(*phase+360.0*frequency*i)); *phase = fmod(*phase+frequency*360.0*numElements,360.0); }

 

and passing it back to the data variable. Then then passing the data variable to:

 

 

 

DAQmxErrChk (DAQmxWriteAnalogF64(gTaskHandle,sampsPerBuffer,0,10.0,DAQmx_Val_GroupByChannel,data,&written,NULL));

 

DAQmxWriteAnalgoF64 will then output whatever is in the data variable to your card, at whatever rate you specify in DAQmxCfgSampClkTiming.

 


 

 

 

If you're unfamilliar with DAQmx programming in CVI check out this example on using the DAQmx Assistant in CVI.

 

 

Richard S -- National Instruments -- (former) Applications Engineer -- Data Acquisition with TestStand
0 Kudos
Message 6 of 12
(4,637 Views)
I have is partially working.  I just need to verify the waveforms. 
0 Kudos
Message 7 of 12
(4,615 Views)
The waveforms are incorrect.  The timing is off either during the addition of the sine waves or the sampling rate of the resultant waveform.
0 Kudos
Message 8 of 12
(4,570 Views)

I have the following array

 

  for(i=0;i<1000;i++)
   {
   
  resultant_sinWave[i]= sin(i*2*3.14*1209/8000) +(sin(i*2*3.14*697/8000)); 
   }

 

It appears to be the tone "1" when graphed on the pc.  When I try and output it to the daq the tone is wrong/noisy

 

How do I set the timing up for a frequency that is undetermined?

0 Kudos
Message 9 of 12
(4,547 Views)
So, looking at the LabVIEW example http://decibel.ni.com/content/docs/DOC-3943 it looks like they choose a sampling rate of around 20,000 which should be quick enough to be a time base for you those frequencies. It does mention to turn regeneration off of the DAQ card. I posted a comment on the example asking for some possible help getting this to work in CVI, lets see what they have to say.
Richard S -- National Instruments -- (former) Applications Engineer -- Data Acquisition with TestStand
0 Kudos
Message 10 of 12
(4,541 Views)