DASYLab

cancel
Showing results for 
Search instead for 
Did you mean: 

user selectable sample rate

Hi all,

 

I am creating a signal processing package(spectrum analyzer) and wish to have the option of making the sample rate user selectable(in a layout). I am confused as to which sampling rate I must use. There is a sampling rate option in the measurement setup, but there is also a sampling rate for the input module. I have tried putting in global variables in both input boxes but I cannot seem to get it to work with a slider or any control module. I have also tried using the predefined variable SAMPLE_RATE in the write global variable module but it does not work. 

 

I am running the DT9837A Data Translation DAQ box

 

Thanks so much!

 

p.s. I am a new user of DasyLab

0 Kudos
Message 1 of 6
(6,311 Views)

...you can also check here » http://www.dasylab.com/content/mydasylab.php?action=start

Alejandro C. | National Instruments
0 Kudos
Message 2 of 6
(6,304 Views)

You cannot change the sampling rate, if the experiment is running.

 

When you insert a global variable into the "sampling rate"-textfield, the variable's value is evaluated only at the start of the measurement. If the variable's content changes during the measurement, the changes are ignored until the experiment is stopped, and restarted.

M.Sc. Holger Wons | measX GmbH&Co. KG, Mönchengladbach, Germany | DASYLab, DIAdem, LabView --- Support, Projects, Training | Platinum NI Alliance Partner | www.measx.com
0 Kudos
Message 3 of 6
(6,298 Views)

can you use the action module with the stop;/restart measurement action to change the sampling rate?

0 Kudos
Message 4 of 6
(6,293 Views)

The only sample rate that will affect the DT driver is the one in the module settings. I don't know if the DT driver creates an exposed time base - check the Measurement ->Time Base settings to see. The DT driver does not use the Measurement settings->Driver, and the "Sample_Rate" global variable is for the Driver only. The confusion for a new user, and many experienced users, is that the more recent hardware support drivers have been written as extensions, or add ons, and they use the newer time base features, rather than the original driver features, which are very limited in today's computer world.

 

If the DT driver allows a Global variable, then it will be like the original DASYLab driver sample rate, you have to stop and restart to pick up the new rate. Yes, the Action to stop and restart will do that, and you can configure the Action to be manual (using a switch, for example) or when the global variable changes. 

 

Another consideration, depending on the sample rates, consider sampling at the highest rate, and then use some data reduction to reduce the rate on the fly, without restarting. What is the range of sample rates?

Measurement Computing (MCC) has free technical support. Visit www.mccdaq.com and click on the "Support" tab for all support options, including DASYLab.
0 Kudos
Message 5 of 6
(6,290 Views)

Thanks for the replies everyone.

 

cj, the DT driver does not allow a global variable nor does it create a time base, sadly. could you give me some examples of which modules in the data reduction category I should be using to reduce the sampling rate? I am sampling from 30 Hz to 8 kHz

0 Kudos
Message 6 of 6
(6,287 Views)