Sound Input Read VI hangs

I'm using the SI Read VI to sample from the Soundblaster card in my Dell PC. I've configured the device for 16-bit mono input, sample rate 44.1 kHz, and the buffer size is 1024 samples. The SI Read VI is in a Timed Loop whose period I've set to 23 ms (1024 / 44.1kHz). Following each acquisition, I do some filtering, frequency analysis, and plotting inside the loop.
The acquisition works well for the first 10 minutes or so that it is running. But sometime after about 10 or 15 minutes, the VI hangs. I've traced the hang back to the SI Read VI, but have not yet figured out how to avoid the hang or recover from it (I have to abort and restart the program).
Has anyone had similar problems with the SI Read VI? Could there be a problem with the DLL that the SI Read VI calls? Are there any upgrades or fixes for this? Can someone suggest a way to recover from the hang?
Thanks for any help,
Mark

This message is a reply to "Sound Input Read VI hangs" (National Instrument) NI Discussion Forums posting found at: http://forums.ni.com/ni/board/message?board.id=170&message.id=137258 and http://forums.ni.com/ni/board/message?board.id=170&message.id=110656&requireLogin=False
Hi everybody,
From the large count of how many of you guys read the above thread of messages, including myself, and who are dealing with the same problem of SI Read VI hanging found National Instrument (NI) LabVIEW (LV), I decided to share my (not so perfect) solution with you guys to save you time and frustration. Here is the story of 3 days (18 hrs/day) of my life, fighting a bug in SI Read VI (SI: Sound Input) (I am currently using LabVIEW Pro v 7.1.1):
For the reason that "A Message cannot exceed 10,000 characters" on this Forum I included my message in the attached Word doc. Hopefully, there is no such limitation on uploaded files!
Samir Berjawi
Research Assistant and Lab Instructor
American University of Beirut
[email protected]
[email protected]
Attachments:
LabVIEW SI Read freezes - Report.doc ‏39 KB
Sound Acquisition Test.zip ‏995 KB

