Record time from start to trigger

Hello there,
I have a program that uses N analog channels to record data, they start taking data (either finite or continuously) a trigger.
I use the built in digital trigger but a software analog trigger (works well though). For now let's just worry about the digital trigger.
I am trying to record the time elapsed from when I start the program to when the trigger signal is received--that is, when the program actually starts collecting its data.
I've seen the examples of how to put a time stamp at the point of the trigger HERE. However, I have a few differences in my code--mainly that I am collecting N channels of data rather than one, which complicates it. Also I don't necessarily want the time stamp, but the time elapsed from start to receiving the trigger.
Right now I have a few ideas:
1) somehow timestamp the start of the VI, then figure out the time stamp of the trigger in a similar way to the example above, subtract the difference.
2) In debugging code, I find that probes record the last update at a certain point in the code. Is there a way to utilize this in actual code?
3) most difficult. Setting up a new channel that observes the digital channel I am triggering off of so that I can record its data continuously, wire that channel to trigger my analog channels. then i can see the time at which the trigger went off. But I am unsure of how to implement this.
Just looking for opinions as to what would be the easiest way to accomplish this task.
Also, I can post my code if desired-- I didn't because it's quite large and difficult to follow.
Thanks to everyone,
beefcake
Solved!
Go to Solution.

Take a look at the Timing palette.
Also, if you search the NI Developer Zone for "elapsed time" you will find 160 documents.
Surely something in one of those places will help you.
Cameron
To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.
To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):
LabVIEW Unit 1 - Getting Started
Learn to Use LabVIEW with MyDAQ

