How to save data acquired from NI-DAQ in text format instead of TDMS using the DAQ-mx ANSI C code?

Hi,
I wanted to save data acquired from NI-DAQ (for example, NI 9234) in a file using the DAQ-mx ANSI C Code. The response I got was as follows:-
One way to do it is with TDMS logging. DAQmx comes with functions designed to log to a TDMS file. This is a special file type that is used for collecting data in a logical format. It can be displayed in a TDMS viewer where data is separated into groups and channels. NI-DAQmx provides examples for how to log to TDMS. Look at the TDMS examples in the C:\Users\Public\Documents\National Instruments\NI-DAQ\Examples\DAQmx ANSI C\Analog In\Measure Voltage directory.
However, now I want to know is there a way that using that same C code, can we save the data in a .txt file format (Text File) instead of a TDMS file? We actually want to access that file through MATLAB (that's why we want to save it in text format).
Also on an other note, is there a way we can access & open TDMS files by MATLAB?
Thanks,
Sauvik Das Gupta

There's a way you can access TDMS files in MATLAB:
http://zone.ni.com/devzone/cda/tut/p/id/7446

Similar Messages

  • Saving acquired data in text format instead of TDMS using the NI DAQ ANSI C code

    Hello,
    I would like to know how to change the code to make it save the file in .txt format instead of TDMS format.
    It would be great if you could help me out with this !!!
    I am attaching the DAQ mx ANSI C code for your reference
    Thanks, 
    Haritha Srinivasan
    Attachments:
    TDMS-Cont Acq-Int Clk.zip ‏1360 KB

    Hello Haritha, Hope you are doing great!
     I think this covers up what you are looking for.
    This has been covered in other forum before, please feel free to check it.
    Regards, 
    LuisA 

  • How to save data model design in pdf or any format..?

    how to save data model design in pdf or any format..?
    i ve created design but not able to save it any mage or pdf format

    File -> Print Diagram -> To PDF File

  • How to copy and paste from excel in Hyperion Planning 11.1.2.2 using the Mozilla 17 as my browser?

    Hi,
    I'm using Hyperion Planning 11.1.2.2.300 and Mozilla 17 as my web browser, and I'm trying to paste a number from excel directly into a cell in a data form in Hyperion.
    ie. after I copy the figure from a cell in excel, I go to a cell in Hyperion Planning and either press Ctrl+V or use the right-click mouse button on the cell where the Copy/Paste/Cut... menu appears.
    Either way the number is not pasted (nothing happens)
    On the other hand, if I double left-click in the cell (which is used for entering values manually in Hyperion Planning) the number if pasted correctly, however this is not a good workaround.
    Please assist.
    Thank you

    Hi, Theresia
    Yes you're absolutely right, I created VR from the manage form's menu. So I use standard HP 11.1.2 functionality. I've seen it in new features while read Oracle documentation. Also with testing of approvals in Proccess managment I use distinct colours for negatives and diff values (greater 1000 and 100 in my example). Colours work fine, but i can't say it about aprovals :). And all these examples of using planning form VR's i've taken from oracle administrators&user guiide and from presentations of EPM 11.1.2
    In addition I've started work with Hyperion products 2-3 month ago. Hence I have to read a lot of information because my previous experience was OLTP, RDBMS not OLAP.
    As a first step i wanna know all standard possibilities of product i use. And also best practice and some often used technics. Many thanks for your idea with Smart list and BR i'll try it (though i use EMPA and Calc Manager rules). I know that soon I have to use Java API's, so I might read and learn Java to write the simplest code first. But for me it's too much info i have to load into my brain in such short period :)
    As a resume, my opinion it's a bug of new features EPM 11.1.2. But maybe I'm wrong cause none has said the same
    Anyway thanks, Theresia, for your help. If you know or will some new additional info i'll say you thanks again
    Best regards,
    Vladimir

  • How to send data coming from modem to a text file

    hi frnds
    I have a modem program in which i can receive sms and call details.What i want is i want to store those msgs to a text file.
    The String variable to which that data is going is in readData() method of some Receiver.java file.
    I tried like this
    FileOutputStream file = new FileOutputStream(new File("modem.txt"));
    Receiver rcvr = new Receiver(); // here i am getting error " the constructor Receiver() is undefined
    String data = rcvr.readData(str);// here error is str cannot be resolved.
    file.write(data); // here i am getting error "Syntax error on token "data", VariableDeclaratorId expected after this token"
    can anyone help me ???

    You need to go and read some Javadoc for all the methods you are trying to call. While you're there have a look in java.io for methods that can write a String.

  • How to save data in ztable after editing in alv report

    how to save data in ztable after editing in alv report?

    Hi,
        Please find the attachment below.This may be usefull to you.
         [http://wiki.sdn.sap.com/wiki/display/Snippets/ALV-Editingandsavingtheeditedvaluesin+Database%28OOPS%29]
    Regards,
    Ramakrishna Yella.

  • How can I Cache the data I'm reading from a collection of text files in a directory using a TreeMap?

    How can I Cache the data I'm reading from a collection of text files in a directory using a TreeMap? Currently my program reads the data from several text files in a directory and the saves that information in a text file called output.txt. I would like to cache this data in order to use it later. How can I do this using the TreeMap Class? These are the keys,values: TreeMap The data I'd like to Cache is (date from the file, time of the file, current time).
    import java.io.*;
    public class CacheData {
      public static void main(String[] args) throws IOException {
      String target_dir = "C:\\Files";
      String output = "C:\\Files\output.txt";
      File dir = new File(target_dir);
      File[] files = dir.listFiles();
      // open the Printwriter before your loop
      PrintWriter outputStream = new PrintWriter(output);
      for (File textfiles : files) {
      if (textfiles.isFile() && textfiles.getName().endsWith(".txt")) {
      BufferedReader inputStream = null;
      // close the outputstream after the loop
      outputStream.close();
      try {
      inputStream = new BufferedReader(new FileReader(textfiles));
      String line;
      while ((line = inputStream.readLine()) != null) {
      System.out.println(line);
      // Write Content
      outputStream.println(line);
      } finally {
      if (inputStream != null) {
      inputStream.close();

    How can I Cache the data I'm reading from a collection of text files in a directory using a TreeMap? Currently my program reads the data from several text files in a directory and the saves that information in a text file called output.txt. I would like to cache this data in order to use it later. How can I do this using the TreeMap Class?
    I don't understand your question.
    If you don't know how to use TreeMap why do you think a TreeMap is the correct solution for what you want to do?
    If you are just asking how to use TreeMap then there are PLENTY of tutorials on the internet and the Java API provides the methods that area available.
    TreeMap (Java Platform SE 7 )
    Are you sure you want a map and not a tree instead?
    https://docs.oracle.com/javase/tutorial/uiswing/components/tree.html

  • Could u plz help me to find simple example for how to save data file in a spread sheet or any other way in the real time controller for Sbrio 9642 using memory or usb flash memory

    Could u plz help me to find simple example for how to save data file in a spread sheet or any other way in the real time controller for Sbrio 9642 using memory or usb flash memory

    Here are a few Links to a helpful Knowledge Base article and a White Paper that should help you out: http://digital.ni.com/public.nsf/allkb/BBCAD1AB08F1B6BB8625741F0082C2AF and http://www.ni.com/white-paper/10435/en/ . The methods for File IO in Real Time are the same for all of the Real Time Targets. The White Paper has best practices for the File IO and goes over how to do it. 
    Alex D
    Applications Engineer
    National Instruments

  • How to save an image from canvas to jpeg2000 format?

    good day! i would like some help about jj2000. i wish to save an image from canvas to a jpeg2000 format file. how will i do it using the jj2000? i just need to save it to a file.
    please help!!!
    thank you in advance!
    lrds

    I am not familiar with Jpeg2000, but the easiest way I've found to go from Java to a JPeg file is with Java Adavanced Imaging (JAI) package from Sun. Take a look at it and see if it meets your requirements.

  • How to read data directly from clusters

    hi all,
    how to read data directly from clusters
    Thanx in advance,
    amruta.

    Using macro:
    RP-IMP-C2-B2.
    RP-IMP-C2-B1.
    RP-IMP-C2-ZL.
    ....etc.
    For TM cluster, U also can use BAPIs like HR_TIME_RESULTS_GET
    More details see SAP HR course 350(HR Programming)

  • How to save datas automaticly making use of SQL Toolkit ?

    Hello !
    I have amounts of datas to be saved automaticly,so I want to use database.I've  registered ODBC data source in my computer.
    As the test datas are saved automaticly,I only write a function to save the datas into database.
    //write datas into database
    void WriteYBdata(char* FileName)
    char *time1;
    char *date1;
    char date[27];
    int hstmt,id,status;
    date1 = DateStr ();
    time1 = TimeStr ();
    Fmt(date,"%s<%d[w4p0]/%d[w2p0]/%d[w2p0]",date1,time1);
    hstmt = DBActivateSQL (hdbc, "SELECT * FROM ybdata");
    DBBindColInt (hstmt, 1, &id, &status);
    DBBindColChar (hstmt, 2, 27, date, &status, "");
    DBBindColFloat (hstmt, 3, &CH4, &status);
    DBBindColFloat (hstmt, 4, &CO2, &status);
    DBBindColFloat (hstmt, 5, &O2, &status);
    DBBindColFloat (hstmt, 6, &CO, &status);
    DBBindColFloat (hstmt, 7, &H2S, &status);
    DBBindColInt (hstmt, 8, &TEM, &status);
    DBBindColInt (hstmt, 9, &HUM, &status);
    DBCreateRecord(hstmt);
    DBPutRecord(hstmt);
    DBDeactivateSQL(hstmt);
    void WritePSMdata(char* FileName)
    char *time2;
    char *date2;
    char date[27];
    int hstmt,id,status;
    date2 = DateStr ();
    time2 = TimeStr ();
    Fmt(date,"%s<%d[w4p0]/%d[w2p0]/%d[w2p0]",date2,time2);
    hstmt = DBActivateSQL (hdbc, "SELECT * FROM psmdata");
    DBBindColInt (hstmt, 1, &id, &status);
    DBBindColChar (hstmt, 2, 27, date, &status, "");
    DBBindColInt (hstmt, 3, &wy_voltage,&status);
    DBBindColFloat (hstmt, 4, &zy_y1, &status);
    DBBindColFloat (hstmt, 5, &zl_i1, &status);
    DBBindColInt (hstmt, 6, &wx, &status);
    DBBindColInt (hstmt, 7, &wg, &status);
    DBBindColInt (hstmt, 8, &ws, &status);
    DBCreateRecord(hstmt);
    DBPutRecord(hstmt);
    DBDeactivateSQL(hstmt);
     I connect the database in the main function.
    I've been debug the program and it communicates normally, but it does not save datas into the database.
    The attachment is my program.It is my first time to use SQL Toolkit and I'm not familiar with it.  I would appreciate it very much if you could give me some help..
    Best regards.
    xiepei
    I wouldn't care success or failure,for I will only struggle ahead as long as I have been destined to the distance.
    Attachments:
    Sava All Data.zip ‏37 KB

    Hi !
    Thank you very much for your reply.
    That line I want to set the time format and it could use the funtion  
    DBBindColChar (hstmt, 2, 27, date, &status, "");
    I do not know it is right or wrong.I could not see any response in this line.
    My original idea is recording the date and time when saving the datas.
    Would you have any good idea according to it ?
    I wouldn't care success or failure,for I will only struggle ahead as long as I have been destined to the distance.

  • How to crete data type from XSD

    Hi All,
    can anyone tell me ...how to create data type from agiven xsd.
    I need urgently....
    thanks in advance....

    import this XSD, load this in your mapping editor and then use this to crate the datatype manually.
    Or, use XML spy, load this XSD and then you should be able to see the Structure, or,
    Look into the XSD data and decipher things yourself
    Regards
    Bhavesh

  • How to make data flow from one application to other in BPEL.

    Hi All,
    I am designing work-flow of my application through BPEL(JDeveloper), I am making different BPEL projects for different functions, like sales manager got the order from sales person and sales manager either approve it or reject it, if he approve it it goes to Production manager and he ships the goods, now I want to keep sales person, sales manger,production manager in seperate BPEL files and want to get the output of sales person to sales manager and sales manager to production manager please help me in dong this.
    I was trying to make partner link in Sales manager of sales person and getting the input from there. I dont know this is right even or not, if it is right I dont know how to make data flow from one application to other.
    Experience people please guide.
    Sales Person -----> Sales Manager ----> Production Manager
    Thanks
    Yatan

    Yes you can do this.
    If you each integration point to be in different process, you have to create three BPEL process.
    1. Create a Async BPEL process 'A' which will be initiated when sales person creates the order.
    2. From BPEL process 'A' call a ASync BPEL process 'B' which has the approval flow. Depending on the input from process 'A' the sales manager will review the order in workflow and approve or reject and send the result back to process 'A'.
    3. Based on the result from workflow, invoke the Sync BPEL process 'C', where you can implement the shipping logic.
    -Ramana.

  • How to save a waveform from TDS3000 series oscillosco​pe to PC via GPIB?

    Hi, I'm a summer intern and I've been recently assigned the task to transfer a telecom pulse mask waveform from a TDS3054 to the PC via GPIB. My question is, is there anyway that I can save the waveform on the scope and transfer the file onto my PC? Or even better yet, save the waveform directly onto my PC in a spreadsheet format?

    First, download the instrument driver for the TDS3054 scope from National Instruments' Instrument Driver Network. Depending on what software you have installed on your system, you may need to download additional software (look at the "Required Software" section). If you have Measurement Studio 6.0 and the NI-GPIB driver, you should have everything you need.
    Once you've installed the instrument driver, look at the instructions that came with the instrument driver for how to save and read from your oscilloscope, and look at the instructions here for how to use that instrument driver with Visual Basic 6.0.
    TonyH
    Measureme
    nt Studio

  • How to manage data aggrigation from multiple systems.

    Hi,
    How to manage data aggrigaion from multiple system which should support paging too.
    please suggest me , best possible soluntion.
    Thank You

    what is ment by aggrigation? what is the difference between Inheritance and aggrigation ? How can it implement as part of the programm

Maybe you are looking for