LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Multitone Generator with frequencies lower than 1

Hello there,
 
the Multitone Generator works great if the frequencies are multiples of one i.e. 1,2,3 ... but what if the frequencies are lower than one or 1.5, 2.33 for example. Does anyone know how to use the Multitone Generator in this way. Your help would be appreciated.
0 Kudos
Message 1 of 9
(3,512 Views)
Check the cluster for sampling info.  The values entered in there need to be mathematically compatible with the frequency.
 
Error -20307 occurred at  "NI_MAPro.lvlib:ma_MultitoneParamsCheck.vi" when called from "NI_MAPro.lvlib:Multitone Generator.vi:2"
Possible reason(s):
Analysis:  Frequency not a multiple of (Sampling Rate)/Samples.
 
For example, for 0.5 frequency, a cluster of 500 sampling rate and 1000 samples worked.  500 rate and 2000 samples worked.  500 rate and 2001 would not work.
 
The boolean coerce frequencies? being set to true seems to help it ignore the error.
0 Kudos
Message 2 of 9
(3,504 Views)

To add just a little more info.

I found that if you don't wire the cluster, its defaults are 1000 sampling rate and 1000 samples.  The ratio is 1, so only frequencies that are a multiple of 1 are allowed.  Anything below 1 or otherwise fractional (like 1.5, 2.33) throws the error.  However, making the coerce frequencies boolean true (its unwired default is false), does not throw an error.

0 Kudos
Message 3 of 9
(3,502 Views)
Doesn't it mean that if coerce is true that the frequencies get rounded to the next Fs/N? Hence the frequencies are not acurate anymore.
0 Kudos
Message 4 of 9
(3,486 Views)

Did you ever find a solution to this problem? I'm still having this problem with my VI.

0 Kudos
Message 5 of 9
(1,303 Views)

@RazorF wrote:

Did you ever find a solution to this problem? I'm still having this problem with my VI.


It's implied that you tried the potential solutions mentioned above, but did you really?  (Just so we know where to start with the troubleshooting.)

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 6 of 9
(1,299 Views)

I should have clarified. I am trying to make it so this VI does not require the tones to be coerced because, as it was said prior, the frequencies being coerced means that its inaccurate. I just need to know how to ignore the error that comes out of it if coercion is set to false. Here's my VI for reference.

0 Kudos
Message 7 of 9
(1,284 Views)

@RazorF wrote:

I should have clarified. I am trying to make it so this VI does not require the tones to be coerced because, as it was said prior, the frequencies being coerced means that its inaccurate. I just need to know how to ignore the error that comes out of it if coercion is set to false. Here's my VI for reference.


Do you need a specific sample rate?  I mean, it's probably a dumb question because you would have changed it to match if you could, but ignoring the error won't work because there is no output on error.  So I guess the answer is either you're stuck coercing or you need to make the samples and frequencies related to each other.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 8 of 9
(1,245 Views)

Have a look at the shipping example for non-regenerating continuous analog output.  It gets you pretty close.  You'll just need to *sum* the distinct tones into 1 waveform for 1 output channel instead of generating an array of individual tones, 1 each for N output channels.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Kudos
Message 9 of 9
(1,243 Views)