How do I read in a 1 Hz pwr level file and send it out at 1Hz to the signal generator?

I would like to be able to read in a 1 Hz file and use the format into string and send it out at 1 Hz to a signal generator to vary the levels to match a timestamp. I was trying to use the format into string but I can't figure out how I could read in this file.
00:00.0
-113.586
00:01.0
-113.598
00:02.0
-113.61
00:03.0
-113.622

If the file is a .csv file as you said in your other post, then you should just be able to use Read From Spreadsheet File, making sure to set the delimiter to comma rather than tab. If it's a small file, you can just read in the whole thing, then use a loop with a Wait For Millisecond Multiple node (the metronome) to send the data once every second.
If the file is very large, and you don't want to read it all at once, you can tell the Read From Spreadsheet File node to read only one line at a time. Put the read node and the data sending node in the same While loop, and use a shift register to carry the Mark After Read value from one iteration into the Offset or Mark At Start terminal in the next iteration. That way, you start reading each line at the end of the previous one. Use some form of flow control (such as a Stacked Sequence Structure) to make sure things happen in the right order - read data, wait for the right time, send data. 

Similar Messages

  • File Adapter to read Zip file and send it as input to another webservice

    Hi,
    I have the below requirement:
    1. A service will generate 3 attachments and place it in a particular directory.
    2. SOA service has to pick those 3 files and send those files as input to another custom application which will email.
    Design :
    1. First SOA will create an archive file of those 3 attachements and then file adapter will poll for that zip file in that location and send that file as a whole to the custom application.
    Query:
    Now my question, is the above design feasible? If so, how to configure the file adapter to pass the file as input to that custom application?
    Kindly do the needful
    Thanks,
    Priya

    You can accomplish this via java embedding activity...Create a java embedding, which will create a zip file.. this java code is easy to implement..
    You can also do away with un-necessary polling file adapter.. and you can use "Synchronous File Read" operation of File Adapter.. For Sync Read, you'll have to pass the zip file name, which you can easily fetch from java embedding activity..
    Let me know, if this doesn't work.

  • How do I convert mail merge documents to individual pdf docs and save each with a field in the merge?

    How do I convert mail merge documents to individual pdf docs and save each with a field in the merge?

    Is this an actual field, or just some piece of static text somewhere? Either way, you can't do it using the Split Document command. You'll need to use a custom-made script to read the value of this "field" and use it when extracting pages from the file.

  • Read  an XML file and send it to client

    Hi,
    I'm introducing to servlet development and I'm trying to do some AJAX calls. The client side is implemented, but I have some troubles on the server side. I want to open an XML file and send it to the client. How can I do that? Any special header?
    I have implemented this test in PHP, so you can imagine what I would like to do:
    if ($type == "xml"){
         $xml = "";
         $file = fopen ("file.xml", "r");
         while (!feof ($file)){
              $xml .= fgets ($file, 4096);
         fclose ($file);
         header ("Content-type: text/xml; charset=ISO-8859-1");
         echo $xml;
    }The XML file is:
    <?xml version='1.0' encoding='ISO-8859-1'?>
    <users>
         <user>
              <name>Pepe</name>
              <age>18</age>
         </user>
         <user>
              <name>María</name>
              <age>21</age>
         </user>
    </users>Thanks.

    Not very useful:(.
    This is my code:
    PrintWriter out = null;
            try{
                   String type = request.getParameter ("type");
                   if (type.equals ("xml")){
                        response.setContentType ("text/xml; charset=ISO-8859-1");
                        out = response.getWriter ();
                        String xml =
                             "<?xml version='1.0' encoding='ISO-8859-1'?>" +
                             "<users>" +
                                  "<user>" +
                                       "<name>Pepe</name>" +
                                       "<age>18</age>" +
                                  "</user>" +
                                  "<user>" +
                                       "<name>María</name>" +
                                       "<age>21</age>" +
                                  "</user>" +
                             "</users>";
                        out.println (xml);
            }finally{
                out.close ();
            }This code works. The servlet send back the xml and the client shows the content but, as you can see, i'm not reading the xml file. So my problem is on reading the xml file as a plain text. My code is this:
    response.setContentType ("text/xml; charset=ISO-8859-1");
                        out = response.getWriter ();
                        String xml = "";
                        FileReader fr = null;
                        BufferedReader br = null;
                        try{
                             fr = new FileReader (new File ("file.xml"));
                             br = new BufferedReader (fr);
                             String linea;
                             while ((linea = br.readLine ()) != null){
                                  xml += linea;
                                  //System.out.println (linea);
                             fr.close ();
                        }catch (Exception e){
                             e.printStackTrace ();
                        }But now I get an Exception File not found. The xml file is in the web directory (I'm using net beans 6.8). Where I have to put the file?
    Thanks.
    Edited by: GagleKas on Mar 15, 2010 6:39 AM

  • How do I record a sound file and send it as an attachment using my 4s?

    How do I record a sound file and send it as an attachment using my 4s?

    Hi,
    The following is the program[Click Here| http://saptechnical .com/Tips/ABAP/email/EmailProgram.txt] which will send any format file. Actual Creator of the program is Amit Bisht.
    Thanks & Regards,
    Rock.

  • How can I get RAW pictures to open in PSE 12 and PSE 13?  I have installed the plugin 8.7.1 but it wont work with either.

    What can I do when I have downloaded RAW plugin 8.7.1 and it wont work on either PSE 12 or PSE 13????

    Hi I asked a computer engineer to install RAW plug in 8.7.1. on PSE 12 for me, and he couldnt do it either.   I have bought PSE 13 and followed the advise I was given - go to Edit - expert - Help - plugins - RAW - update- and IT WORKS !!!    DW
    Original message----
    From : [email protected]
    Date : 25/01/2015 - 11:53 (GMTST)
    To : [email protected]
    Subject :  How can I get RAW pictures to open in PSE 12 and PSE 13?  I have installed the plugin 8.7.1 but it wont work with either.
        How can I get RAW pictures to open in PSE 12 and PSE 13?  I have installed the plugin 8.7.1 but it wont work with either.
        created by susanl96972449 in Photoshop Elements - View the full discussion
    Hello, I have been experiencing similar problems and followed the suggestion and yes, the raw icon comes up as illustrated but there is nothing there to indicate any further action can be taken.  So I am presuming that means it is installed and no further action required?
    Here's my problem:  I have had no problems  getting my pics into my organiser in Elements 12 from either my Nikon D7100 or my Fujifilm X100S - until last week.  Suddenly when they are imported all I see is the timer icons but they don't open to let me view them.  If I click on one it will open and I can then edit it but it will not save an image onto the grid for me to view so it's really frustrating not being able to view all my photos in order to decide what to edit and compare them.
    Here's what action I've taken so far - restarted the computer (endlessly), checked the updates and installed them, checked I have the latest raw plug in (I do) and gone into edit/update thumbnail (doesn't do a thing) - and torn out a fair amount of my hair.  So anyone out there experienced this and can give me some advice? Please?
    If the reply above answers your question, please take a moment to mark this answer as correct by visiting: https://forums.adobe.com/message/7129439#7129439 and clicking ‘Correct’ below the answer
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page:
    Please note that the Adobe Forums do not accept email attachments. If you want to embed an image in your message please visit the thread in the forum and click the camera icon: https://forums.adobe.com/message/7129439#7129439
    To unsubscribe from this thread, please visit the message page at , click "Following" at the top right, & "Stop Following"
    Start a new discussion in Photoshop Elements by email or at Adobe Community
    For more information about maintaining your forum email notifications please go to https://forums.adobe.com/thread/1516624.

  • How can I rip a 10" x 10" post script file from InDesign 6, it keeps telling me "the active document

    How can I rip a 10" x 10" post script file from InDesign 6, it keeps telling me "the active document uses multiple pages sizes and won't print.  My page sizes are all 10" x 10"

    Please post in the InDesign forums here http://forums.adobe.com/community/indesign/indesign_general. They will be able to help you.

  • I have just recorded on garageband and now need to send away for editing how do i place in file and send

    I have just recorded on garageband and now need to send away for editing how do i place in file and send 

    Send where? Edit how?

  • I bought me and my wife a iPhone 4 32G and it turns out that she gets better signal then me mine keeps going in and out of service most of the time i only get one bar how can i fix this?

    I bought me and my wife a iPhone 4 32G and it turns out that she gets better signal then me mine keeps going in and out of service most of the time i only get get one bar how can i fix this?

    Restore as new in itunes and try again.

  • I just attempted to download a file and send to me, but  it may have gone out to all my contacts - how can I tell?

    I was just attempting first use of adobe send and it looks like I may have sent this to all my email contacts, how will I know?

    Did the unshare.  Thank you 
          From: bob.treitman <[email protected]>
    To: Robert Goldsmith <[email protected]>
    Sent: Tuesday, March 31, 2015 2:52 PM
    Subject:  I just attempted to download a file and send to me, but  it may have gone out to all my contacts - how can I tell?
    I just attempted to download a file and send to me, but  it may have gone out to all my contacts - how can I tell?
    created by bob.treitman in Adobe Acrobat.com Services - View the full discussionIf it says "Anonymous" then the only way that it would have gone out to all of your contacts would be if you sent it to them through your email client. And it would be in your email's Sent folder (not Adobe Send's). If you look at https://cloud.acrobat.com/sentfiles, does it show that the file has been Viewed? If the Views column shows a 0, then nobody has yet viewed it. If you're concerned, you can select the file by clicking the check box, then select Unshare. That will make the file inaccessible to anyone other than yourself. https://forums.adobe.com/servlet/JiveServlet/downloadImage/2-7392942-745487/900-90/SentTab .png  If the reply above answers your question, please take a moment to mark this answer as correct by visiting: https://forums.adobe.com/message/7392942#7392942 and clicking ‘Correct’ below the answer Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: Please note that the Adobe Forums do not accept email attachments. If you want to embed an image in your message please visit the thread in the forum and click the camera icon: https://forums.adobe.com/message/7392942#7392942 To unsubscribe from this thread, please visit the message page at , click "Following" at the top right, & "Stop Following" 
    Start a new discussion in Adobe Acrobat.com Services by email or at Adobe Community For more information about maintaining your forum email notifications please go to https://forums.adobe.com/thread/1516624.

  • I have a VI and an attched .txt data file. Now I want to read the data from the .txt file and display it as an array in the front panel. But the result is not right. Any help?

    I have a VI and an attched .txt data file. Now I want to read the data from the .txt file and display it as an array in the front panel. But the result is not right. Any help?
    Attachments:
    try2.txt ‏2 KB
    read_array.vi ‏21 KB

    The problem is in the delimiters in your text file. By default, Read From Spreadsheet File.vi expects a tab delimited file. You can specify a delimiter (like a space), but Read From Spreadsheet File.vi has a problem with repeated delimiters: if you specify a single space as a delimiter and Read From Spreadsheet File.vi finds two spaces back-to-back, it stops reading that line. Your file (as I got it from your earlier post) is delimited by 4 spaces.
    Here are some of your choices to fix your problem.
    1. Change the source file to a tab delimited file. Your VI will then run as is.
    2. Change the source file to be delimited by a single space (rather than 4), then wire a string constant containing one space to the delimiter input of Read From Spreadsheet File.vi.
    3. Wire a string constant containing 4 spaces to the delimiter input of Read From Spreadsheet File.vi. Then your text file will run as is.
    Depending on where your text file comes from (see more comments below), I'd vote for choice 1: a tab delimited text file. It's the most common text output of spreadsheet programs.
    Comments for choices 1 and 2: Where does the text file come from? Is it automatically generated or manually generated? Will it be generated multiple times or just once? If it's manually generated or generated just once, you can use any text editor to change 4 spaces to a tab or to a single space. Note: if you want to change it to a tab delimited file, you can't enter a tab directly into a box in the search & replace dialog of many programs like notepad, but you can do a cut and paste. Before you start your search and replace (just in the text window of the editor), press tab. A tab character will be entered. Press Shift-LeftArrow (not Backspace) to highlight the tab character. Press Ctrl-X to cut the tab character. Start your search and replace (Ctrl-H in notepad in Windows 2000). Click into the Find What box. Enter four spaces. Click into the Replace With box. Press Ctrl-V to paste the tab character. And another thing: older versions of notepad don't have search and replace. Use any editor or word processor that does.

  • I have the latest downloadable version of LR5.  It crashed while it was createing 1:1 previews during an import. After a Win7(64) restart, it shows a message that LR needs to quit because it can't read the preview files and it will try to fix it the next

    I have the latest downloadable version of LR5.  It crashed while it was createing 1:1 previews during an import. After a Win7(64) restart, it shows a message that LR needs to quit because it can't read the preview files and it will try to fix it the next time is launches.  I get the same message the next and every subsequent time it launches so I can't launch LR at all now.
    I get that the preview file got corrupted somehow.  Is there some way to fix this problem without building a new catalog?

    Use Windows Explorer to open the folder containing your catalog. You will see a folder with the extension .lrdata. You need to delete that folder and then start Lightroom again. Lightroom will generate a new previews folder.

  • I just want to read in a csv file and send it to an instrument at 1 Hz per line

    I want to read in a csv file that has pwr levels given at 1 Hz and append this using a format into string to the signal generator at 1 Hz. I just have never read in an entire file to automate the procedure. Thanks!

    duplicate post
    Please give time for people to respond. 

  • Reading text file and output (to stdout) a list of the unique words in the

    Hi,
    I have a main method as
    main.java
    package se.tmp;
    public class Main
    public static void main( String[] args )
    WordAnalyzer.parse( args[0] );
    and text file as
    words.txt
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the quick brown fox jumps over the lazy dog
    the requirement is like
    I need create this WordAnalyzer class, implement the parse method, and then commit the file. This method takes a single parameter, the filename of the file to parse. The method should read this file and output (to stdout) a list of the unique words in the file along with the number of times each appears in the file.
    Can anyone please help me on this?
    Thanks.

    Where are you having problems?

  • When I read a pdf document using Safari I'm unable to read more than one page of a file. A padlock icon is locked on the tab. Please help.

    When I read a pdf document using Safari on my IPad  I'm unable to read more than one page of a file. A padlock icon is locked on the tab. Please help.

    Hi snoreaustralia,
    It sounds like you just need to associate the PDF filename extension with Acrobat, rather than Preview. Please see this document from the Microsoft Help for instructions on choosing the default program for opening a particular file type (in your case, PDF): Change which programs Windows uses by default - Windows Help
    Best,
    Sara

Maybe you are looking for