Similar Messages

  • Wrong sampling rate from Sound Input Read VI on Dell Latitude E6510

    Hi,
    When I
    receive data from the sound card with the Sound Input Read VI, the actual
    sampling rate is not equal to the sampling rate set in the Sound Input
    Configure VI. I estimate the sampling ratio by dividing the number of samples received
    by the difference between the first and the last t0 from Sound Input Read. For
    example, if the sampling rate is set to 7000 S/s, the actual sampling rate is
    around 6900 S/s. If the sampling rate is set to 7050 S/s, the actual sampling
    rate is around 7200.
    This problem appears when the
    code is run on my Dell Latitude E6510 machine. When I run the
    same code on my Lenovo ThinkPad, the sampling rate is correct.
    The Labview application I
    am developing is to be used to acquire data synchronously from several sources,
    including the sound card input. It is therefore important that the sampling rate
    is correct.
    If anybody has any idea
    about what may cause this problem, and a way to fix it, I would be grateful.
    Ole

    It has been a trend the last years that sound card only support some sampling rates, not a range. You should refer to your sound card manual for this kind of information.  You should also be aware of that the NI sound interface is junk, and they do care about it either. Use the WaveIO interface instead See the link. But I am quite sure your problem is related to the sound card hardware not some NI driver issue
    http://www.zeitnitz.de/Christian/waveio
    Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
    (Sorry no Labview "brag list" so far)

  • Time mismatch with Sound Input Read VI

    Hi Folk,
    I am acquiring the signal of the PC
    sound card with the "Sound Input Read VI" and I have
    noticed that between subsequent waveform data packets there are time
    mismatch, both overlap and gap.
    To point out the observed behavior, I
    have posted a modified example, the "Continuous Sound Input.vi". In the example, I have computed the
    time difference between the t0 of the actual waveform packet and t0
    expected on the basis of the previous waveform packet.
    Consistently, in the indicator "Time
    series" (Waveform Charts), each time there is a time overlap or
    gap the Charts resets it self or presents a gap.
    By reading 1 second of data the time
    mismatch is about 0.015625 or 0.03125 sec. (both positive and
    negative).
    The repetition frequency of the time
    mismatch decreases as the acquisition sample rate increases.
    The amount of the time mismatch seems
    to be sample rate invariant.
    Do you have any idea from where this
    problem is coming out and how to solve it?
    Thanks for your help,
    Asper
    Attachments:
    Time mismatch with Sound Input Read VI.png ‏51 KB

    Pre made Labview functions are not some holly grails that is newer to be touched and modified. In fact many included functions in Labview has what I will name as "high flimflam factor" That will say a lot of functions you do not really need. Express VIs are grim examples of this.
    Anyway I have made some modifications and removed some babyfat in the sound input VI. Take a look at it. The top level VI is the "time fixed sound.vi" It could be that you will get an error because Labview will not find a DLL. If a DLL is reported missing you will find it in C:\Program files\National Instruments\LabVIEW 2010\resource\lvsound2.dll
    Remember to save the modified VIs in a separate folder, and not in the vi.lib folder at all. Be careful so you do not overwrite any Labview function
    Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
    (Sorry no Labview "brag list" so far)
    Attachments:
    Sound Input Read (DBL)_time_fixed.vi ‏30 KB
    time fixed sound.vi ‏19 KB

  • Sound input read multiple soundcards

    Heey everybody,
    I have a problem. I want to read two different signals at the same time from 2 different soundcards. 1 internal soundcard from my laptop, and 1 usb soundcard. 
    So i used the Acquire Sound VI.
    Reading both signals at the same time is not a problem until i set the measuring time to about more that 30 seconds. It gets a buffer overflow.
    So i tried to do the following:
    I first made this with 1 signal first, and it worked perfectly, every second it got updated.
    But, when i added the second signal it only wanted to read the first second of the first signal and then it got stuck, and i had to stop the software by closing it. And then killing labview with the taskmanagement thingey from windows.
    Anyone have any idea what the problem is?
    Greetings,
    Jory 
    Solved!
    Go to Solution.

    Ok, never mind, i've solved it. I made the buffers larger (at the sound input configure block) and now it works like a charm

  • Sound Input Read Spectrum Analyzer

    I am working on a project with Arduino to do a spectrum analyzer. The LVIFA part of it is working fine.
    The part that I am struggling with is the audio input.
    I am using the Sound Input Pallet.
    My troubles are two-fold.
    1. A single read takes quite some time and I need to have a pretty quick response. I decreased the samples per read and came up with problem #2.
    2. I can get one read out of the Sound Read In and then the VI locks up. I have my timeout set to 1 Sec and it never times out. I have to restart LabVIEW.
    While it would be nice to have this VI working, I'm not even sure that I am using the correct tool. If I am going to be running an audio spectrum analyzer display off of the data input, I need to response to be within a few mS (ie. <200) so that it looks visually correct.
    If this library will not achieve this, then I need to look into a different tool.

    Hi,
    I have a similar project, actually I am using a Audio frequency range as input to the Arduino and do an FFT to receive the spectrum out of it.
    See the YOUTUBE video I did and the code in *.jpg. I took actually the Continous Input example and modified it.
    Hope that helps.
    Keep me posted, since we might work on a same project.
    http://youtu.be/aqzyofQHXDM
    Y3G
    Attachments:
    Uno Blockpanel.JPG ‏104 KB
    Uno FRONTpanel.JPG ‏99 KB

  • PLEASE can a AE from NI take a look at my problem. Sound input read behave in strange manner then the buffer size is larger than 2X number of samples to read.

    On my computer I have discovered some strange behavior then reading data from the sound card. Then the buffer size is 2x samples to read everything is as expected. But since I read the sound card 10 times pr second I feel a .2 second buffer is to small. I am using XP, and XP is not a RTOS so with a buffer set to 0.2 seconds I may lose data. Therefore I set the buffer size (number samples/ch on Sound Input Configure.vi) to be in range of 2 seconds. The result then is that then reading from Sound input.vi, a reading often take more than 0.1 second. On my computer it is often 500mSec. Then the next 5 read follows with almost zero interval. I do not loose data. But on my front panel the graphs looks like an very early silent movie. This error was introduced in Labview 8.x. To be honest I think the labview 7.x sound system was much better in many ways.
    But before I point any finger NI. Other people has to verify the behavior I experience. I have made an example showing this error. It is a modified version  of the "Continuous Sound Input.vi" example. Then the "buffer in seconds" control is set to 0.2 every thing works OK. Changer this to a larger number will produce the mentioned above hiccup. The larger number in this control the larger hiccup. Is it any way to fix this? My solution up to now has to use a free 3. part software(http://www.zeitnitz.de/Christian/index.php?sel=wav​eio) But I guess it soon will be outdated. It may not work with newer windows versions.
    Any help at all will be appreciated 
    And yes I have the most updated version fo DirectX. Also I se this in Labview 2009 which I have trail version of. The VI I have made is in 8.6
    Message Edited by Coq Rouge on 09-07-2009 10:54 AM
    Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
    (Sorry no Labview "brag list" so far)
    Attachments:
    Continuous Sound Input with timing.vi ‏23 KB

    macaba wrote:
    If you take a moving average of the 0.2s buffer vs. 3s buffer at an update rate of 10, then they are the same (just under 100ms), so the average refresh rate is the same. I agree that is odd behaviour that the time between sound reads go to zero quite a lot then take a long time once in a while (presumably to fill the buffer
    I guess it goes to zero because it is reading data from the buffer it do not has to wait for data from the sound card. The mysterious thing is the periodic delay. You are also correct then saying that average timing is correct. And in my application I have no data loss.
    If you search for sound in this forum you will find out that many people has reported trouble with the sound system.
    Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
    (Sorry no Labview "brag list" so far)

  • G5 sound input reads drums but no sound coming out

    i'm not sure what the deal is, the input is reading my drums fine but i hear no sound not through headphones or surround sound or computers speakers. All my sound works for anyhting else. please help me

    My present computer has no sound input capabilities but there may be a setting in sound control panels or whatever software you are using for selecting sound output, including passthrough. There's also a midi application in your applications that controls sound features.

  • How to have Sound Input Read VI read .wav in sections

    Hi,
    I'm trying to read audio data from my laptop's soundcard, and it's really slowing down my VI's processing power. I read on the NI website to read the .wav file in sections instead of as a whole, but I have no idea how to do that. Any suggestions? My VI is attached.
    Thanks!
    Attachments:
    signalgen.vi ‏56 KB

    You have set the sample rate for the sound card to 100000 samples pr second. That is a sample rate your sound card will not be able to handle. Hence a error will occur. And you will not get any data from the sound card. Some sound cards may support samplerates in 1 Hz step but most sound cards do only support some rates. The latter is most typical. All sound cards do support 44100 Hz sample rates but typical sample rates are 44100,22050,11025, and 8000. Some sound card do also support higher sample rates than 44100. Refer to your sound card documentation for this. Your way of using the Daq card by reading 1 sample on each iteration, using software timing is also a Daq NO-NO. Read data in chunks and do not do to many updates pr second, and always use HW timing. If you need the waveform to appear "live", or "real-time" 10 updates pr second is more than enough.  
    I have included a sample vi. I suggest that you use that as your workhorse from this point. At least if you want more help from me
    Tip Labview is shiped with many very useful examples. Then you are stuck. Go to toolbar->help->fFind examples. As one example the Daq setup is from the "Cont Acq&Chart Samples-Int Clk.vi" vi example
    Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
    (Sorry no Labview "brag list" so far)
    Attachments:
    workhorse.vi ‏37 KB

  • Difficulty getting Sound input configure and sound input to read more than 2 channels

    I need multichannel audio input for my project. I can't seem to read more than 2 channels of my audio interface.
    The interface Im using is an Alesis Multimix8 USB 2 mixer and and audio interface. This supports 10 channels in and 2 out. With other software I can read all input channels simultaneously without any difficulty. When I specify the sound input configure and sound input read, to read more than 2 channels any extra channel is a blank signal. Im using Labview 8.5 here.
    Solved!
    Go to Solution.

    Take a look here
    http://forums.ni.com/t5/LabVIEW/Play-waveform-express-vi-list-devices-on-front-panel/td-p/1559336
    Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
    (Sorry no Labview "brag list" so far)

  • System Preferences Sound Input is stuck at Soundflower (64ch). I can't change it!

    So, I have a mid-2010 MacBook Pro running OS X Yosemite (latest version). (250GB HDD, 4GB RAM, 2.4 GHz)
    I wanted to record some commentary for my video and to use the mic I went into System Preferences > Sound > Sound Input.
    With my mic connected, I tried all of the 4 options (picture below), but then after closing and opening System Preferences again, the sound input is stuck on "Soundflower 64ch).
    When I try to change it (e.g. Built-In), it "crashes", but not really: It selects the option I clicked for a second or two, then the list disappears and says "No Input Devices" briefly, then the list reappears with "Soundflower 64ch" selected.
    Please help, I've tried some solutions I found online, like restarting the laptop, repairing disk permissions, even a code for Terminal.
    Thanks to anybody in advance.
    UPDATE: ****, I think my Mac is possessed or something. It shows the ring of death when my mouse is on the System Preferences window, and when I try to take a screenshot of the list itself, it lags and doesn't let me take it until "No input devices found" appears.

    Either remove "Soundflower" or refer to its developer for support.
    Any third-party software that doesn't install by drag-and-drop into the Applications folder, and uninstall by drag-and-drop to the Trash, is a system modification.
    Whenever you remove system modifications, they must be removed completely, and the only way to do that is to use the uninstallation tool, if any, provided by the developers, or to follow their instructions. If the software has been incompletely removed, you may have to re-download or even reinstall it in order to finish the job.
    I never install system modifications myself, and except as stated in this comment, I don't know how to uninstall them. You'll have to do your own research to find that information.
    Here are some general guidelines to get you started. Suppose you want to remove something called “BrickMyMac” (a hypothetical example.) First, consult the product's Help menu, if there is one, for instructions. Finding none there, look on the developer's website, say www.brickmymac.com. (That may not be the actual name of the site; if necessary, search the Web for the product name.) If you don’t find anything on the website or in your search, contact the developer. While you're waiting for a response, download BrickMyMac.dmg and open it. There may be an application in there such as “Uninstall BrickMyMac.” If not, open “BrickMyMac.pkg” and look for an Uninstall button. The uninstaller might also be accessed by clicking the Customize button, if there is one.
    Back up all data before making any changes.
    You will generally have to restart the computer in order to complete an uninstallation. Until you do that, there may be no effect, or unpredictable effects.
    If you can’t remove software in any other way, you’ll have to erase and install OS X. Never install any third-party software unless you're sure you know how to uninstall it; otherwise you may create problems that are very hard to solve.
    Trying to remove complex system modifications by hunting for files by name often will not work and may make the problem worse. The same goes for "utilities" such as "AppCleaner" and the like that purport to remove software.

  • Bootcamp 3.1 & Windows 7 x64 - no external sound input, low speakers level

    Hi all,
    I just installed long awaited Bootcamp 3.1 update. I am rather disappointed.
    The only thing that has changed is that the red light on the audio output is off. This thing actually bothered me the least.
    External sound input line does not seem to work at all. No matter if mike or standard line device is connected. System recognizes that something is connected but there is no sound coming, level indicator does not rise.
    Speakers level is still low. As far as I know all it takes to fix it is to alter some settings in the *.ini file. Someone did it and posted for other to download but why it is sho hard for Cirrus and Apple? What is the matter?
    Is there any way to get sound output via Mini Port under Windows 7?
    System does not even see such device.
    Thanks,
    Thomas

    What about the iMac though? 2008 Model w/ Realtek to be specific. The audio is low and poor and I haven't even tried the audio out. I'm running Win7 x64 and everything works well aside from my audio and my external WD Studio FW800 drive disconnecting randomly with repeated directory changes. I can avoid that on my system... but the audio is a real disappointment. Makes me feel like I need an external FW sound card.

  • Premiere Pro 2.0 and Windows 7 - Direct Sound Input soundcard driver problem

    My XP machine crashed, I reinstalled Premiere Pro 2.0 with Windows 7, and I got the following error: 'The Currently installed soundcard driver does not support Direct Sound Input. Recording audio is not possible.' The soundcard drivers are updated. Any ideas? Here's what I have: AMD Phenom II X4 965 Processor  3.40 GHz 8 GB, 64 bit. Thank you for looking.

    Thanks! Though I upgraded to solve the problem, this is good to know.
    Bob
    Date: Wed, 9 Nov 2011 04:45:42 -0700
    From: [email protected]
    To: [email protected]
    Subject: Premiere Pro 2.0 and Windows 7 - Direct Sound Input soundcard driver problem
    Re: Premiere Pro 2.0 and Windows 7 - Direct Sound Input soundcard driver problem created by Steve-Italy in Premiere Pro CS4 & Earlier - View the full discussion
    VERY VERY VERY EASY (now, when I solved the problem, not before...!!!)
    Insert Micropone or any jack in Micropone Input or Aux Input, on your sound card or motherboard !
    AND NOW YOU CAN USE PREMIERE PRO 2.0
    Enjoy
    Steve - Italy
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4015730#4015730
    To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4015730#4015730. In the Actions box on the right, click the Stop Email Notifications link.
    Start a new discussion in Premiere Pro CS4 & Earlier by email or at Adobe Forums
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.

  • 50L7300UC - sound input from Mac not outputting to ARC

    I'm having an odd problem with audio on my 50L7300UC (Canadian model of the 50L7300U). I have a soundbar hooked up via HDMI ARC, and it works fine for audio from my cable PVR, from online sevices such as Netflix accessed through the TV itself, and from my PC (a Windows 8 tablet connected via a mini-Displayport to HDMI cable, which provides both audio and video). But with my wife's Macbook Air, using the same mini-Displayport to HDMI cable, video is fine but the sound won't output to the soundbar. Oddly, the sound does work if played through the TV speakers, but if I switch sound output to the soundbar (which the TV sees as "Amplifier"), nothing comes out. I've tried different settings on the Macbook's audio output (using the Midi Audio utility), but that doesn't seem to matter. Any ideas?

    Hmm, if it doesn't see the internal microphone when connected via the FW cable, maybe you might have to run audio cables from the camcorder line output to the sound input on the Mac.

  • G4 and microphone suitable for sound input port

    I'm looking into getting started with podcasting and I need help with selecting a microphone. I'm on a G4 desktop machine with a sound input port, any suggestions as to the tech spec or manufacturer of a suitable microphone would be most appreciated.
    Thanks.
    G4 desktop   Mac OS X (10.4.6)  

    Hi, Neil -
    This Apple KBase article provides some info with regard to microphone selection -
    http://docs.info.apple.com/article.html?artnum=18275
    Scroll down the article to the G4 section that matches your G4 model.
    Many users have gone to using the Griffin iMaic adapter, since it permits a wide variety of micophones to be used. There's a link near the bottom of the above article to Griffin's iMic page.

  • Sound Input and Output Disappeared

    I am considering a purchase of a used Macbook Pro (4,1) from early 2008 with Snow Leopard 10.6.8 installed. When I first tried the machine, the sound input and output were absent. After removing preference files, resetting NVRAM, etc., I finally got them to work. They worked for a few weeks, but recently they disappeared again. This time, my efforts to ressurrect them have been fruitless.
    Here is what I have done in an attempt to remedy the situation:
    •Delete com.apple.audio.DeviceSettings.plist and com.apple.audio.SystemSettings.plist
    •Jiggle a digital headphone jack in the headphone port
    •Verifiy Disk and Repair Permissions
    •Reset NVRAM
    •Reset SMC
    I have read online that some people have replaced the AppleHDA.kext file with the one from 10.6.7 - however, every effort I have made to find this file has resulted in failure. I am not able to locate MacOSXupdCombo 10.6.7.pkg anywhere on the web
    Any recommendations? I was able to fix this once before - why not now? Thanks for any and all constructive input...

    Did you recieve the install disk(s) when you purchase the machine? I would try doing a back up of your data then a fresh install of the OS. Insert the disk into the mac then click restart and hold the c key, ten follow the prompts.
    If you wish to take this route, I would try the 10.6.8 combo update first (it should be fine to run it again), then if you wish you may try the 10.6.7 update. Altough I would just do a OS X reinstall and then run software update till you bring it up to date. On disk 2 there should be the AHT (Apple Hardware Test) that you can run by booting the disk holding the D key to check for a hardware fault.
    You may also make a Genius bar appointment for a free evaluation, they have more extensive diagnosis tools and would then tell you what your otions would be. (hey it's free)
    Genius Bar appointment http://support.apple.com/kb/DL1361
    10.6.8 Combo update
    http://support.apple.com/kb/DL1399
    10.6.7 Combo Update:
    http://support.apple.com/kb/DL1361
    All the Best

Maybe you are looking for