How to save data quickly to the high sampling frequency

Hi all

I use a structure of producers and customers to measure and record the data. The sampling rate must be as high as 10 kHz. Given that so much data, it takes a long time before the data is saved. At first, I saved the data in an excel sheet. Then I tried to save it in binary, but it still takes a while to complete save. How can I make the time savings a short circuit?

Thank you

The best

First we will make some corrections to your DAQmx code.  Since you are using continuous sampling, do NOT connect the samples per channel.  Which is actually limiting your buffer.  And there is really no need to define your buffer size either.  It is default to very big, so this isn't a problem as long as you read your data quite often.

Now your data connection... You simply create a very wide range while acquiring data.  Then, you save the data.  It's actually not through the advantage of using the producer and the consumer.  You should save your data in the loop of the consumer.  It will be elinate need a lot of memory and you save the data to the file while you are buying.

But, in this case, I say that the producer and the consumer is not even necessary.  Use the DAQmx Configure registration VI.  With this VI, you can tell DAQmx to disseminate all data directly in a PDM file.  You don't have to do anything.  It is by far the best way to save on your DAQ data.

Tags: NI Hardware

Similar Questions

  • Save the high sampling rate data

    Hello!

    I use NI PXI-4462. (204.8kS, input analog 4 / s sampling frequency)

    I want to collect data from "load" (channel 1) and "acceleration sensor" (2nd, 3rd, 4th channel).

    I also want to save data to a text file.

    So I do a front pannel and block diagram. You can see in the attached file.

    The program works well in a low sampling rate.

    However, when I put up to 204800 s/s sample rate, the program gives me "error-200279".»

    I don't know what means this error, and I know why this happened in the high sampling rate.

    I want to know how I can fix it.

    Is there any problem in my diagram?

    Is it possible to save high sampling rate data?

    I really want to samplling more than 200000 s/s rate.

    I would appreciate if you can help me.

    Thank you.

    NH,

    You have provided excellent documentation.  So what has happened is that the amount of time it takes to run the other portion of the loop results in a number of samples to be taken is greater than the size of the buffer you provided (I don't know exactly what it is, but it will happen at high frequencies of sampling high) resulting in samples are crushed.  You might be best served in this case to take a loop of producer-consumer - have the loop you have acquire the data but then have an additional loop that processes the data in parallel with the acquisition. The data would be shipped from the producer to the consumer via a queue.  However, a caveat is that, if you have a queue that is infinitely deep and you start to fall behind, you will find at the sampling frequency, you specify that you will begin to use more and more memory.  In this case, you will need to find a way to optimise your calculations or allow acquisition with loss.

    I hope this helps.  Matt

  • How to save data from the COM port to file?

    Hi all

    can someone tell me please how to save data from the COM port on file? I transfer 1 byte of serial port... attached is the image of the vi... very basic.

    I would like to save the data in a table... I mean, 1 data--> data--> data tab 2 tab 3rd--> tab

    and so on... can anyone help?


  • How to display date / time in the browser console?

    How to display date / time in the browser console?

    You can set through the Options (gear icon) page in the Web Console (Firefox/tools > Web Developer).
    This applies to the browser console and the Web console.

  • How to save an image in the body of an email?

    How to save an image in the body of an email? All I get is exemplary, not save as.

    How to save an image in the body of an email? All I get is exemplary, not save as.

    ===========================================
    Take a look at the following articles:

    Open or save an attachment in Windows Mail
    http://Windows.Microsoft.com/en-us/Windows-Vista/open-or-save-an-attachment-in-Windows-Mail

    Parts attached email Windows Live Mail - open and save
    http://www.webdevelopersnotes.com/tips/windows_live_mail/windows_live_mail_attachments_open_save.php

    Volunteer - MS - MVP - Digital Media Experience J - Notice_This is not tech support_I'm volunteer - Solutions that work for me may not work for you - * proceed at your own risk *.

  • How to save data in the text file of Spartan 3

    Hi all

    I would like to kindly save the data table text file or a spreadsheet on vi using fpga spartan 3e as an fpga target. Once I added all the functions related to the operation of file, it gave an error that these functions are not supported by the target device.

    could you please help me with this

    Thank you

    Rania

    Hi David,

    Thank you for posting. You use LabVIEW? If so, what version of LabVIEW FPGA do you use? You use a host VI, or any deployment of code at your target to run? The file IO VI probably won't compile to target because they are not intended to be used on your host computer. Resources and the paths of files do not exist on the target FPGA, but rather on the side of the host. I have included a link below that describes how to transfer data between the FPGA and host. I hope this helps!

    http://zone.NI.com/reference/en-XX/help/371599F-01/lvfpgaconcepts/pfi_data_transfer/

  • How to save data in the spred sheet file that is?

    Hello

    I want to save a table in the same spred sheet file I read my external device.

    here as an attachment, I enclose the vi.

    This is the example of data I want to save for example in the first column I want only numbers with no floating point.

    and remaining column is everdata, it should be the same.

    As an attachment, file name 11 is the same file that I want to, but I always get as file attachment 2,

    can you please guide me how can I get data that is displayed in the table of labview.

    Thank you much in advance.

    This code - using the Format to a string - creates a very similar to the log file output 11. You can write the string to a file with write a text file or write the string array with write to File.vi of the worksheet.  Write to File.vi of the worksheet internally converts an array of strings for what is in the string, and then wrote this text, so it makes more sense to use only write to text file. Write to Spreadsheet File.vi help will make additional copies of the data, which can become a problem if the dataset is large.

    Read the detailed help for Format string for more information on the available format codes.

    Lynn

  • How to save external files in the logical project?

    Didn't know how to phrase the question. Here's the question. Ex: someone sent me an audio file to add to my project of logic and I have it drag my desktop and everything is all fine and good. I save the project, and then proceed to remove the audio file from my office. I then go back to open my logical project and it says that it cannot find the file. In Garageband, once I recorded an audio file project, it is always there even if I deleted it from my office. But in the logic, it does not do this. Is it sort of permanently save/integrate a file in a project of logic, so that I can remove from my desk and there not try to pick him up every time at the opening?

    Hello

    You must have the logic to copy the files:

    For new projects, use file > save and make sure that "Copy the following files to your project" is enabled for audio files.

    For existing projects, or file > save as, then check the same box

    or

    File > project settings > active

    TDC

  • How to save data to file (.xls)

    I need save data in the format .xls - Microsft Excel... LabVIEW allows only save it in .xlsx format. You know someone that is possible to save the .xls file? Thank you for your help.


  • How to save data in a txt file.

    Does anyone know why the txt file is empty with no content?

    FILE * f = fopen ("/ shared/documents/save.dat", "w");
    {if(f==null)}
    fprintf (stderr, "Failed to create output. txt\n");
    _exit(2) (1);
    }
    fprintf (f, "Hello World");

    File is created, but the file txt empt without 'Hello World '.

    Ha ha solved.

    fclose (f);

  • How to save a bitmap on the device?

    Hello

    I have a bitmap image, which I have created a few bytes I get from server. Now, I want to save this file on my device. How can I achieve this?

    Thanks in advance

    That's how I saved my image on the device

    FileConnection fconn = (FileConnection)Connector.open("file:///store/home/user/screenCapture/image01.bmp",Connector.READ_WRITE);

    if(!fconn.) Exists())

    fconn. Create();

    OutputStream out = fconn.openOutputStream ();

    Bitmap image = Bitmap.createBitmapFromBytes(tempJpegBuffer,0,tempJpegBuffer.length,1);

    if(image == null)

    System.out.println ("null image");

    else {}

    out. Write (ReceiveThread.tempJpegBuffer);

    out. Close();

    }

    fconn. Close();

    } catch (Exception e) {}

    System.out.println ("Exception:" + try ());

    e.getMessage ();

    }

    and display the image recorded as by peter has mentioned above

    :-)

  • BlackBerry Smartphones Email attachments - how to save an attachment to the device memory or media card?

    I have a BlackBerry 8310 Curve, which we got up to speed up our translation services.  the thing is that we have received a document attached, and we could not know how to SAVE the attachment to either the memory card or peripheral support, which would then allow us to transfer it directly to the laptop to work on.

    The temporary solution we found was to convey the message to a different email address and download it to your computer. For some reason any later we could not attach the document to email the map of media either, so we had to email from the laptop to the blackberry, and then forward it to the client.

    So, my questions are:

    How to save an attachment to an e-mail message OR the card memory or device support?

    How can I attach a document to an email when ATTACH it to does not display the file in the folder? (of course I've already put it there)

    and as a side note

    Why I could open the email attachment I had forwarded to the blackberry, but I could not open the original document (the two word .doc) sent customer e-mail.

    Here are the details of my laptop: Win XP Home edition, Service Pack 3

    lordsnotball wrote:

    I have a BlackBerry 8310 Curve, which we got up to speed up our translation services.  the thing is that we have received a document attached, and we could not know how to SAVE the attachment to either the memory card or peripheral support, which would then allow us to transfer it directly to the laptop to work on.

    The temporary solution we found was to convey the message to a different email address and download it to your computer. For some reason any later we could not attach the document to email the map of media either, so we had to email from the laptop to the blackberry, and then forward it to the client.

    So, my questions are:

    How to save an attachment to an e-mail message OR the card memory or device support?

    How can I attach a document to an email when ATTACH it to does not display the file in the folder? (of course I've already put it there)

    and as a side note

    Why I could open the email attachment I had forwarded to the blackberry, but I could not open the original document (the two word .doc) sent customer e-mail.

    Here are the details of my laptop: Win XP Home edition, Service Pack 3

    Unfortunialy up to what your phone is updated with OS 4.5 the only way is to do it as you have in the past or I'm sure there are some programs that you can buy until you do not upgrade.

  • How to save downloaded and open the PDF directly into my laptop, compared to saving the file in the cloud? Can I remove DC and install Acrobat Reader, which is thin and easier to use for my needs and much, much more secure?

    Somehow, I downloaded and installed Adobe alleged DC update for the existing acrobat Reader installed on my laptop.

    DC app has been a disaster for me in terms of generation of convoluted navigation and extra work.

    In addition, I do NOT trust or want an application based on a cloud because of the deep and hard-learned risk, privacy and security, as well as the occasional loss of connectivity online and access, what urgent needs can get GROUND in terms of use of such an external cloud-based application.

    Issues related to the:

    [1] how to save a PDF downloaded and open directly on my laptop, a report file to save the file in the cloud and then copying it in the folder of the laptop? This process in several steps inside the DC is a frustrating PITA, as Adobe Acrobat Reader has been sufficient for my needs.

    can [2] Alternatively, I remove CD and install the latest version of Adobe Acrobat Reader, which is thin and easier to use for my needs and much, much more secure?

    Thank you very much in advance for the help and deliberate in a timely & the readers attention. Today is Tuesday, November 3, 2015.

    Kind regards

    Stephen H. Franke

    E-mail: shfranke@hotmail... com

    Hi stephenf95557665,

    (1) you can simply save the file on your computer as allows you to save in the older version of the player, it is not necessary to register I your cloud of document.

    If you save the file to the document cloud, you will be able to access any system from anywhere.

    (2) If you still think earlier version users need, then they can probably uninstall the last being & reinstall the old version using this link http://get.adobe.com/reader/enterprise/

    Kind regards
    Nicos

  • How to save a copy of the file? (simple javascript needed)

    I'm a noob, so need a Javascript/installation for InDesign CC script, which runs automatically when a file is openand saves a copy of the document to a specific folder, to the present time (i.e. "c:/file/filename_COPY_6_MAY_2014_23_59_59").

    This code is just for this work? :

    var dmd = app.activeDocument;
    var oldDocName = dmd.name;
    //make new file
    var newDocName = oldDocName.substring(0,oldDocName.length-5); //removes ".indd"
    var dd = new Date;
    var NewFile = new File("/c/backups_folder/" + newDocName + dd.getDate() + "_" + dd.getMonth() +  "_" + dd.getHours() + "-" + dd.getMinutes() + "-" + dd.getSeconds() +".indd");
    //copy
    oldDocName.copy(NewFile);
    
    
    
    
    
    
    
    
    
    

    Hi all

    I don't think that the link you have provided on stackflow meets your problem and certainly not the best way.

    Hopkins response for sure does not seem be correct (sorry)

    I think that my script below is the best method.  Don't lead to annoying delays in file open.

    Put it in your startup script file

    Trevor

    // https://forums.adobe.com/message/6363852#6363852
    // By Trevor
    #targetengine document_copy
    (function () {
        if (app.eventListeners.itemByName ("saveCopy").isValid) app.eventListeners.itemByName ("saveCopy").remove(); // makes debugging easier and prevents multiple eventListener creations
        var mySaveCopyEventListener = app.eventListeners.add("afterOpen", saveCopy);
        mySaveCopyEventListener.name = "saveCopy";
    }) ();
    
    function saveCopy(ev)  {
        if (ev.target.constructor.name !== 'Document') return;
        saveCopy.Folder = "C:/backups_folder/"; // Change as needed
        if (!Folder (saveCopy.Folder).exists) {
            Folder (saveCopy.Folder).create();
            $.sleep(300);
        }
        if (!ev.fullName.copy (new File (
            saveCopy.Folder + // folder name
            ev.fullName.name.replace(/.[^.]*$/,"") + // file name without suffix
            (" " + new Date).replace (/:/g,"\xB7").replace(/\s\S+$/,"") + // date Change format as desired
            (ev.fullName.name.match(/\..+$/) ? ev.fullName.name.match(/\..+$/).toString() : ".indd") // suffix could be idml or who know what
            ))) alert ("Something messed up, a copy was not made");
    }  
    
  • How to recover data up to the current timestamp

    The emp table I want to recover data up to the present time how can I do that (until the second current)

    This link will help

    http://www.Oracle.com/technetwork/issue-archive/2012/12-Jan/o12plsql-1408561.html

Maybe you are looking for