High Accuracy Analog Input,Data Acquisition Modules questions

At present,i produced a Data Acquisition Modules,but work not well,pls give me some suggestions.i produce according to a product from USA,but i only produce one channel.pls check the link.
http://www.sun-yuan.com/english/readnews.asp?id=71
Thanks for your help.pls send to my email:[email protected]

I haven't done this with NI-DAQmx, but I assume Read.vi works the same way as it does with traditional NI-DAQ.  The way I do it is to give Read.vi the number of samples that it will read in 1 second.  For example:
4 channels, 1000 Hz, read 4000 samples in Read.vi
All you have to do to accomplish this is multiply your scan rate and number of channels and pass the answer in as the number of samples to read.  It will always read a second of data, even if it gets behind on one iteration of the loop it can catch up on the next.  I also use a Wait Until Next ms Multiple and wire like 400 to it as not to bog down the CPU.  Then you can just keep track of the elapsed time and stop the loop after 24 hours.  Just be sure to clear the acquisition after the loop now that you're using a continuous acq, otherwise the buffer will overflow.
As I said, this is how AI Read.vi works for traditional NI-DAQ, I'm not positive that DAQmx Read.vi works the same way, but I don't see why it wouldn't.
Message Edited by Marc A on 01-16-2006 05:07 PM
Message Edited by Marc A on 01-16-2006 05:09 PM

