2 digital out 2 analog in loop

LabVIEW 2013 SP 1
Windows 7 Pro
NI DAQ PCIe-1433
Custom PC board attached to the DAQ
Each individual signal disucssed has been tested and works.
Hi all,
I have an application that does a bunch of setup, when the user presses go, runs a main loop that does a number of things, saving images, etc., and also periodically sets digital output pins HI, and then LO.
This has to be synchronized with the image retrieval and storage.
It is working well.
I need to add 2 Analog Input signals, also synched with the Digital out and the video capture.
I simplified it all so that in the test application, I start the app, set up some preliminary stuff, and when the user presses go, run a main loop.
I've removed the video component and data file components for now.
The test app will trigger a single digial out (e.g. left puff) and start listening on a single Analog In (e.g., left mic).
When the left mic reaches a trigger level, it flags it, and stops listening.
When the time is up, the digital out (left puff) is set to LO.
If the trigger level hasn't been reached when the digital timer is up, it stops listening then too.
That works okay (the first time).
However, the loop keeps running, as it should.  When the next time hack comes around the the same thing is supposed to happen again (either left or right), the digital signal is not tripped, and the Analog In is not started.
And that failure is true for all future loop iterations.
I threw in a counter to show me if the LabVIEW was enterring the case statement, and it is counting up as it should.  But the signals are not generated.
If I go to the diagram, and turn on the 'lightbulb' tracking; everything works.
I get the digital output when I should, I get the analog in.
When I turn off tracking, it doesn't work past the first iteration.
I've attached the example file.
Any thoughts are appreciated,
Jeff
Solved!
Go to Solution.
Attachments:
Puff timing loop.vi ‏36 KB

Hi Julian,
That occurred to me as well, but I couldn't see it.
After taking the night off, and looking at it again, I noticed that the 'stop' case was executing directly following the 'start' case (within the same iteration of the while loop).
So, it was actually turning on, but then immediately turning off, before any slow-witted human could discern the action.
Thanks for the solution.
Jeff