Similar Messages

  • Differnec in front end and back end of ESS record time from ABAP point

    HI Expert,
    Here I need information regarding employee working time.
    Quary is we are trying to restricts the records entered in time sheet through user exit CATS0006.
    Here in CATS0006 one table is there CHECK_TABLE.
    when I am executing time sheet from back end(t code  CAT2) the table Check_table is having forward and backword 6 weeks data from the key date and date_from and date_to fields have correct value for week start and end.So that I am able to validate records.
    But when I am executing from ESS>Working time>Record working time and set an external debugger on CATS0006 I got that at this time CHECK_TABLE has only edited entry and date_from and date_to field value are also not correct one.
    Please suggest what may the cause of problem ,is it the case with your system as well?
    Is it a problem with SAP standard code?
    << Moderator message - Please do not promise points >>
    << Moderator message - The answers in the forum are provided by volunteers. Please do not ask for help quickly. >>
    Thanks,
    Subhashree.
    Edited by: Rob Burbank on Dec 2, 2011 9:26 AM

    Hi,
    What password are you talking about, the one created with the workgroup manager? That will be difficult since 2010 doesn't have the workgroup manager anymore. You can still use the database in the 2010 environment but you can't make any changes to the original
    database without the password.
    Maurice

  • How to get elapsed time from start of current day

    Hello,
    I've tried to use the DateDiff function to calculate the elapsed time, starting from 00:00:00:000 (Midnight of current day), but I'm getting hung up on how to inform the function of what date values it should use.  I could parse off the time section
    of the
    GetDate() function, but that doesn't seems a little klunky to me. 
    So, what I'm trying to capture is this (pseudo code): 
    Elapsed Time (int) =    Select DateDiff(seconds, Current Day.Midnight, CurrentDay.CurrentSecond)
    Any help is greatly appreciated.
    Cap

    Hello,
    So something like this? You can change it around, I used variables so you can see and check (and play with) the values.
    DECLARE @CurDay DATE = GETDATE()
    Declare @SecondsToDate INT
    SELECT @SecondsToDate = DATEDIFF(SECOND, @CurDay, GETDATE())
    SELECT @SecondsToDate AS SecondsPastMidnight
    -- do the check
    SELECT DATEADD(SECOND, @SecondsToDate, CAST(@CurDay AS DATETIME))
    Sean Gallardy | Blog | Microsoft Certified Master

  • Integration with Outlook - how to increment end date and time from start date/time

    Hi,
    I want to add a variable amount of time to an appointment start date and time in outlook, through vba in access.  Code below shows what I've done:
    ======================================
        Dim olApp As New Outlook.Application
        Dim olAppointment As AppointmentItem
        Dim myRequiredAttendee As Outlook.Recipient
        Set olAppointment = olApp.CreateItem(olAppointmentItem)    
        With olAppointment
            .Start = DateValue(strStartDate) + TimeValue(strStartTime)
            .Duration = intDuration
            .End = DateValue(strStartDate) + ????????
    =======================================
    What do I replace the ????? with so that it increments the start time by any duration I decide in minutes?  Using the duration doesn't seem to work and I also want to be able to have the appointment span a number of days, e.g. could start at 930am on
    Monday and end at 10am on Weds, but want to set the end time relative to the start time.
    Thanks,
    Chris.
    _________________________________________________________ Every day is a school day!

    I've tried that, but it throws out a datatype mismatch error :(
    It would be helpful if you posted the exact code you tried.  In my tests, setting teh .Duration property appears to work.  However, if you want to set the .End property to a specific number of minutes after the date/time of the .Start property,
    this works for me:
    With olAppointment
    .start = DateValue(strStartDate) + TimeValue(strStartTime)
    .End = .start + TimeSerial(0, intDuration, 0)
    End With
    Assuming, that is, that intDuration contains the number of minutes the appointment should last.
    Dirk Goldgar, MS Access MVP
    Access tips: www.datagnostics.com/tips.html

  • NI 6115, triggering AO & AI simultaneously from 2 different trigger sources?

    I am using NI 6115. Can I trigger my AI and AO simultaneously and independently (at different times) from 2 different trigger sources?

    This is possible to do. What Software are you using to program this? (CVI, LV, ...) So, what your are trying to do is a triggerd generation, adding hte functionality of a triggered acquisition. In general, I would think that the easiest way of doing this is just to have continuous AO, then trigger the AI when needed with the PFI0/TRIG1 line. If you need to trigger both the AO and AI, I can think of 2 ways of doing this:
    1. use the PFI0/TRIG1 to trigger the AO and one of the other PFI lines that are not in use to trigger the AI. Take a look at the daqmx examples in the language you are using for triggered AO, Triggered AI, copy and paste the necessary portions into a new Programm, you might want to adjust the error inputs and outputs in LV so t
    he components get acomplished in the order you require. Daqmx is fully multithreadding compatible, so I would strongly suggest you use Daqmx.
    2. Trigger your AO with PFI0/TRIG1 and use an analog edge condition to trigger at a specific value in your generation. The backdraw of this is that you would have to input the signal you are giving out into one of your AI channels which you probably are not interested in doing.
    For all these options, you are going to find examples in LV or CVI, but you will need to take parts of one example and paste it into the other.

  • Arrive time of start trigger

    Dear all NI high speed digitizer experts:
     I am asking how can I read the timestamp of the start trigger? In my measurement I configure my digitizer NI5154 to start a multirecord acquisition by sending a start trigger. Currently I use the timestamp of the first captured waveform as the trigger time. This is not a precise approximation since the time difference between the first waveform and the trigger varies in a few ms range.
    Anyone know how to read the trigger timestamp?
    thank you.
    Lixin 

    Hello,
    The timestamp that you're looking at is actually the software timestamp returned by the NI-Scope driver VI, so you're right that it will differ from when the start trigger on the digitizer hardware is received and when that first sample is returned in software, especially if you have a very long record length.
    There are two properties that can help you determine a relative timestamp between records, but is actually a time value of a constantly running counter onboard the digitizer. The "Absolute Initial X" and "Relative Initial X" values that get returned as part of the "wfm Info" on the Fetch VI, will show you the timestamp of the first sample in each record of a particular acquisition and the time from the trigger to the first sample of the record, respectively. Take a look in the niScope Fetch (poly) detailed help and you can see this explanation.
    These values are good for comparison between records, but not a good absolute timestamp, because this counter is constantly running and is only reset on rollover or when the board is reset. So, you can see that the values returned may look a little funny, but keep in mind they are values derived from the counter counting a certain rate. So, what you can do is take the first values returned for AbsoluteInitialX and RelativeInitialX and add/subtract them (depending on your trigger type) and make that value your "0" time, and then for each consecutive record, just extrapolate from there.
    Hopefully this helps out.
    Chris W

  • Macbook Pro takes a long time (41 secs) from start to reach log-in - It used to be almost instantaneous, I'm running Lion OS

    My Macbook Pro takes a long time (41 secs) from start to reach log-in - It used to be almost instantaneous, I'm running Lion OS. I thought this might be because I'd used a lot of disk space but I've now reduced that - I'm only using 40 of the 320 gb available. I have no games and I've unchecked the "re-open windows" option on shutdown. The rest of the preformance (once in) remains good.

    41 seconds is actually a little faster then normal. Boot from completely off is normally around 45-50 seconds.
    Your computer never ever came on almost instantaneously from completely off. You are confusing waking up from sleep mode and booting the computer from completely off.

  • Large records retrieve from network took too much time.How can I improve it

    HI All
    I have Oracle server 10g, and I have tried to fetch around 200 thousand (2 lack ) records. I have used Servlet that is deploy into Jboss 4.0.
    And this records come from network.
    I have used simple rs.next_ method but it took too much time. I have got the only 30 records with in 1 sec. So if I want all these 2 lacks records system take around more than 40 min. And my requirement is that it has to be retrieve within 40 min.
    Is there any another way around this problem? Is there any way that at one call Result set get 1000 records at one time?
    As I read somewhere that &ldquo; If we use a normal ResultSet data isn't retrieved until you do the next call. The ResultSet isn't a memory table, it's a cursor into the database which loads the next row on request (though the drivers are at liberty to anticipate the request). &ldquo;
    So if we can pass the a request to around 1000 records at one call then maybe we can reduce time.
    Has anyone idea How to improve this problem?
    Regards,
    Shailendra Soni

    That true...
    I have solved my problem invokeing setFetchSize on ResultSet object.
    like ResultSet.setFetchSize(1000).
    But The problem sorted out for the less than 1 lack records. Still I want to do the testing for more than 1 lack records.
    Actually I had read a one nice article on net
    [http://www.precisejava.com/javaperf/j2ee/JDBC.htm#JDBC114]
    They have written a solutions for such type of the problem but they dont give any examples. Without examples i dont find how to resolve this type of the problem.
    They gave two solutions i,e
    Fetch small amount of data iteratively instead of fetching whole data at once
    Applications generally require to retrieve huge data from the database using JDBC in operations like searching data. If the client request for a search, the application might return the whole result set at once. This process takes lot of time and has an impact on performance. The solution for the problem is
    1.     Cache the search data at the server-side and return the data iteratively to the client. For example, the search returns 1000 records, return data to the client in 10 iterations where each iteration has 100 records.
    // But i don't understand How can I do it in java.
    2. Use Stored procedures to return data iteratively. This does not use server-side caching rather server-side application uses Stored procedures to return small amount of data iteratively.
    // But i don't understand How can I do it in java.
    If you know any one of these solutions then can you please give me examples to do it.
    Thanks in Advance,
    Shailendra

  • Why does a new run once start up program run every time I start my computer? The start up program is coming from Reader XI. The only name on it is a number starting with 141_______.

    Why does a new run once start up program run every time I start my computer? The start up program is coming from Reader XI. The only name on it is a number starting with 141_______.

    See also https://forums.adobe.com/thread/1654402

  • A simple list with seven time buckets starting from the date report is run.

    Hi All,
    I am new to ABAP.Recently i have planned to write a progam which will help in planning the delivery of scheduled items.For a given sales Org. it will display all the undelivered,delivered items in a simple list and sort them with delivery dates.it will also provide a summary report at material group.For that i have used selection screen(LIKP-VKORG-Obligatory).when i enter VKORG Details i should get all the delivery docs for which delivery is not done or partially done.For this i have taken one more table LIPS
    (LIPS-MATKL,LIPS-MATNR,LIPS-VBELN,LIPS-POSNR,LIPS-WERKS,LIPS-LFIMG,LIPS-MEINS) for tables LIKP and LIPS VBELN is the key field.when i enter VKORG Data in the selection screen ,how can i get the data from LIPS Table.Please explain?
    Also report should be simple list with seven time buckets starting from the date when the report is run.The amount of quantity to be delivered should be displayed under appropriate bucket i.e within the bucket where its delivery date falls in.for ex:If the report is run on Tuesday 15th march 2010 then the start date 1 should be starting date of the week which is Monday 14th March.
    The report will be summarized at Material Group and Material Number.
    Appreciate your help
    Thanks and Regards,
    Shakeer Hussain

    Sorry, sounds too much like a complete requirement you want done for you by the community.
    Please work on it yourself and search for available information before posting specific problems only.
    Thread locked.
    Thomas

  • How do I stop LR5 import dialogue from starting every time I insert an external drive. I have already unchecked this from Preferences to no avail.

    How do I stop LR5 import dialogue from starting every time I insert an external drive. I have already unchecked this from Preferences to no avail.

    Hi Jim:
    You are a Legend! I have Windows 8.1, but I had the same option in Control Panel and sure enough it was in auto play, which I have now changed and it is no longer occurring. Thank you!!
    Wendy

  • Each time I start FF tabs from previously visited websites automatically propagate. How do I keep this from happening?

    Each time I start FF, tabs from previously visited websites automatically propagate. How do I keep this from happening?

    Open the Options dialog (in the menus select Tools > Options).
    Go to the general panel, and in the Startup section change the option for "When Firefox starts"

  • How do I stop Firefox from checking add-on compatibilty every time I start the program?

    In the past 2 days, every time I start Firefox, a "What's New" tab (checking for compatibility of add-ons?) pops up in addition to my homepage tab. How can I keep the "What's New" tab from coming up? It seems like this starting happening after I updated to Firefox 6.0.
    Running Windows Vista
    Firefox 6.0

    Firefox 8 i am on and its doing the same,very annoying,ill be going back to previous version...
    do you guys at Firefox ever check your update's on any of your own computers before you release them?
    might be a good idea,its the same with kylo,updates come screw everything up when they were working fine...im am a house builder,if i built houses with this many errors i'd be bankrupt by now....

  • How much time does a query take from start to end?

    How can i query the time a SQL command takes from start to end (it was a big query and started yesterday evening when we started work today it was ended)?
    i selected some values of v$sqlarea but i could not understand the result absolutely. is there a more practical way of getting this information?

    select sql_text, cpu_time/100000, elapsed_time/100000 from v$sql where sql_text like '
    If the SQL is still in memory, not 100% reliable and there is a Bug 2101311 V$SQL.CPU_TIME / ELAPSED_TIME wrong for DML statements

  • Every time I start Firefox, the upgrade/signup page is displayed in one tabe while google, my start;up page s displayed in another. How can I stop the firefox page from loading every time?

    Every time I start Firefox, the upgrade/signup page is displayed in one tab while google, my start-up page is displayed in another. How can I stop the firefox page from loading every time?

    See these articles for some suggestions:
    * https://support.mozilla.com/kb/Firefox+has+just+updated+tab+shows+each+time+you+start+Firefox
    * https://support.mozilla.com/kb/How+to+set+the+home+page - Firefox supports multiple home pages separated by '|' symbols
    * http://kb.mozillazine.org/Preferences_not_saved

Maybe you are looking for

  • How do I disable the "ad wigets" in a auto populating site?

    When I use a website that auto-populates a window the widgets are also trying to "suggest" a link for me. I cannot figure out how to disable the widget so I can use the site. the website is livestrong and I am trying to fill out my selections for tra

  • How to disable keyboard strokes

    Hey..........can anyone help me!!!How does one disable the keyboard input....i.e,if i have a textfield and i want to give input through another panel or frame containing buttons, and disable the input through keyboard.....Any 1 ?????plz..

  • UPDATE STATEMENT GETTING FAILED

    Hi Can you specify me condition in which case update statement will fail and exception will be handled I wanted to know that Lets says I have a procedure procedure p1 is begin update emp set deptno=50; end; can you suggest me when will update stateme

  • Use Dropbox as iPhoto library location?

    I need access to my image files from several computers, and am wondering whether I could simply locate my iPhoto library on Dropbox, and access it as needed. I am, and would continue, backing up to a remote hard drive, so the Dropbox would not be the

  • PGI effects and how to see them

    hi ,       When PGI is done the following documents are generated . like accounting document, costing document, inventory document. how to see those documents generated by a particular PGI thanks mmn rewards for sure