10-01-2016 05:47 AM
Hi
i would like to play music (in external hardwired speakers) using PXI system. PXIe 6738 (voltage output),PXIe 8840(controller),PXIe 1071 (chassis) is used.
some queries are there
1.Is it possible to create voltage signals by PXIe 6738 according to audio files.
2.Can PXIe 6738 analog output be connected to audio amplifiers.
Please let me know.
Solved! Go to Solution.
10-11-2016 04:28 PM
Hi sajeesh,
1. Yes it is possible to create voltage signals from an audio file. Just open up one of the Voltage - Output examples in LabVIEW and replace the waveform generation part of the code with your audio file data. There is a "Sound File Simple Read.vi" that will turn a .wav file into a waveform data type that you could feed into the DAQmx Write.vi You will probably want to change the DAQmx Timing.vi to "Use Waveform" so that you don't have to worry about matching the sample rate to the waveform, just let the waveform define it. Something like this-
You can take a look at this post if your file is MP3. LabVIEW doesn't have built in functions for it, but looks like others have done it calling into external API's.
2. Depends on what your audio amplifier needs. The 6738 will output +/-10 Volts, and a max of 10 mA. The output impedance is 0.2 Ohms. Will that work with your amplifier? That is the question.
That should give you a good starting point with building your PXI-Powered sound system.
10-14-2016 04:39 AM
Hi.
How ouput impedence of PXIe(AO Channel) and input impedence of audio amplifier effects the architecture ?
I hope Generally measuring devices would have high input impedence.
10-14-2016 10:37 AM
I'm not a sound guy, but I'm guessing its biggest affect would be the current drive. From a quick search online, audio power amplifiers can have a wide range of input impedances, from 1 Ohm to several kOhms. This would mean anywhere from 10 Amps to 5 mA at 10 Volts, respectively. Just know that the 6738 can only output a max of 10 mA.
10-15-2016 01:05 AM
hi..
its ok .the system is working fine with speaker.
NI PXI 6221 is used for Analog output.
we have to play audio files in 4 channels simultaneously.
Error obtained when we write voltage values to AO channel in parallel (error-50103 NI platform services :the specified resource is reserved)
but when we write voltage values one after other no error is obtained.
how to resolve the issue?
10-15-2016 01:10 AM
hi..
The system is working fine with speaker.
NI PXI 6221 is used for Analog output.
we have to play audio files in 4 channels simultaneously.
Error obtained when we write voltage values to analog channel in parallel (error-50103 NI platform services :the specified resource is reserved)
but when we write voltage values one after other no error is obtained.
how to resolve the issue?
10-17-2016 09:18 AM - edited 10-17-2016 09:18 AM
Hi sajeesh,
That error sounds like there are too many tasks being configured for the device. You can only have one hardware-timed AO task on an M series (62xx) card - see here. If you use only one task, and put the 4 waveforms into an array, include all channels in your task, then use the DAQmx Write (N Chan N Samples) to write to all channels simultaneously, that should work. Also, there are only 2 AO channels on the 6221. Are you using multiple cards to output 4 channels? If you are using more than one M series card, you will need to create separate tasks for each card as the M series cards do not support multi-device tasks.
X series cards do, however. The 6783 is built on the X series STC3 timing architecture and has 32 AO. Is that why you are considering the 6738? You will run into the same error unless you put all 4 channels in the same task, just like you would need to do with the 6221.