Similar Messages

  • How can i avoid phase delay in annalog input data acquisition of multi channels

        I am using a PCI-6251 M Series board and wish to acquire two analog signals and output one analog signal simultaneously.  I have a question about multi-function -synch ai-ao.vi .With this Vi I work out annalog  input of one channel  and   data output of one channel synchronously.I take some  change in the vi which I make the sampling rate and sampling number of input and output channel be equal. But when i increase the input channel from one to two,a problem come that is the data acquired always shift towards one direct which depends on the sampling rate(for example data shift turn left when 250kS/s,right when 200kS/s).  Does the phenomena mean phase delay or lag during accquring data? or mean data loss? how it happen ?
         I wonder if the acquisition on both channels is perfectly simultaneous.I  hope the start of data  acquisition each time be the same all time.
              I would appriciate it  if any comment and suggestion.
                Attachments: modified VI from the Multi-Function -synch ai-ao.vi
                I  delete some part about data processing  in while cycle.vi in additonal file

    The specifications for the PCI-6251 state that it is not a simultaneous sampling board. This means that the board has one A/D converter which is multiplexed between channels. How much time delay is between channels is determined by how the board timing works, but it cannot be less than the reciprocal of the maximum sampling rate. For that board this is 1/1.25 MS/s or 800 ns. The delay could be as much as the reciprocal of your actual sampling rate. You need to look at the detailed specification for the device to determine the intersample delay. Some boards require addditional delay when switching channels to allow the multiplexer and amplifier to settle.
    Perhaps you can sample at a rate that is high enough that the delays produce acceptably small phase shifts. If your signals a deterministic enough, you may be able to calculate the shift and compensate.
    If you need true simultaneous sampling, you will need to check the specifications to be sure that the device you select offers that capability. I took a quick look at NI's web site DAQ search page and that is not a top level search option, but as you start to specify channels and sampling rates it becomse available.
    Lynn

  • Display Continuous Fluctuations in Input Data in Module Pool Screen

    Dear All,
    We are working on a Weighbridge Interface scenario, where the weighbridge is sending data to a digitizer, which is connected to the COM port of a PC. The objective is to read the data from the digitizer, and display in a Module pool screen. However, there is one more requirement: the weight may fluctuate until it stabilizes, and the fluctuations have to be displayed on screen. For example, the tare weight of a vehicle may be 12.4 TON, but when the vehicle is standing on the weighbridge, the weight may vary from 10.4 to 12.4 TON. The idea is to capture the stable weight, so that any discrepancies can be avoided. In the current IT system implementation, the fluctuations in the weight are displayed. But using ABAP, can these fluctuations be captured? For example, we may design a screen containing a field for capturing the weight, and the weight displayed there automatically refreshes as soon as there is a change in the digitizer reading. Is this possible to achieve? If so, how?
    Awaiting answers.
    Thanks and Regards,
    Sid

    Hi Sid,
    just a suggestion for the refreshing of an ABAP screen: you can use class CL_GUI_TIMER, but it only handles whole seconds, i.e. 1 second, 2 seconds and so on, but not 0.5 seconds...
    An example of an ABAP listing could be the following:
    *& Report  ZZAVV001
    REPORT  zzavv001 NO STANDARD PAGE HEADING.
    CONSTANTS: c_yes(1) TYPE c VALUE 'X'.
    DATA: BEGIN OF t_bseg OCCURS 0.
            INCLUDE STRUCTURE bseg.
    DATA: END OF t_bseg.
    data: d_num_bkpf type i,
          d_num_bseg type i.
    PARAMETERS: interval TYPE i DEFAULT 5.  "meaning 5 seconds
    *       CLASS lcl_receiver DEFINITION
    CLASS lcl_receiver DEFINITION.
      PUBLIC SECTION.
        METHODS:
          handle_finished FOR EVENT finished OF cl_gui_timer.
    ENDCLASS.                    "lcl_receiver DEFINITION
    * Global data
    DATA:
      test       TYPE i,
      receiver   TYPE REF TO lcl_receiver,
      timer      TYPE REF TO cl_gui_timer.
    START-OF-SELECTION.
      CREATE OBJECT timer.
      CREATE OBJECT receiver.
      SET HANDLER receiver->handle_finished FOR timer.
      timer->interval = interval.
      CALL METHOD timer->run.
      PERFORM load_data.   "or whatever you have to do to read the weight
      PERFORM show_list.   "or whatever you have to do to print the weight you've read
    *       CLASS lcl_receiver IMPLEMENTATION
    CLASS lcl_receiver IMPLEMENTATION.
      METHOD handle_finished.
        PERFORM carga_datos.
        PERFORM muestra_listado.
        CALL METHOD timer->run.
      ENDMETHOD.                    "handle_finished
    ENDCLASS.                    "lcl_receiver IMPLEMENTATION
    *&      Form  load_data
    *       text
    FORM load_data.
      clear: d_num_bkpf,
             d_num_bseg.
      select single count( * )
        into d_num_bkpf
        from bkpf.
      select single count( * )
        into d_num_bseg
        from bseg.
    ENDFORM.                    "load_data
    *&      Form  show_list
    *       text
    FORM show_list.
      get time.
      skip to line 1.
      position 1.
      write: / 'Date / Time:', sy-datum, sy-uzeit.
      write: / 'Number of BKPF records:', d_num_bkpf.
      write: / 'Number of BSEG records:', d_num_bseg.
    ENDFORM.                    " show_list
    Okay, it's just a tiny code snippet, but I hope it may help you by designing auto-refreshing screens.
    Kind regards,
    Alvaro

  • Why is the Analog Input data incorrect when VI is restarted?

    In the attached Read Temp.vi I get correct data the first time it is run. Once stopped and then restarted the data values are incorrect. If I remove TS-1 from the I/O channel list then correct data is reported even when rerun. Why do I get incorrect data when I rerun and have TS-1 in the I/O channel list?
    Attachments:
    AI_Read_Anomaly.llb ‏42 KB
    VPTS_Rev_2.daq ‏27 KB

    Hello,
    Which version of NI-DAQ are you using. try to upgrade it to version 6.9.2 available free from National Instruments website and see if it helps. It should.
    Please tell me if it does not help.
    Sincerely,
    Sastry V
    Applications Engineer
    National Instruments

  • DAQmx example "Multi-Device Synch-Analog Input-Finite Acquisition.vi"

    I'd like to sync 72-channels across nine 6123 cards.  The example quoted above demonstrates how to sync 2 individual channels on 2-cards.
    Other cards e.g. 6561, niHSDIO VIs have examples for Multi-Device that include FOR loop initialisation for Multi-Device synchronisation.  Is there equivalent example code for Multi-Device synchronisation of the 6123 cards ?

    The example to sync here, http://zone.ni.com/devzone/cda/tut/p/id/4322  is similar to the example shipped with LV8.5.1
    for clarity, the code of the two examples as are added as .jpg's to the post.
    Are both examples fundamentally doing the same thing ?  "Sharing a Master Timebase" from one of the 6123 cards, and "using PXI Star Trigger to Trigger all cards simultaneously" ? 
    For 72-channels, would I need to create a huge diagram with 72 parallel paths ?
    Attachments:
    20090716_6123_sync_a.jpg ‏65 KB
    20090716_6123_sync_b.jpg ‏193 KB

  • Analog input(sound) to SD card Module NI 9802 using cRIO 9023

    Hi,
    I am using cRIO 9023 ,NI 9802, NI 9215 and NI 9269 modules, I have acquired an analog input from the module and give it to the Analog output module, the output which I have taken is an audio signal(sound *.wav file) and want to save this output to the SD card module. I am unable to create the wav file in the RT cRIO and that's why I am facing problem in saving the data into the SD card.
    I have the followig queries:
      How can I convert the output to wav file which I have already acquired from the output module.
      How can I save the converted wav file into the SD card module.
    If anybody have already worked and have some knowledge kindly share with me.
    Regards,
    Ather

    Here is an example VI that ships with LabVIEW that may help.  You can change the Write to Text File to Write to Binary File.
    Applications Engineer
    National Instruments
    Attachments:
    9802.zip ‏5 KB

  • DAQPAD 6020e misses digital triggers during analog input (AI)

    I am using a 6020E BNC DAQPAD to acquire two seperate 12kHz analog signals from a sonar through ACH0 and ACH1. The sonar generates a digital start trigger at the start of each ping to notify the DAQ that new data is to follow and i am using this to trigger my application through PFL0/ TRIG 1. Typical trigger repetition rate required/generated by the sonar is 20-30Hz but is selectable. My problem is that the board/software misses complete analog input data pings when the digital trigger repetition rate goes above 2-3HZ (ie I only receive 10% of the pings I desire). Analog sampling rate is 45kHz and I am acquiring 1-2kSamples per triggered acquisition. The problem happens using a Labview application based o
    n a modified version of the shipped "Acquire N - Multi Digital Trig.vi" (and original). Any suggestions welcomed.

    Hi,
    I believe that the problem you are having is due to using the pause function to pause the acquisition before the next trigger and the fact that DAQpads do not have a DMA transfer mechanism. The default setting is to create an interrupt when the onboard FIFO buffer is half full. So when the pause trigger occurs there will always be data left on the FIFO, up to a half buffer of data.
    To work round this problem you can use an external stop trigger instead of the pause.
    Or it is possible to change the data transfer mechanism to cause an interrupt on every sample acquired instead of every half FIFO buffer. This will send every sample acquired by the DAQ board to the computer. The drawback is this method is very processor intensive and significantly slows
    down data acquisition rates. As you are approaching the sampling limit of the card (100Ks/s or 50Ks/s for 2 channels) you may find that you will get buffer overflow.
    To change the interrupt setting use the "Set DAQ Device Information.vi", which is located on the Functions Palette » Data Acquisition » Calibration and Configuration. See the LabVIEW help for information on using this VI.
    Kind Regards
    Tristan J
    Applications Engineer
    National Instruments

  • ELVIS Scope and Analog input triggering

    Hi everyone,
    I'm trying to read two waveforms, one from the analog input and one from the scope. These waveforms are coming from two sides of a voltage divider and should always be in phase. But I think that there might be a triggering problem. When I change the frequency of the input waveform, my measured waveforms go out of phase.I have programmed each express VI to trigger off of the SYNC.
    I can't use analog inputs for both measurements because the sampling rate is too small. I can't use the scope for both inputs because one of the waveforms is a differential measurement.
    Any help would be appreciated, thanks.

    Hi, I looked at the ELVIS Hardware User Manual and noticed that you have 12 channels that can be used as differential, Reference single ended or non reference single ended. Unless you have them all busy I don't see why you can't use the analog inputs. About the sampling rate, it will be determine by the M Series DAQ device that you are using and the source of the signal. It is a good practice to sample, at least, 10 times faster than the frequency of the input signal. The documentation of the card should show what the maximum sampling rate is.
    Now, Open the example called "Multi-Device Synch-Analog Input-Cont Acquisition.vi" at the NI Example Finder under Hardware Input and Output»DAQmx»Synchronization»Multi-Device. If you get the same results shown in the picture then you need to analyze if the voltage divider is affecting the phase.
    For more information about synchronization check the article called "Synchronization Explained".
    Good luck!
    Alejandro | Academic Program Engineer | National Instruments

  • Data acquisition with highly accurate GPS time stamping (hh:mm:ss:sss UT)

    A research group has developed a data acquisition system dedicated to daily observations of solar phenomena at radio waves using high time resolution (5-100 ms).
    First, the analog signal from the antenna (1000-2500 MHz) is sent to a spectrum analyzer (HP8559-A). After that, the analog signal is digitized during 5 minutes in a NI USB-6009 device connected to the PC, before to be stored in a file. By that time, other acquisition data cycle is restarted and so on up to the end of day.
    However, we need timestamp (UTC) the solar data at the beginning and end of each sample of 5 milliseconds, during all acquisition process, in order to have the UTC time information of recorded solar events. So, a time resolution of at least 1 ms is required.
    A software permit us to read recorded data and visualize corresponding spectra during last 5 minutes. However, we need UTC time information in the format hh:mm:ss.sss UT. Then, UTC millisecond is important for us, but not available yet.
    To solve this problem, we are searching for a high accuracy timing GPS receiver (on the order of microseconds or nanoseconds), with at least three significant digits of precision (UT time in milliseconds) and which give us the UTC signal at least each 5 milliseconds or even better (1 ms). However, most GPS receivers only outputs 1 PPS (Pulse Per Second = 1000 millisecond).
    Then, we are open to a better addressing on how to solve this problem !!
    We know that GPS time synchronization with PXI-6608 can be used to precisely timestamp data acquisition, but we have to solve this problem with a lower cost. Also, we require a PCI interfacing instead of PXI.
    Do we have to use a timer card? How do we use a timer, GPS and USB-6009 to timestamp data acquisition? Does the NI PCI-6602 solve the problem?
    Obs:
    The data acquisition software was developed in C++ Builder to run on a PC (Pentium III 2 GHz) under Windows XP environment. We used the NI-DAQmxBase driver to sample the signal from the NI USB-6009.
    We are sure your expertise can help us on this matter.
    Regards,

    I better explain my problem in the thread How to timestamp continuous analog data acquisition using USB-6009 and GPS timing board?
    We are considering to use the PCI-1588 or a GPS timing board (low-profile slot too), but I´m not sure that the USB-6009 can be used to solve the problem.
    How to syncronize the data acquisition and timestamps using USB-6009 and PCI-1588 with external GPS?
    In other thread I would appreciate any suggestions for GPS timing board and PCI-1588 too.
    Regards,
    Lilian

  • How do I acquire multiple signals in the NI cDAQ 9172 using 2 analog input modules?

    Hi everyone,
    Is anyone familiar with using the NI cDAQ 9172?  This is my first time using it and I am not sure what exactly I am doing wrong... Alone with a NI 9233 analog input module, it works great.  I can grab my 4 signals from each channel and go.  However, when I add another analog input module to the mix, it gets an error.  It looks like it is reading only one and not the other.  It bombs at one of the DAQ start task and read task.
    Basically, the block diagram is just a double of the one 9233 working alone.  Is there something needed for input to make the 9172 working?  Any ideas?
    Any help is much appreciated.  Thanks!!

    Hi Jud,
    Both threads are correct.  The cDAQ-9172 has a single analog input timing engine, so both of your analog input modules will need to be in a single task.  The other VI you referenced shows one analog input task (with channels added from two modules) as well as an analog output task.  Analog output has a separate timing engine from analog input, so both of those can run in parallel independent tasks.
    The beginning of this thread is a good example; a single DAQmx Create Task followed by a DAQmx Create Virtual Channel for channels from each module.  Also, Getting Started with NI-DAQmx will give you the fundamentals for data acquisition, though I don't know how many of their examples use CompactDAQ.
    Regards,
    Kyle

  • Problem with the analog input acquisition in labview fpga 8.5.1 and CRIO

     Hello all,
       I am using NI CRIO 9104 RT controller with 9014 FPGA chassis.I am using an Analog input module 9205.My problem is with the acquisition.I am using a
    function generator which generates some sine wave of -1 to 1 ,5hz to125khz sine signal and i have connected to 9205 in rse mode.In FPGA vi i had placed the I/O node and placed an indicator(data type FXP).If i connect the i/o node to a chart or graph,i am not able to see the output.?How this problem can bbe solved
    Next i had placed a FIFO in DMA transfer mode of depth 1023 which will accept the U32 datatype,so i did some manipulation as mentioned in a tutorial.
    Now in RT VI i am reading the same data from the buffer in U32 and doing the reverse manipulation i am able to view the data.Now the problem is ..if i am
    increasing the frequency of the input signal,the data is completly lost ?How can i overcome this problem...
    thanks in advance,
    srikrishna.J
    Analysis Engineer,
    Neurofocus

    Difficult to see where is the problem ....
    Be sure you are doing a good RT system by grabing reference design examples
    Don't forget to specify the DMA FIFO size in the RT code
    Doesn't matter the size of the DMA size under the FPGA project explorer.
    Upload your code, You will get answers...
    Mathieu

  • Can the analog inputs be daisy chained to measure higher voltages?

    Can the analog inputs of a PXI-6289 be connected in series to measure higher voltages than normally allowed at the analog inputs of the PXI-6289 (i.e. 10 VDC)?  For example, let's say I wanted to measure 18 VDC using an analog input channel of the PXI-6289.  I would then pick two AI channels and connect the positive of one to the negative of the other and then the two remaining leads would be placed across the 18 VDC.  Resistors could also be placed across the 18 VDC to form a votage divide.  One AI would measure the voltage across one resistor and the other AI would measure the voltage across the remaining resistor.  I have tried this and the voltage measurements appear to loose accuracy.  Thank you for your help.

    Hello Rafi,
    You may want to invest in a high voltage attenuator for signal conditioning prior to reading the signal.  The documents below may also be helpful:
    High Voltage and Isolated Measurements
    http://zone.ni.com/devzone/cda/tut/p/id/10693
    High-Voltage Measurements and Isolation
    http://zone.ni.com/devzone/cda/tut/p/id/3410
    Regards,
    Roman Sandoval | National Instruments | RF Systems Engineer

  • "Chassis Temperatur​e" in Analog Input Module for FPGA (cRIO-9201​)

    I have just gotten my cRIO with a analog module (9201) and a digital output module (9472).
    When I place an Analog Input Module on my block diagram and double click it, I can choose from the following inputs:
    Channel 0 through Channel 7
    AND
    Chassis Temperature
    I have tried to find any documentation for this "Chassis Temperature" but so far without success.
    If I read this input and feed it straight to an indicator, I get values in the range of 120 to 150.. Now, without more information, this number is rather useless. Does anyone know how to transfer this data to a temperature (either in the Celcius scale or the Fahrenheit scale)?
    Thank you!
    Project Engineer
    LabVIEW 2009
    Run LabVIEW on WinXP and Vista system.
    Used LabVIEW since May 2005
    Certifications: CLD and CPI certified
    Currently employed.

    I still did not find any documentation for this "feature" but I lucked out and found the following:
    in the folder: \labview 7.1\examples\FPGA\CompactRIO\cRIO-910x\
    you should have a file called:
    cRIO-910x support files.llb
    in this there is a convert to temperature vi.
    To get the raw data as a temperature, it looks like all you have to do is divide the binary data by 4 and the answer will be in Celcius.
    Project Engineer
    LabVIEW 2009
    Run LabVIEW on WinXP and Vista system.
    Used LabVIEW since May 2005
    Certifications: CLD and CPI certified
    Currently employed.

  • Trig an analog input with NI6115 through digital data sent by NI6534

    Hello,
    I have 2 NI cards: NI6534 (master), NI6115 (slave)
    I have succeeded to do the following point:
    The slave wait a trigger given by a generated pattern data through NI6534 to start an analog acquisition
    (I noted that the start of the analog acquisition is delayed by 100 ns, is that normal?)
    Now I want to delay the analog acquisition (let's say by exactly 5.0 microseconds)
    Any idea how to do that
    Loranger

    Loranger,
    The delay you are seeing is expected. When using a trigger pulse to "trigger" acquisition on another card, there will be a small delay. Usually the card will actually "trigger" within 1-2 ticks of the timebase clock after the trigger pulse is received over the RTSI line. 2 ticks of the timebase on the NI6115 (timebase of 20MHz) corresponds to 100ns.
    In regards to delaying the analog input aquisition; this is what I would suggest. I would have the trigger from the NI6534 go to a counter on the NI6115. You could program the counter to generate a delayed pulse (5 us) when the trigger from the 6534 is received. The output of the counter could then be used to trigger the analog input acquisition. This should work for you. I hope this helps.
    Todd
    D.
    National Instruments
    Applications Engineer

  • How to read data from analog input and export it to a file using Components Works

    I've made a simple application (Delphi 5 using the activeX) that read data from analog input channel 0. After I read the data, I want to export it to a file using the Components Works on a 6035E NIDAQ. (I'm not using labview and don't want to use it)
    How can I do that???
    Regards,
    Francis

    Here's a sample code to do this...
    P.S.: If you read only one channel this code won't work.
    function MyFunction: Integer;
    var
    Low, High, i, j, ChannelCount, RowCount: Integer;
    Po: P;
    begin
    //you are reading multiple channel
    ChannelCount := VarArrayHighBound(Buffer, 1);
    RowCount := VarArrayHighBound(Buffer, 2);
    for i := 0 to ChannelCount do begin
    for j := 0 to RowCount do begin
    WriteToDisk(Buffer[i, j]));
    end;
    end;
    end;

Maybe you are looking for

  • Creative Cloud is Stuck on the InDesign Install

    I am running Creative Cloud. During the install of InDesign the CC app asked me to shut down a copy of Adobe Acrobat. I shut Acrobat down but Creative Cloud is stuck on the InDesign install. I shut down CC and restarted it but it is still stuck. Is t

  • Shift is not opening file on EHD and I don't have privileges : (

    It is embarressing how much trouble I am having with iTunes. I have put my library on an EHD (correctly through consolidating), and I understand I should start iTunes while pressing shift. But this is not properly directing iTunes open the music fold

  • Make graphics in a datagrid "clickable."

    Can you place a clickable graphic along side text in a datagrid?  Each graphic does something different (runs a function to load a selected swf)If so, what might be a good approach? It would look something like this: DataGrid 1.  Some Text with a gra

  • System using a big percentage of CPU

    My mac is very slow. I launched safari but the system is using more tham 60% percent of CPU, while the user it shows using 30%. How can I make it get better and faster? I have already cleaned safari cache and history. What I have to do to get down th

  • G/L accounts linking with sales tax and VAT

    Hi gurus,          I want to link the G/L account with Sales tax and VAT for this wat i can do and where,plz help me, it is very urgent. Regards, Dharma.