01-11-2018 09:36 AM
Hi,
I use the X-series multi-function USB: USB- 6341.
in the analog output channel I need a sine wave at the frequency of 20 kHz. in the analog input channel I need to acquire the data at 100 kHz.
I have modified an existing vi from the NI example programs that it's overview: This VI outputs a waveform on an analog output channel and bring the signal back into an analog input channel.
the problem is that I need the analog output to make a sine wave for as long as the VI runs, but it's stops after one sec (even though the analog input channel keeps acquire data)
Please, any thought?
thanks in advanced.
01-11-2018 10:49 AM
You have 2 options:
1. Keep writing the same waveform to the AO.
2. Use a DAQmx Write property node and set the Regeneration Mode property to Allow Regeneration.
01-11-2018 01:53 PM
Hi Crossrulz!
thank you for your response.
I am quite new with LabVIEW, could you please elaborate?
again thanks in advanced,
Naama
01-12-2018 04:00 AM
I have tried to use the daqmx write node but it's still dosn't work...
any thought?
thanks in advanced
01-12-2018 05:29 AM
Hi,
I use the X-series multi-function USB: USB- 6341.
in the analog output channel I need a sine wave at the frequency of 20 kHz. in the analog input channel I need to acquire the data at 100 kHz.
I have modified an existing vi from the NI example programs that it's overview: This VI outputs a waveform on an analog output channel and bring the signal back into an analog input channel.
the problem is that I need the analog output to make a sine wave for as long as the VI runs, but it's stops after one sec (even though the analog input channel keeps acquire data). I have tried to use the DAQmx write node but it's still doesn't work...
Please, any thought?
thanks in advanced.
01-15-2018 07:31 AM
Hi,
I use the X-series multi-function USB: USB- 6341.
in the analog output channel I need a sine wave at the frequency of 20 kHz. in the analog input channel I need to acquire the data at 100 kHz.
I have modified an existing vi from the NI example programs that it's overview: This VI outputs a waveform on an analog output channel and bring the signal back into an analog input channel.
Then I need the analog input (inquired data) to go through a Band Pass Filter-->absolute value--> Low Pass Filter.
In the original program (before the filters and absolute values) it works but after I have added it I get an error.
the final graph doesn't make sense, it also seems like the analog output stops even though I have added the property node and defined "allow regeneration"
I have attached both VI (with filter, no filter)
Please, any thought?
thanks in advanced.
01-15-2018 07:46 AM
Hi Naama,
why did you create a new thread instead of sticking with your original one?
I moved your message…
In the original program (before the filters and absolute values) it works but after I have added it I get an error.
So the problem is (most probably) in the changes made to your "BPF" VI!
You changed the sample rate and the number of requested samples. And you added the filters…
Error 200279 means: you didn't read the sample data fast enough from DAQmxRead: something in your loop requires more time than you expect it…
it also seems like…
Do you check the error wires inside the loop? When does the error occur?
01-15-2018 07:55 AM
Hi GerdW,
thank you for your response.
Error 200279 means: you didn't read the sample data fast enough from DAQmxRead: something in your loop requires more time than you expect it…I don't know how to fix it.. The USB-6341 is supposed to be able to work in those rates but I don't understand how I can solve this.
Do you check the error wires inside the loop? When does the error occur? Yes, it's ok
please if you can help me?
Naama
01-15-2018 08:00 AM
Hi Naama,
disable the filters and graphs in your loop and check if the error still occurs.
When the VI runs without problems: enable the first filter and check again.
When the VI still runs errorless: enable the next filter.
Repeat until you found the problem…
Keep in mind: we don't have your hardware so YOU have to do the testing and debugging!
Do you check the error wires inside the loop? When does the error occur? Yes, it's ok
What is ok? When does the error occur?
01-15-2018 08:07 AM
Hi,
again thank you for your help.
I don't know why even without the filters there is a problem. When I have first built this program I did it step by step as you mentioned.
So without the filter I have 2 problams:
1) error 200272- which I don't know how to solve (increase buffer size et cetera)
2) I don't know why it only do one cycle of analog output (hence the sine wave at the frequency 20KHz)
thank you!
Naama