05-22-2008
10:03 AM
- last edited on
05-01-2024
09:59 AM
by
Content Cleaner
Hi guys, I'm currently using a PCI-4462 to perform fractional octave analysis on a signal that's well within the range of human hearing. At the moment our program only logs the signal strength of individual bands, but I think it would help us if we could record that signal as sound to compare the human analysis of the sound as heard by our sensor against what our algorithm thinks is happening.
I've seen some guys allude to doing this in LabView, but our systems will only have the basic DAQmx drivers installed. Can anyone give me any pointers about how to grab samples from the card and pipe it into a wave file that a human being can listen to?
We're developing our application in C++.
Thanks!
--Peter
05-23-2008 01:56 PM
Hi Peter,
A .wav file is an uncompressed audio format that is made up of the raw sample data and a header which tell the audio player what is need to know to play the data, such as the sample rate, number of channels, bits per sample, etc… You are already acquiring the raw audio data from you PCI-4462 using NI-DAQmx. Now you need to write that data to a file along with the needed header information to make it a wav. Information on the .wav file format can be found here. You also may be able to find some libraries or dlls on the web that make this simpler to do. LabVIEW in the Windows environment does come with some sound Vis that makes this very easy. That is probably why you’ve heard it can be done. Please let know if you have any questions.
Thanks,