Status of sound play

Hi,
We are trying to output sound to the computer's sound card continuously from say a continuously sampled analog signal. We recognize that there are two clocks involved here, a A/D sampling clock and a clock (on the sound card) for outputting the sound. Despite our efforts, the two clocks are going to be slightly different. In order to use some resampling technique to compensate for the constant frequency difference, we need to know the status of the sound playing, i.e. how many samples are already played from the buffer written using the sound output write vi. Does anyone know how to obtain this status ? Or does anyone have any ideas how to output sound continuously without buffer underrun or overrun ?
Thanks

Hi sv123,
I'm not 100% sure on this, however I believe statistics like this would be idiosyncratic to the soundcard that you're constructing an interface with. This would mean that driver specific API would need to be called in order to gather the information you require, so your best bet may lie with using the Call Library Function Node or a .NET Constructor Node from the Connectivity palette within LabVIEW alongside some knowledge of the driver's internal structure.
Alex Thomas, University of Manchester School of EEE LabVIEW Ambassador (CLAD)

Similar Messages

  • Sound play during keypress

    Hi all,
    I have a sound loaded that I would like to have smoothly play
    while a key is held down.
    So I have...
    var eSound:EngineSound = new EngineSound();
    ...keypressed event, etc...
    if (upArrowPressed)
    if (eSoundPlaying == 0)
    eSoundChannel = eSound.play();
    eSoundChannel.addEventListener(Event.SOUND_COMPLETE,eSoundComplete);
    This is part of a game loop, and I have tried a number of
    things with the eSoundComplete function too (re-checking status of
    the up arrow and re-launching the play() if it's still down, etc.).
    The idea is that while the player holds down the up arrow,
    the engine sound will play. The engine sound is only about .5
    seconds long and is loopable.
    Currently if the player holds down the arrow key the sound
    will play, stop, play, stop, etc. So there is a little delay
    between each...like it's making a skipping sound.
    Does anyone know how I can have the sound play as a seemless
    loop *only* while a key is held down?
    Thanks!
    -K

    make sure you have the recording input set correctly in your settings (look under Device options)
    however your tv tuner is connected to your soundcard (eg Line-IN) then this should be set accordingly

  • When i login to my account and it takes me to the desktop, the error sound plays, then the rainbow wheel appears, and finder immediately stops responding

    It started yesterday when i was listening to itunes when all of a sudden the music stopped playing and i had to hold down the power button to shut it down and reboot, and then, when i logged back in, the error sound played, and then finder opened up, but the window was grayed out like i had another app selected, bu i didn't, so i tried to open up itunes and the icon started bouncing and then it stopped midbounce and i had to reboot again because finder wasnt responding. now when i log in, the error sound plays, and finder immediately stops working and then i have to reboot again because i cant click anything and i cant properly relaunch finder. please help

    Please read this whole message before doing anything.
    This procedure is a diagnostic test. It’s unlikely to solve your problem. Don’t be disappointed when you find that nothing has changed after you complete it.
    The purpose of the test is to determine whether the problem is caused by third-party software that loads automatically at startup or login, or by a peripheral device. 
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards. Boot in safe mode and log in to the account with the problem. Note: If FileVault is enabled, or if a firmware password is set, or if the boot volume is a software RAID, you can’t do this. Ask for further instructions.
    Safe mode is much slower to boot and run than normal, and some things won’t work at all, including Wi-Fi on certain iMacs. The next normal boot may also be somewhat slow.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin. Test while in safe mode. Same problem? After testing, reboot as usual (i.e., not in safe mode) and verify that you still have the problem. Post the results of the test.

  • Mail notification sound plays after I have read a new message

    When a new message comes in, the mail sound does not play right away. Often I will see the email and read it. Then, some time after I've finished and the screen is locked again, the sound plays.
    This problem occured with iOS 4 and still happens in iOS 5.

    Hi,
    I have had chats/conversations that have shown the blue "unread" indicator which goes if you reselect the chat but appears again when you select another Chat.
    I have also had the red Unread number indicator showing on the Dock icon badge as a separate issue.
    This second I have resolved in Force Quitting the DOCK in Activity Monitor ( I will use Terminal but prefer an User Interface option).
    The first I tend to solve by dismissing that particular Chat/Conversation.
    As you have tried the DOCK reset method by both the recommended methods of doing so I would try a PRAM/NVRAM reset.
    Restart the Mac holding down the CMD+ALT+P+R keys all at the same time until you have heard three Start up Bongs.
    You can then let the Start up Continue.
    8:58 pm      Friday; January 2, 2015
    ​  iMac 2.5Ghz i5 2011 (Mavericks 10.9)
     G4/1GhzDual MDD (Leopard 10.5.8)
     MacBookPro 2Gb (Snow Leopard 10.6.8)
     Mac OS X (10.6.8),
     Couple of iPhones and an iPad

  • I placed my ipad on top of my CPU with a music playing,i heard a crack on the sound and when i checked it,i can no longer hear a sound playing on my ipad.i tried to check place a headphone its still playing a sound but when i pull it out,wont play at all.

    i placed my ipad on top of my CPU with a music playing,i heard a crack on the sound and when i checked it,i can no longer hear a sound playing on my ipad.i tried to check place a headphone its still playing a sound but when i pull it out,wont play at all.

    I don't know if this will work but it's worth a try. I wonder if somehow you ended up with a short inside of your iPad. Give the things below are trying to see if that helps. Good luck.
    Try a Restart. 
    Press and hold the Sleep/Wake button for a few seconds until the red "slide to power off" slider appears, and then slide the slider. Press and hold the Sleep/Wake button until the Apple logo appears.
     Resetting your settings
    You can also try resetting all settings. Settings>General>Reset>Reset All Settings. You will have to enter all of your device settings again.... All of the settings in the settings app will have to be re-entered. You won't lose any data, but it takes time to enter all of the settings again.
    Resetting your device
    Press and hold the Sleep/Wake button and the Home button together for at least ten seconds, until the Apple logo appears. Apple recommends this only if you are unable to restart it.
    Or if this doesn't work and nobody else on the blog doesn't have a better idea you can contact Apple. 
    Here is a link to their contacts with most of the information below. 
    http://www.apple.com/contact/

  • I was listening to music on my ipod shuffle when it went off.It hasn't turned on since then.When i connect it to the computer,the connection and disconection sounds play continuously without the ipod showing.What could be wrong or how can i get it to work

    I was listening to music on my ipod shuffle when it went off.It hasn't turned on since then.When i connect it to the computer,the connection and disconection sounds play continuously without the ipod showing.What could be wrong or how can i get it to work?

    Hello,
    I am currently an owner of an Ipod Touch 4th generation. I see you are having problems with your Ipod Touch, so I will try to find a solution to your problem.
    Hold down the Sleep/Wake and Home buttons for at least 10sec. or until Apple logo appears (Nothing will be lost, this is just a "Hard Reset")
    Hope that helps!
    If none of the above solutions work, can you please respond back ASAP as I will try to find another solution to your problem (This might even help others with the same problem!)
    Cheers!
    Pizza98704

  • How to make sound play in loop

    Hi
    How can i make sound play in loop? Is there any property in class SoundChannel responsible for this or i have to write my own function?

    Using the sound Object there is a property you can pass in which asks for number of Loops
    Play(startPosition:Number,LOOPS:int,SoundTransform)
    or you can create your own method that listens to SoundComplete and then trigger play again.  which in my opinion is the best to do because when you play a sound with a loop, and choose to have is begin at a position other than 0  then the loop will play starting from where you set the position.

  • No embedded video (empty bar) in FF ver. 15 32bit. Sound plays. Flash ver. 11.4.402.265. No problems in IE. Windows 7 x64.

    Installed FF 15 (32 bit) on a fresh copy of Windows 7 Ultimate edition (x64).
    Everything works fine except the embedded video.
    The video clip thumbnail is shown, when clicking on the clip the sound plays and the right-mouse click shows flash player options, but no video is shown (empty bar).
    No problems on original YouTube or other flash video sites were detected.
    No crashes detected.
    Please, advise.

    1) Started the FF in Safe Mode.
    The embedded video works normally (!!!)
    2) Re-started the FF in normal mode - got the problem.
    3) Disabled ALL plugins and ALL add-ons (except the flash player) in Normal Mode - got the problem (once again, ALL plugins / add-ons were disabled).
    Safe Mode - everything works.
    Normal Mode - problem occurs (with no relation to disabling plugins / add-ons).
    Looks like there's something built-in FF which has the problem with showing embedded video normally in FF Normal Mode.

  • Why doesnt a sound play when I change the path?

    Hi. I am trying to play a background sound in my program and so far, after searching and reading lots of posts I finally have a "TaDa" sound playing once when the program starts. But what I want is a sound to be looped everytime I start a program. That sound will be in the same folder as the program.
    This is the code that I put in public static void main() to play the sound:
    public static void main(String[] args) {
    SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    java_testt b = new java_test();
    b.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    b.startApp();
    private void startApp()
    {playStartupSound();}
    private void endApp() {System.exit(0);}
    private void playStartupSound() {
    Runnable soundPlayer = new Runnable() {
    public void run() {
    try {                                                                                    
    File tadaSound = new File(System.getenv("windir") + "/" + //This is the windows tada sound. All I want is
    "media/tada.wav"); //to change the path to another sound
    AudioInputStream audioInputStream = AudioSystem
    .getAudioInputStream(new FileInputStream(tadaSound));
    AudioFormat audioFormat = audioInputStream
    .getFormat();
    DataLine.Info dataLineInfo = new DataLine.Info(
    Clip.class, audioFormat);
    Clip clip = (Clip) AudioSystem
    .getLine(dataLineInfo);
    clip.open(audioInputStream);
    clip.start();
    } catch (Exception e) {
    e.printStackTrace();
    Thread soundPlayingThread = new Thread(soundPlayer);
    soundPlayingThread.start();
    Does anyone know how to choose another sound in the same folder as java_test and make it work with this code because when I change the ath it doesnt run.
    Thanks.

    Please put your code between the code tags. It's much better readable then.
    public static void main(String[] args) {
    SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    java_testt b = new java_test();
    b.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    b.startApp();
    private void startApp()
    {playStartupSound();}
    private void endApp() {System.exit(0);}
    private void playStartupSound() {
    Runnable soundPlayer = new Runnable() {
    public void run() {
    try {
    File tadaSound = new File(System.getenv("windir") "/" //This is the windows tada sound. All I want is
    "media/tada.wav"); //to change the path to another sound
    AudioInputStream audioInputStream = AudioSystem
    .getAudioInputStream(new FileInputStream(tadaSound));
    AudioFormat audioFormat = audioInputStream
    .getFormat();
    DataLine.Info dataLineInfo = new DataLine.Info(
    Clip.class, audioFormat);
    Clip clip = (Clip) AudioSystem
    .getLine(dataLineInfo);
    clip.open(audioInputStream);
    clip.start();
    } catch (Exception e) {
    e.printStackTrace();
    Thread soundPlayingThread = new Thread(soundPlayer);
    soundPlayingThread.start();
    }

  • Why do my speakers not play music? I know they work because when I go I change my ringtone all the sounds play. I am not a very happy costumer right now and would like an answer to my problem. Thanks.

    Why do my speakers not play music? I know they work because when I go I change my ringtone all the sounds play. I am not a very happy costumer right now and would like an answer to my problem. Thanks.

    What happens when you play music? Do the hardware volume controls work when using the Music app?

  • Headphones usage on Satellite A660-BT2G22 -sound plays out of the speakers

    When I plug headphones into my Satellite A660-BT2G22 Laptop the sound plays out of the speakers and the headphones.
    There has to be a way for me to make the sound play only through the headphones and I would really love that because I am going off to college soon and will have a roommate and I will want to listen to my own music and stuff and not force him to hear my stuff all the time.
    Please help?

    This notebook model is not known to me but check control panel and option for some audio manager there. On notebooks with Realtek sound card there is Realtek HD Audio manager.
    Check all options there, especially small folder symbol placed at the right top side. When you click on it connector settings window will be open. Enable auto popup dialog.
    Now, every time when headphones will be connected you can choose headphone as only device you want to use.
    Please check it out.

  • Flash in AW sound plays but no picture

    I've googled for this but haven't found any definitive
    answer.
    I have a subroutine which plays flash files through the flash
    xtra. It works fine but for the 3 files in which there has been an
    mp3 embedded (to time the animation to the sound) - the sound plays
    fine but i get one line of the picture only near the bottom and it
    doesn't play the anim.
    I have tried the same procedure with a fresh file - just
    having the flash xtra and loading the anim into it directly with
    "browse..." but with the same result. The anims play fine from the
    media folder tey are located in, playing in Firefox or IE.
    Any suggestions? Using Flash MX, AW 6.5 and Mp3s.
    Thanks in advance
    Helen

    > Ahh steve yes you musn't have seen my post on the web or
    after i updated
    > it -
    > thought to mention it after posting...
    Once it goes out on NNTP there's no updating it .... I'll
    only ever see your
    original post. That web interface is too slow for my sanity!
    >
    > "I have tried the same procedure with a fresh file -
    just having the flash
    > xtra and loading the anim into it directly with
    "browse..." but with the
    > same
    > result. The anims play fine from the media folder tey
    are located in,
    > playing
    > in Firefox or IE."
    When you view the Flash file as standalone ... outside a
    browser, then
    right-click and Show All, what do you see?
    Wild guess ... maybe you have something off at the top of the
    Flash movie
    that's pushing it down the screen???
    Steve\\
    EuroTAAC eLearning 2007
    http://www.eurotaac.com
    Adobe Community Expert: Authorware, Flash Mobile and Devices
    My blog -
    http://stevehoward.blogspot.com/
    Authorware tips -
    http://www.tomorrows-key.com

  • Published for iOS, sound plays but no screen.

    Hi,
    I have completed a new game that runs great on Android - created using Flash Builder 4.5 and Flash Professional. I got all our Apple stuff out of the way and then also compiled for iOS. Then I deployed to my son's iPod Touch 5 via TestFlightApp.com. He installed and ran and we get the sound but no screen. I'd really like to finish debugging and then deploy this app for both droid and iOS at the same time (in the next few days). Can someone tell me why the SWF's that are the UI of the app are playing sound but not showing up on screen? How can I fix this problem?
    BTW, please forgive the fact that the site is under dev (will be completed and polished before go live), but you can get some idea of what the game is about at our web site: headshotgame.com.
    Best,
    Al

    Ooops, spoke too soon...
    After we recompiled all our FLA's to SWF's and added them as assets to our Flash Builder project, it did not work again (SWF sound plays but no graphics display). So, we went back to the earlier test solution and it did not work  either?!?
    Finally, we compiled using the quick compile selection of Flash Builder. The intro screen showed up all the sudden! But, none of the buttons work and you can't navigate to any other of the screens. Sadly, this is not answered and I don't know whether this belongs in the Flash Builder or the Flex forum as I don't know what is causing the problem.
    All of this works perfectly on Android. Same code on iOS does not work. Perhaps it's the fact that I'm testing on an iPod touch with iOS5?
    I have people waiting to test this app and help me get it live but I can't seem to get it to run on iOS. Please let me know if I can provide any other info to help you help me.
    Thanks!
    A summary of our problem:
    We have multiple SWF's that are compiled in Flash Pro that make up a larger mobile app that we built in Flash Builder.
    We add the Flash Pro SWF's to Flash Builder as assets of the project and use the Navigator to move between them with event listeners bubbling up from the buttons that are in the SWF's.
    There are many SWF's - most screens have multiple SWF's on them.
    All of this works very well on Android.
    The same project compiled for iOS creates an IPA file but when the IPA file is deployed to the device, none of the screens show up but the sound plays.
    There is only one way to get a (the first) screen to show on the device which is to set Flash Builder packaging method to "fast". Yet, getting the screen to show is useless as it won't allow you to navigate (and the SWF behaves differently in other ways compared to Android).
    I am testing on iPod and will recruit other iOS device users to test as well. The iPod I am testing on is an iPod touch with iOS 5.

  • How to stop sound playing at a embed FLV video

    Hello,
    I would not a piece of code, which will stop the sound
    playing in a embed
    flv video. Following situation:
    I have a "main.swf" file which loads two swf as following:
    loadMovie ("Teenies.swf", _root.contenedor);
    loadMovie ("CananIntro.swf", _root.mc_video);
    The "CananIntro.swf" includes (embed) the flv video "canan
    PART1.flv".
    I would need the action sript code to make the sound at
    "canan PART1.flv" ON
    or OFF.
    Thank you for any hint.
    Walter

    Another way to do this is to create a boolean right off the start. Lets say var createMusicTrack:Boolean and set it to true
    Then load your music and start playing it and at the end of that load code add a line that sets the boolean to false so that when you come back to frame 1 the boolean will be false and the code will not load and play, but this could be problematic too. Djnr suggestion is better for your purposes.

  • How to make the notification sounds play through EarPods

    The notification sounds/ringer on my iPod touch keeps playing through the external speakers even though I have EarPods plugged in. If I turn on a video of game tho, it will play through the earpods. Is it possible to make the notification sounds play through the EarPods as well?

    Hi Everyone,
    Just in case anyone else runs into this problem here is the solution that i've managed to piece together,
    I have a movie clip twice the size of the stage, the movie clip is called bg_mc, here is my actionscript...
    bg_mc.addEventListener(Event.ENTER_FRAME, mouseMoveHandler);
    function mouseMoveHandler(event):void
    var cursorX = stage.stageWidth - mouseX;
    bg_mc.x -= dx / 5;
    this action script tells the movieclip to move left and right depending on where the users mouse pointer moves. (it also adds a slight delay to make it look like tweening)
    I then published this in Flash using the publish settings shown in the reply above.
    Then i went into dreamweaver and removed the margins in the html file
    Now the flash file will resize to any screen resolution and will allow the user to move the MC left / right across the screen depending on where the mouse pointer is,
    I hope this is helpful,
    Ben

Maybe you are looking for

  • Error while trying to change Material master

    Hi , I am getting following error when I am trying to Change material master thru Tcode MM02 "Required parameter missing when calling up module MARA_SINGLE_READ" In fact , I also couldn't select this Material in Purchase order .Error which i am getti

  • Problem In MIRO at the time of bill of entry

    Hi, I am facing a problem while doing bill of entry for an A/c assigned (Asset) PO in MIRO. When i am simulating, i noticed that Asset transaction G/l is getting debited instad of cenvat clearing A/c for all Duties for which credit to be taken. But i

  • Compatability with Kaspersky PURE

    I recently installed Kaspersky PURE and have issues with web sites fully loading or working correctly on Mozilla. Things work fine on Internet Explorer, but not Firefox, which is what I prefer. Please help...thank you.

  • Need Inspection lot creation at only one storage location level - QA07

    Hi, I have shelf life expired material at different storage location. When ever i run QA07.System generates inspection lot for all storage location.But I want to process the inspection lot for only one storage location. Please guide me how can we map

  • SWF exports and buttons.

    So I'm getting a lot of conflicting information on DPS on the web, including from adobe sources. In Bob Bringhurst's DPS tips app, it states that the most simple way of creating toggle buttons is to use an MSO with a "go to next state" action - did t