Similar Messages

  • Simultaeno​us digital out and analog in

    Hi. I am running into an issue with the simultaneous AI (analog in) and DO (digital out) with Athena (www.diamondsystems.com) and LabVIEW (see the supplied files): The original program example supplied by somebody (the attached 060126 file) runs fine with these two simultaneous operations.
    However, for my specific requirements, I would have to put a frame (flat sequence) around the DO part (the attached 060131 file), followed by another flat sequence frame that changes another DO state. The reason that I must do this is that I have 2 valves which change states as the AI operation continuous to run.
    I have noticed though, once I put those flat sequence frames around it, the DO pauses and doesn't perform the operation until the AI loop is stopped. I have tried to create various local variables but the issue persists. Would there be a workaround for this? Thanks.
    Attachments:
    HMIR_SBC_060131.vi ‏374 KB
    HMIR_SBC_060126.vi ‏137 KB

    I have taken a look at your code. Based upon your description,
    and the fact that I do not have the driver for your device, I am not exactly
    sure where the program is pausing.  I can give you some suggestions to
    resolve your problem.  When you use a flat sequence structure, every piece
    of code in a frame has to finish execution before the next frame will start
    execution.  If you have code in parallel (i.e. digital output and analog
    input) in one frame and the same in a second frame the digital output and analog
    output in the second frame will not start until all the code in the first frame
    has finished execution.  In your case it you have a while loops for
    digital input and output in the first frame.  When both of these loops
    finish execution, you should see the second frame start shortly after. 
    From your description what I believe is happening is that the digital output in
    the first frame is finishing and waiting for the analog input to finish. 
    After the analog input loop finishes the second frame can start.  If you
    want the second frame's digital output to start before the loop finishes
    execution you will need to take that code out of the frame.
    Regards,
    Jesse O
    Applications Engineering
    National Instruments
    Jesse O. | National Instruments R&D

  • Send out analog and digital signal simultaneously ?

    Is there any way to send out an analog signal and a digital signal at
    the same time? Time is critical in my application. Milisecond delay is
    not allowed. I am using a PCI-MIO-16E-4 board and DAQ 6.0.
    Any information from you will be deeply appreciated.
    Sent via Deja.com http://www.deja.com/
    Share what you know. Learn what you don't.

    You went a little too far. the while loop I was talking about was the one around the digital write. You've now taken the digital write completely out of the loop and closing it. You can't do anything with the digital when the analog in is running. You've also closed the analog write while the analog in is running. The attached is more like what I was talking about.
    Even with the diagram cleaned up, it sounds like you still have a problem. I don't know the details of your hardware setup but I would start by looking at the analog signal you are generating and verifying that it is correct to your hardware. It would help if you had a scope to troubleshoot. If the signal is correct to the hardware, then trace it through to the connection to the DAQ's analog input. If it's correct there and you still don't see the signal, then you may have wired up the DAQ incorrectly. You haven't specified the connection type (differential, RSE, etc) and I believe it will default to differential.
    Attachments:
    Single Channelv 2_mod.vi ‏535 KB

  • Digital out to analog speak

    I have just bought a new Audigy 2 ZS, but I have a question regarding the possible use of the digital out of the card for my Logitech 560 speakers, with some kind og adabter/converter, as I find it to be quite a hassle to crawl under my desk everytime I have to use my headset.
    I have read that I can use an adabter for my Line Out and 2, but that is lovering the sound on the one that the headset is connected to, so I really don't like that option, as that isn't ideal when gaming and using speakers.

    Jutapa wrote
    Hi This may become quite expensi've (thought). You need an adapter to split signal (from output to dig speakers and DAC) so you do not have to swap cables when changing between speakers/headphones, and a DAC to convert signal from digital to analog. DAC must be capable to convert multi channel input into 2 channel stereo output. You find available devices by googling. .jtp
    As I see it, I need a device that will make it possible to get my analog speaker witch has two connectors, that tight now occupies the Line Out and 2 on my soundcard, making it impossible to connect my headset at the same time, unless I find a way to use the Digital output
    I also don't understand why it's not possible to use the many "pins" on the soundcard, for my headset, as I would guess that when you buy a Creative Soundblaster Audigy 2 ZS Platinum , you get some sort of cable that goes from these "pins" to the front panel? I would really like to be able to use these "pins" to connect my CoolerMaster Stacker I/O Panel http://www.coolermaster.com/index.ph...0+CM%20Stacker
    Message Edited by Blind-Goose on 04-7-2005 02:37 PM

  • Xtrememusic: Digital out or Analog out, Advantages Disadvanta

    I have a Xtrememusic card, that has a wonderful sound using the analog outputs to 3 Sonic Impact T-Am
    ps.
    Now, I'm curious about using the digital out to a Panasonic SA-XR55 digital amp/receiver. I know I would lose the CMSS, but the Panasonic can do it's own synthesis of surround. I'm interested in knowing from users about the pros and cons of using the digital out or analog outs. I know the quality of the Xtrememusic DACs are good, and I read that the Panasonic?has a excellent sound output as well. If I choose to use the digital out, I could just use?the motherboard onboard digital out, although only in DVD modes does it do a true bitperfect pass through. In stereo mode, it's still using some of Windows to mix the sound. I could also use the digital out of the card. Seems like a shame to bypass all of that nice analog the card is capable of?
    Oh yeah, anyone know if a old Creative Li've 5. I/O panel will work with a Xtrememusic card??Thanks

    wiersch,
    I believe you might have Skype set to auto-configure your soundcard. Try this, open Skype and go to it's audio setting menu. Disable the option 'Let Skype adjust my sound device setting.'
    Jason

  • How do I get my new apple tv from digital out put to analog

    How do I get apple tv2 from digital to analog output?

    Hard to without knowing the setup. At any rate I wouldn't recommend it.
    There will be no guarantee that it will work as only HDMI is supported. As stated above you will not be able to play HDCP content (i.e. iTunes, Netflix)

  • Analog audio unavailable - only digital out

    Hello, I'm having a problem where my audio isn't functioning. Only digital out. I didn't even know my macbook had digital out. When I look in the headphone jack there is a red lazer beam shooting out. I don't want lazers. I want an analogue signal. Thanks.

    Hopefully one of these steps should solve the problem.
    1. System Preference > Sound > Output > Internal Speakers
        Highlight  Internal Speakers / Headphones
        Make sure Mute is not enabled.
    2. Reset PRAM.  http://support.apple.com/kb/PH4405
    3. Reset SMC.     http://support.apple.com/kb/HT3964
        Choose the method for:
        "Resetting SMC on portables with a battery you should not remove on your own".
    4. Applications > Utilities > Audio MIDI Setup
        Audio Devices window
        Side Bar
        Click the Built-in Output.
        Under Mute any of the boxes checked? If so uncheck it.
    5. Option click the speaker icon in the Finder menu bar,  select Internal Speakers.
    Best.

  • Performance issues using control references in Analog control loop?

    My main vi of a tensile tester control application calls a number of sub-vi's, including a analog control loop which controls the test. The control loop must update some boolean and digital indicators and respond to user input on the front panel of the main vi during a test.
    To simplify my main vi, I moved the control loop code into a sub-vi, and used control references to access the controls and indicators on the front panel. However, this has dramatically affected my loop performance, and the loop can no longer keep up with the acquisition speed.
    Do control references always cause such a slowdown? Is there anything that I can do besides moving the code back into the main vi?
    Thank You,
    David Creech

    I have had the same problem. I have discovered other funny things about references also; some kind of memory management (or mismamagement?) is taking place behind the scenes.
    Regardless, you can often do away with the references by passing the initial state of a control or indicator into the subvi, changing it inside, and passing the altered state back to the caller. Once back in the caller you update the front panel control or indicator by using a local variable.
    One thing to watch out for if using this scenario is the dreaded race condition; this can be avoided using a state machine. Check out
    http://www.advmeas.com/goodies/statemachine.html
    for a good example. It is a shame that references behave in this way; it limits thier usefulness.
    Perhaps someo
    ne else will point out a way to utilize them more sucessfully?

  • Can i generate PWM output from digital out of my PCI 7041 RT DAQ card?

    I want to generate 4 PWMs using my PCI7041 card. I do have only 2 analog outputs and 2 counters to output my signal that's why I want to use digital out of my card for PWM. How can I do that? If there is any example then please let me guide that way.

    Hello rajen,
    There is a good link to PWM in LabVIEW using counters here.
    As for using analog output, you will need to be able to continuously update your output waveform. I've attached a program that demonstrates this. Hope this info is helpful.
    -Alan A.
    Attachments:
    Continuous_Analog_Out_Update.vi ‏139 KB

  • Audigy 4, digital out would not work, now external box does not power

    I recently purchased a audigy 4 sound card. At first it was almost as if there was a loose wire somewhere. Sometimes the external break out box would power up and sometimes it would not. There was no loose wire and it now no longer powers up at all. The only thing that was worse than the intermittent power up was the digital out on the box. First of all I was told that you could use the spidf out on the box to a receivers digital in, this never worked now matter what settings I tried. I was then told to try the mini out. So I went and bought a mono mini out, that was a joke, didn't fit right rarely worked. I then went and bought a mini stereo plug to RCA out, that fit right and worked a few times, It no longer works at all.
    I had the settings set up correctly with the spidif passthrough.
    Has anyone else had any problems getting the digital out to work with a receiver?
    The analog works fine, but just like the audigy mp3 the bass output for my sub is weak and almost nonexistent. I have a nice hifi/ht system I am trying to get this card to work with.

    hello there!
    i have the same problem - when i use the equalizer i can save a preset without problems,
    but if i reboot the pc i first have to open the equalizers window to make the equalizer work. without having opened the equalizer window it seems to be not activated.
    does anybody have an idea how to fix that problem?
    greetz,
    doolak

  • Sound Blaster card 'digital out' into my high-end stereo receiver?

    BSound Blaster card 'digital out' into my high-end stereo receiver?A I want?to interface my iTunes music library?(all tunes in Apple Lossless file format) to my high-end sound system, using an optical (TOSLink)?cable and a "mini TOSLink adapter" that will plug into the 'digital out' jack on the Sound Blaster card in my Windows XP PC. This configuration will take advantage of the high-end DAC's in my Denon receiver.
    I don't care about getting surround sound out of my PC, and I'm not a gamer. I just want hi-fi stereo music from my iTunes library.
    Will this work?Can I expect CD-quality sound?
    Also, would it be worthwhile to upgrade my model SB394 sound card to a hi-fi SB card like X-Fi Xtreme Audio, or is any sound card as good as any other for simply deli'vering the digital data stream to my Denon receiver?

    Jebus wrote:
    well, I have two devices that a combo CD player/Tape decks/radio tuner/amp; one has misc input, the other doesn't. Both are analog devices, both are old things I bought at a yard sale. I got 6 bookshelf speakers that use pairs of stripped wire as the input hooked up in 2 parallel wired sets of 3 to the CD/Tape/Tuner/Amp thing that has a misc input. Anyway, the one without misc input has a 3 disk CD changer, plus it would give me a way to input tape and radio sounds sources into my computer if I just connected it's audio outputs to the internally located Aux In on my soundblaster card in my computer. But I wonder, what considerations do I have to have?
    Firstly, is the Aux In on my board analog or digital? I'm assuming if it doesn't say "digital", it's analog; correct?......
    secondly, and more importantly; the CD/Tape/Tuner/Amp thing is supposed to be used with 8 ohm speakers and do I have to worry about sending too much current to the soundcard?
    specific model of SB card; I'm not sure. It has 2 analog outs, analog in, mic in, digital out and a joystick port; and it came installed on a 200 Dell w/ Win ME
    and please, don't try selling me something; I use old crappy hardware and really do not mind doing so.
    any help will be appreciated, thanks.
    Aux-In is an analog port (4-pin connector/stereo).
    Don't connect powered output (= speaker outputs) into soundcard but, if possible, use some low-power connection like Headphones-Out (or if possible then some line-out port).
    jutapa

  • No digital out signal from Optical Out

    I have a Pavilion p6250f PC with a ATI Radeon HD 4200 integrated graphics card.  I have it connected to my Onyo receiver through the DVI-D port to the HDMI port on my Onyo receiver.   I get a message saying I need to cable the sound separately, so I am using a optical cable from the PC to the receiver, but am unable to get any sound.
    I have used the Realtek menu to select Digital Out.  Any ideas?

    Hi,
    Where are you connecting your optical cable to on the PC as you have stated?
    Try SPDIF output from the PC using a coaxial cable to a digital input on the receiver. Or, use an analog cable from the back of the PC to the receiver.  Then go back into the Control Panel ---Sound---> Playback Tab and set the default sound out device.
    HP DV9700, t9300, Nvidia 8600, 4GB, Crucial C300 128GB SSD
    HP Photosmart Premium C309G, HP Photosmart 6520
    HP Touchpad, HP Chromebook 11
    Custom i7-4770k,Z-87, 8GB, Vertex 3 SSD, Samsung EVO SSD, Corsair HX650,GTX 760
    Custom i7-4790k,Z-97, 16GB, Vertex 3 SSD, Plextor M.2 SSD, Samsung EVO SSD, Corsair HX650, GTX 660TI
    Windows 7/8 UEFI/Legacy mode, MBR/GPT

  • Digital out not working (unibody)

    I have been using my digital out for some time and now i noticed its not working. When i go to the system panel it says headphones when i plug in the digital audio out connector rather then saying digital audio out. NOthing has changed otherwise. Same connector cable plugging into the same audio system.
    Thanks in advance

    Have you tried cleaning out the jack with some compressed air? Sometimes the Mac will mistakenly think something is plugged in to the optical/analog audio jack.

  • X-Fi XtremeMusic and Digital Out

    Please forgive me if this has been asked before, but here goes...
    I have a WinXP machine with an X-Fi XtremeMusic card that I would like to hook up to my Onkyo TX-SR600 receiver. The ideal situation would be to run a single digital line into the coax digitial input of my receiver. I would like all sounds to pass through the receiver and let the receiver do the decoding if possible.
    Do I need to hook up analog cables for the 6 channels in addition to the digital line?
    Thanks for any help,
    - James T

    No, just run the digital coax to the rec. If you don't have one, you will need a digital coax and a /8 mono to RCA adapter. Radio Shack has these items.
    If you play games and want surround sound, you will have to go to analog out. I acutally have both analog out and digital out. They work well.

  • M-Audio Studiophile AV 40 monitors with imac optical digital out

    I'm looking to purchase these monitors for my imac or ones very similar to them and was wondering how I go about hooking them up to the imac. I've read that I would have to use a mini-TOSLink cable to use the optical digital out, but how do I go from that to the RCA on the back of the monitors? Do they make a mini-TOSLink cable to RCA cable? Any help would be greatly appreciated.

    aberrant_soul wrote:
    I've read that I would have to use a mini-TOSLink cable to use the optical digital out,
    but how do I go from that to the RCA on the back of the monitors?
    No, the AV 40 inputs are line-level analog RCA; they 'don't understand' digital audio,
    and the conversion requires more than a cable -- you'd need an D-to-A converter.
    You could run an analog signal to the monitors with just a cheap miniplug-to-RCA
    (analog) adaptor from Radio Shack; but if you want to use the iMac's digital output,
    you'll need some sort of external digital-to-analog conversion hardware.
    I don't know of any inexpensive stand-alone TOSLINK-to-analog converters, but
    there are many USB-to-audio products that would allow you to feed digital audio
    from the iMac to the AV 40's -- but through a USB port, rather than TOSLINK.
    Search for "USB audio" on amazon.com and/or newegg.com.
    Looby

Maybe you are looking for

  • How do I install the Safari web browser on my iPad?

    How do I install the Safari web browser on my iPad?

  • Windows 7,  Adobe Acrobat and the HP DesignJet 5000 PS

    We have users that connect to a networked DesignJet 5000 PS to print  out design documents. One of our users was recently upgraded to Windows 7  and is now unable to print from Adobe Acrobat. When  the user attempts to print, the print dialog box app

  • Nested for loop in the collections

    Hi Experts, collection1 ============ SELECT o.object_id       BULK COLLECT INTO l_obj_info         FROM (SELECT     n.node_id, n.object_id                     FROM nodes n               START WITH n.node_id = 100               CONNECT BY PRIOR n.node

  • Connection to https AEM URL (SSL)

    Hi, I am not able to connect to AEM (5.6.1) version from Adobe Drive 5. Please help. URL : https://dam.corp.abc.com

  • Sync contact, calendar, massage. etc from iPhone to iTunes?

    My old computer died and i got new one so, I synced apps, music and ringtoon  everything goes fine, but I want to update my iPhone but the problem,  if I update my iPhone all my massages, contacts, notes and calendar will removed, please help!