How to synchronize analog input and output from two different USB daq boards

Hi all,
I have two very differnt USB boards the NI USB 6008, which I am using to acquire the data (Analog Input) and a NI USB 9263, it is an Analog Output only board that I am using to deliver a signal (in this case a square pulse). The reason why I am not using the 6008 Analog Ouputs is because I need to deliver negative voltages and need the full +/-10V range.
Looking at similar posts I am pretty sure that I can't use an external trigger or a shared clock, I also tried to use the synchronization of timed structures but no cigar.
I am including a quick vi that I whipped out showing how the signal jitters due to the lack of synchronization. The AO from the 9263 connects to the AI in the 6008 in this example.
Solved!
Go to Solution.
Attachments:
Test Pulse.vi ‏117 KB

I talked to a specialist in the phone and tols me that it is not possible.

Similar Messages

  • Comparing digital input and output from two different DAQs

    I want to create this program where the digital output lights up LEDs at random and push buttons are the digital input part of another DAQ are pushed. When the correct button is pushed, the score will increase by 1. My code doesn't work though. Can someone point my errors to me? Both the DAQs i'm using are USB-6008 DAQs. thanks
    Attachments:
    Untitled 1.vi ‏41 KB

    Let's start with the digital output
    What is this code all about?
    Do you want only one of the 8 led's to lit randomly or are multiple led's also ok?
    The two possible codes are in attached file SNAG-003.jpg
    Connect the output of the "Scale by power of 2" function or the "Multiply" output directly to the Write DAQmx vi
    I don't understand the purpose of the "Boolean Value" and "Replace subset array" thing, so I skipped it
    Attachments:
    SNAG-002.jpg ‏49 KB
    SNAG-003.jpg ‏22 KB

  • Analog Input and Output in One Single VI

    I need help in setting both analog input and output in one single VI. How do I assign channels to be either input or output? How do I simultaneously uses both in one single VI with a while loop structure?? Which AO am I suppose to use to obtain signal from the function generator I have built to feed into the DAQCard-1200?? Help!!
    Attachments:
    Test1.vi ‏48 KB

    One thing you'll need to be aware of is that you will need to DMA lines: one for AI and one for AO. If you don't, then you can configure the DAQCard to do without DMA using the Config VI. But you certainly can do this.
    As far as your function generator, you will want to do a buffered analog output. You will write your buffer of points to the buffer, and then tell NI-DAQ how fast to update your analog output channel with these values.
    So, you can be reading from AI and checking the AO process in the same while loop. Just make sure you handle the while loop execution (the wait it exits) correctly. This can get tricky when you're doing two types of measurements.
    J.R. Allen

  • How to change the input and output schema in BPEL process

    hi',
    Please tell me how to change the input and output schema in BPEL process after the process is made.
    thanks
    Yatan

    If your intention is just changing the content you are passing to bpel/returning from bpel
    Here is another way
    just update your default created xsd files with new elements, update wsdl elements in message definition and chnage bpel code to reflect new elements in activities
    Regards,
    Praveen

  • How to view the input and output layouts created in the planning folder?

    Hi all,
    How to view the input and output layouts created in the planning folder in the bw 3.5?
    Thanks
    Pooja

    Hi,
    You can refer to this link. How to create planning folder and executing the planning folder.
    http://help.sap.com/saphelp_nw04/Helpdata/EN/5d/7c4b52691011d4b2f00050dadfb23f/frameset.htm
    Hope this helps

  • How to control (the input and output) EXE file after I call it using exec?

    Hi,
    I knew that I can use runtime.exec() to call one EXE file, and this works. But this EXE has two characteristics:
    1. After this exe starts, it asks user to input number such as 1 or 2 onto computer screen, then press return. Then the exe will start the calculation.
    2. after it starts calculation, it prints 3 columns of numbers onto the screen.
    My two questions are:
    1. How to use java to input the number such as 1 or 2 automatically? this EXE can not work like this in DOS command line:
    C:> file.exe parameter
    The parameter is the number such as 1 or 2 that I wanna input.
    2. how to redirect the 3 columns of numbers from computer screen to txt file?
    My colleague can solve these two questions using Mathematica. So I know that definitely there is at least one solution for it. I just can not do it using Java. This wierd exe file bothered me a lot and I really wish that I can get help from someone in java community.
    Thank you!
    Tony

    When you call Runtime.exec, you get a Process object. (I presume something similar happens when you use ProcessBuilder.) Process has methods with names getOutput, getInput, and getError. These correspond to the standard input, standard output, and standard error streams of the spawned process.
    You can read and write to the process on the streams corresponding to input and output that the process writes to the console.
    [add]
    In fact, you should be grabbing and reading the output/error streams anyway, because of the points raised by the Traps article. Google "Java Runtime exec traps" and you'll probably get a link to this JavaWorld article, which describes common Runtime.exec problems and how to solve them.
    Edited by: paulcw on Jun 15, 2010 4:09 PM

  • Synchronizing analog input and output

    I am in the middle of converting some Traditional NI-DAQ code to the
    DAQmx API (I am using C++).  Most of it is going quite well: my
    code complexity has been greatly reduced and (since upgrading to 7.4)
    my CPU usage has plummeted.  However, in one particular case I
    need my input and output buffers to be synchronized.  I.e. sample
    0 of my input buffer should be read at the same instant sample 0 of my
    output buffer went out on the line.  In Traditional NI-DAQ, I
    synchronized my input and output start triggers using the following
    method (which I believe I found in an example somewhere):
    error = Select_Signal(addr, ND_PFI_6, ND_OUT_START_TRIGGER, ND_LOW_TO_HIGH);
    error = Select_Signal(addr, ND_IN_START_TRIGGER, ND_PFI_6, ND_LOW_TO_HIGH);
    This then allowed me to setup my input thread, then initialize
    everything in my output thread and when my output got the start
    command, so did my input.  The result was that I could perfectly
    match buffers of output data to buffers of input data (after taking all
    the appropriate buffering into account).
    When I try the same method with the DAQmxConnectTerms function, my
    buffers don't line up.  They are off by 15-20 ms out of a 400ms
    buffer (sampling at 10kHz).  I tried cutting out the middle man of
    PFI6 with similar results.  So my current "synchronize" block
    looks like this:
    error = m_fnConnectTerms("/Dev1/ao/StartTrigger", "/Dev1/ai/StartTrigger", 0);
    I get no error.  This also seems to cause my output loop to hang
    after a few seconds, although that could be a side effect of something
    else that I haven't tracked down yet.  Is there a better way to do
    what I'm trying to do here?  Perhaps it is a misunderstanding of
    the way buffering works on the M series cards (I am currently using a
    6221).

    Don't use Connect Terminals. Use the technique shown in this example program
    C:\Program Files\National Instruments\NI-DAQ\Examples\DAQmx ANSI C\Synchronization\Multi-Function\ContAI-Read Dig Chan
    which is the sharing of sample clocks via the DAQmxCfqSampClkTiming function where the sample clock source of one task is set to the clock of the other task.  This example slaves a digital input task to an analog input task but the idea is the same for your application.

  • XiFi and Audigy Take Over Input and Output from Bluetooth Head

    I am having trouble with my bluetooth headset when making phone calls in any VoIP application (Skype, Yahoo!). I usually use the headset as the input and output for my VoIP bits so I can move away from my desk, etc... First, it worked under XP with my Audigy no problem. I bought a XiFi and installed the latest drivers and it began stealing my audio. Oddly, it does not do it until the call connection is made (so I hear the ringing in the BT headset and once the call is answered the system reverts to the mic, a Logitech USB, and main speakers, directly plugged to the soundcard).
    I decided to put my audigy back in, because I was planning on upgrading to Vista and thought the XiFi may be bad. I did a fresh Vista install with the Audigy and everything worked (i.e. audio for phone calls stayed in my BT headset). I then upgraded from the Microsoft drivers to Creative?s Vista drivers and the problem then happened with the Audigy as well.
    This leads me to believe that some sort of regression happened in the latest drivers. Everything else works great, games, movies, etc? but this is a show stopper because I want to use my bluetooth headset. I tried to downgrade to the Microsoft drivers but the card would no longer work. I have tried a driver install only, then added the software, removed that and did a full install. This is with BETA drivers on Vista, but the problem existed in XP as well which were not BETA drivers AFAIK. I have updated to the latest Bluetooth drivers as well with no luck.
    I have confirmed this on two of my PCs and a friend of mine is having the same problem (XP, XiFi) so he went and bought a Skype phone which works correctly.
    Thanks in advance

    thanks for reply..
    Please help me out with the entire setp by step procedure that i have to follow in getting the output in variable
    i am using to get the emp name from webservices and i am passing empno from form.
    INPUT STRING
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:tem="http://tempuri.org/">
       <soapenv:Header/>
       <soapenv:Body>
          <tem:ALL_GetEmpNamefrmID>
             <!--Optional:-->
             tem:EmployeeLogin>{$ /process_data/@emp_no $}</tem:EmployeeLogin>
          </tem:ALL_GetEmpNamefrmID>
       </soapenv:Body>
    </soapenv:Envelope>
    when i hard coded emp no for testing EG: 1234 the out put i am getting the folloeing XML when i click tes
    OUTPUT:
    <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
       <soap:Body>
          <ALL_GetEmpNamefrmIDResponse xmlns="http://tempuri.org/">
             <ALL_GetEmpNamefrmIDResult>SUBBA</ALL_GetEmpNamefrmIDResult>
          </ALL_GetEmpNamefrmIDResponse>
       </soap:Body>
    </soap:Envelope>
    Please help me out what are the steps i have to follow for getting out put SUBBA to my variable

  • How to set the input and output of a subVI

    I am trying to configure a subVI by following Chap. 7 of "LabVIEW fundamentals". But I stuck at "Building the connector pane".
    My subvi is quite simple, just for testing purpose. I plan to do a summation and display the result. So I placed one numeric Add icon on the block diagram and a numeric Indicator on the front panel. I built a connector pane with three terminals, two for input and one for output. 
    But, how could I associate the terminals on connector pane with inputs and outputs of terminals on the block diagram? I wanna build a subVI, whose input are two numbers and display the summation on the subVI.
    Forrest Sheng Bao, Ph.D.
    Assistant Professor, Dept. of Electrical & Computer Engineering
    University of Akron, Akron, OH, USA
    https://sites.google.com/site/forrestbao/

    Hi Forrest Bao,
    use the right mouse key as often as you can in LabVIEW. It´s very helpful. If you right click on a link in the connector pane, then you can select to disconnect selected or all.
    Mike
    Message Edited by MikeS81 on 08-28-2008 01:33 PM

  • How to print one sales order output from two printers using single command.

    Dear all,
    Our requirement is to print single sales order from two different printers, where as one printout for sales order output and another for sales order cash receipt.
    We developed two smartforms for both outputs.
    But we are struggling to assign the smartforms to single document type, which has to result two printouts after saving the sales order.
    Please help us to solve the issue.
    Your suggestions will be highly appreciated.
    Best regards
    Raghu ram

    Hi,
    You should define two different output type for your requests, one is for SO output, the other is for SO cash receipt. That's okay!
    Good luck
    Z.T

  • Simultaneous Digital Input and Output from NI 9403

    Hi,
    I was wondering if it is possible to digital output through one line in this module(NI 9403) while simultaneously reading from 10 other lines?
    Basically what I need is for line0 to always be closed(true), and read lines1:10 - at very least 1sample/second.
    I have attached a stripped down version of my code illustrating my error. I thought I was getting the error because the two tasks were using different clock configurations, but I tried using the same inputs and that doesn't work for me.
    Any input is greatly appreciated.
    Thank you
    Attachments:
    Digital I-O.vi ‏22 KB

    Hi Matthew,
    The behavior you're seeing is expected for the 9403 module, since it is a serial module. The DAQmx help has the following restrictions in the Digital I/O Considerations for C Series Devices section.
    Timed digital input/output restrictions:
    You cannot use parallel and serial modules together on the same hardware timed task. 
    You cannot use serial modules for triggering. 
    You cannot do both static and timed tasks at the same time on a single serial module. 
    You can only do hardware timing in one direction at a time on a serial bidirectional module.
    So you can only do timed input or output at one time, but not both. However, based on the VI you attached and the description of what you want to do, you don't necessarily need both timed tasks in your loop. You can create a static output task to update that one line and after that, you can just start your timed input task on the rest of the lines. This should maintain the state on the DO line, since you're not acquiring from it.
    Cheers,
    Cristina
    Cristina

  • Multiple Input and Output from a 6534

    Hello
    I am after some advice regarding my PCI 6543 digital I/O card and the best way to achieve my desired results. I am programming in Visual C++ with Ni-DAQ 7.
    I want to generate a pattern output from one of the ports, Port A, following a software command. This pattern consists of a 10uS pulse on DIOA0, that repeats 200 times with a period of 100uS. I want this DIOA0 output line to initiate an input on ports C and D, possibly through the REQ pin. Consequently the input should acquire 200 times for each call to the pattern output.
    I want this to repeat, so the pattern output goes again (as in a FOR loop), and the input occurs again for an as yet undetermined number of times.
    I have managed to get something worki
    ng for 1 iteration, and I can generate multiple pattern outputs, but the inputs only seem to acquire for the 1st iteration. However, if I step through the code in debug mode I can get the input to work correctly.
    Any ideas would be gratefully appreciated.
    I am still trying to get some earlier problems with this application solved.
    Kind Regards
    Jamie

    Hi Jamie,
    There are a couple different ways you can loop from a buffer. You can either use the onboard memory of the 6534 and loop from there or you can specify as a software configuration that the board loop through the PC memory buffer.
    For the onboard looping you need to specify the following:
    iStatus = Set_DAQ_Device_Info (1, ND_PATTERN_GENERATION_LOOP_ENABLE, ND_ON);
    For software, PC memory looping, the following function specifies this:
    iStatus = DIG_DB_Config (iDevice, iGroup, 1, 0, 1);
    I attached a couple programs that might be of use. Check this post:
    http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=5065000000080000008BA10000&USEARCHCONTEXT_CATEGORY_0=_31_%24_12_&USEARCHCONTEXT_CATEGORY_S=0&UCATEGORY_0=_31_%24_1
    2_&UCATEGORY_S=0
    Hope that helps. Have a good day.
    Ron

  • Multithreaded analog input and output and serial communication during the AIAO

    I need to read in analog data on 4 channels (4000 scans/s on each channel for a total of 250ms) and while this is happening send out two signals: A trigger pulse (which I currently send on an analog channel, using channel DAC0OUT) and two ascii commands using the serial port. My problem is that the data acquisition VI I am using is a blocking VI, it runs to completion before allowing the two signals to be sent. I am using the VI titled, "AI Acquire Waveforms (scaled array).vi" I don't need to look at the acquired data until after the whole operation is complete. Any help anyone can offer would be much appreciated.

    Hello Mark,
    The AI Read VI will block other operations when waiting for data. I would suggest to reduce the number of scans to read (this is an input for the AI Read VI) to help with handling multiple operations simultaneously. By reducing the number of scans to read by the AI Read VI, it won't have to wait for the whole buffer to be read in before "unlocking" the CPU for other operations. You could place the AI Read in a loop and acquire smaller chunks of the data at a time. For instance, your buffer size is probably 1000. Instead of calling the AI Read VI once and waiting for all 1000 scans, you could place the AI Read in a for loop and acquire 200 scans at a time (have the for loop run 5 times).
    Or you could set up the AI Read VI to read 0 scans the fir
    st time and then just read whatever is in the backlog on subsequent calls. There is a backlog output to AI Read; you could use this with a shift register within a loop to read only the data that is already in the buffer. For both of these cases, I would place a wait in the loop (25-100 ms) to give the CPU time to do other things.
    Another method is to use an occurrence. Place the Functions >> DAQ >> Misc >> Set DAQ Occurrence.vi on your block diagram and set the "DAQ Event" input to "Fire every n scans" (the actual string is a little different). Then put in a Wait on Occurrence function (Functions >> Advanced >> Synchronization >> Occurrence) When you use an occurrence, you are waiting for the driver to tell you when the data is acquired, rather than constantly querying the driver, so it is much faster.
    One of these suggestions should help.
    Let me know if you have any additional questions.
    Regards,
    Todd D.
    NI Applications Engineer

  • How to display error messages and output from Matlab (which Matlab would typically send to its command window but no longer does when called by Labview) into Labview or allow it to be dumped into Matlab Command Window?

    Using Labview 6i and Matlab 6.1. I want to be able to see Matlab warnings and error messages either in the Matlab Command Window or in Labview itself. Currently Matlab is called by Labview (which is working). However I would like to debug and/or modify my Matlab script file to better understand how the two programs are interfacing. It is difficult since no data or messages can be displayed currently to the Matlab command window. I would like to change that if it is possible - Labview is suppressing that from happening. If not possible to send these
    messages to Matlab Command Window can I make it at least possible to see Matlab's actual warnings and/or error messages in Labview?

    I don't think you can debug your Matlab script from labVIEW. The following webpage talks about this:
    http://digital.ni.com/public.nsf/3efedde4322fef198​62567740067f3cc/19106e318c476e608625670b005bd288?O​penDocument
    My suggestion would be to write a script in Matlab and thoroughly test it before calling the script from a Matlab script node in LabVIEW.
    Chris_Mitchell
    Product Development Engineer
    Certified LabVIEW Architect

  • Input and output from child process

    Hi all,
    I am developing an IDE for the Haskell functional programming language. The application runs the Haskell interpreter as child process, and sends and receives input from the interpreter. At the moment I'm programming the integrated console through which the IDE should communicate with the interpreter. The problem is that when I send a command to the interpreter to execute the code I can't detect when the code is running and when it waits for input, so I'll be able to dissable and enable input in the the console respectivly. Please answer as soon as possible, and if my explanation of the problem is not clear enough please just comment about it. Thank you in advance.

    Generally the way I have seen that sort of things designed is like this: You have a script in mind. For example:
    1. Send command "ABC DEF" to the interpreter.
    2. Wait until it responds with "OK" or "Failed".
    3. If it responded with "Failed" then quit.
    4. Send command "XYZ XYZ" to the interpreter.
    5. ... and so on
    You can do this in simple or complicated ways, of course. But if you can't do it, then you're going to find it difficult to do anything at all. For example you won't know when the interpreter is waiting for input (that seems to be your problem already).

Maybe you are looking for