Why do we lose counts through a timed loop?

I have written a program to count the rising edges of a square wave produced by a function generator using the DAQmx functions. The counter is read in a time loop with a period of 1 second, so we take a sample once every second. It appears that the program is working correctly accept for the fact the the counts are continuously 2% lower than they should be. We are guessing that this is due to the fact that the timed loop really isn't taking a full second to complete each iteration. Any suggestions on how to fix these timing errors? The counters are read from the NI 6608 Device if that is of any help.

Please post images of your code so that we can be off assistance.
Thank you,
Ben
Ben Rayner
I am currently active on.. MainStream Preppers
Rayner's Ridge is under construction

Similar Messages

  • Timed loop not starting - works after closing and opening project

    Refer the image below - a simple timed loop should run when the Run button is pressed. What happens is that the parallel vi runs (see arrow) but the vi inside the loop doesn't.  Both vi's shown run forever (i.e. the timed loop is only used to specify the CPU).  
    When I press the Abort Execution button, strangely it can then be seen that the execution highlighting runs into and through the timed loop and probe 50 is updated.
    This sorted itself out after I closed the project and opened it again so its not a critical issue - was simply wondering what could cause this?

    That program looks kinda weird.
    First of all, avoid to use flat sequence structures whenever you can, or use it only when you are going to initialize something, or when your program has an specific sequence.
    I think you have a problem the way you are conecting the subvis. Remember that in LabVIEW,  the flow of the data will determine the order of execution, and in your case, the conections looks kinda weird.
    I have a question; Do the subvis need to run simultainously?, or what do you need to do exactly

  • Why does it always lose count?

    Hi, all-
    I installed PCI7344 to control steppers. I configed it into open-loop stepper control. In the "Find Reference Setting", I selected the "Smart Enable" and "Reset Position"; Set "Offset move", "Primary Position" and "Secondary Position" to zero.
    Then I run the labview example program "One-Axis Find Reference with Status Monitor.vi" to find home. Of course once the home position is found, the "Position" in "Current Trajectory Data" is reset to zero. Afterwards I moved the stepper through "1-D Interactive".
    Here comes the weird problem. The first time I move the stepper after the Home Position is found, it always lose counts. For example, I put in 10000 in Target Position with the "Relative Position" mode, after the movement is co
    mplete, the "Position" in "Current Trajectory Data" shows "9995" (always some counts less than or 10000) instead of 10000. The weird thing is this only happens in the first move, in the moves after that, the positon display will match the step I input.
    Any idea why this happen? I tried to disable the Position Reset in the "Find Reference Setting" and use Absolute Position Mode, it seems in either case the problem is gone.....

    I haven't heard about this issue, yet. Which NI-Motion version are you using? The latest version available for download is 6.1.3. You need to install 6.1.2 first and then the maintenance update 6.1.3.
    Download links:
    NI-Motion 6.1.2
    NI-Motion 6.1.3 maintenance update
    Please update to the latest version of NI-Motion and also update the firmware on the board in MAX. Please post a new comment to this answer if the problem persists.
    Best regards,
    Jochen Klier
    National Instruments Germany

  • Why do I lose my text layer in AE when gpu ray trace rendereing? Macbook pro with retina and latest

    why do I lose my text layer in AE when gpu ray trace rendereing? Macbook Pro with Retina and latest AE update.
    Any new text layers disapear also as soon as the 3d box is checked.  Solid layers do likewise.  The text is available in fast draft mode but is not present in a final render. 
    Adussting the number of "rays" makes no difference.
    No one else seems to be having this problem with ther macbook pro with retina ( on internet).
    What silly mistake am I making???????????
    If I start the project in CPU ray trace all is fine.  If after the problem develops in GPU I change back to CPU I DONT get them back!!!!!
    I just reset the AE preferences - no help.

    Go through this thread :
    http://forums.adobe.com/message/4749742
    You might get your answer.

  • Restarting counter in Timed Loop

    I have a timed loop inside a state machine, used to start/stop a data acquisition sequence.
    It works fine, but I'm monitoring the "i" count and Actual End [i-1] values and after the start/stop/start sequence
    these values continue to grow and don't get reset to zero.  I would expect a While Loop to reset the "i"
    variable every time is is called, but I don't see any option for resetting the time looped.
    I can get around it, but I would expect a reset method for this loop, so I'm just wondering if I'm missing something.
    Maybe I need to use "Create Timing Source" instead of the setting it iin the dialog box?
    Labview 2010f1 on Windows Vista SP2 PC

    This might help. Here is a part of the png file you posted. I put in "Structure Name>" to point to the Structure Name input. Notice that the name "bob" is listed as the Structure Name. You must be on Win7 which uses different fonts than XP - that's probably why the name is only half visible.
    Note that the Clock name is connected to the (timing) Source Name input.
    I'm attaching an updated version of the file with the Timing Loop name wired directly.
    Thanks for posting your timed loop interations3 program in 2009. When I run this code, the Iteration Count DOES reset when the Timed Loop is restarted.
    steve
    Help the forum when you get help. Click the "Solution?" icon on the reply that answers your
    question. Give "Kudos" to replies that help.
    Attachments:
    New timed loop interations.vi ‏42 KB

  • Why do I lose the sound effects for mail on my MBA and not the other Macs I have? Running ML.

    Why do I lose the sound effects in Mail for sending and receiving on my MBA and not on my other Macs? Running Mountain Lion. The problerm seems to be related to the sleep mode. When the MBA sleeps and then wakes up the sounds are missing. If I shut down and restart the machine the sounds will be back but only last until the maching goes through a sleep cycle.

    Primarily because, as ron245 points out, there is only ONE speaker on the bottom.

  • When I downloaded Mozilla Firefox 4.0 Beta 10 I lost all my Bookmarks. I went back to using the older version and get the message that it is no longer supported or covered by virus protection. Why did I lose my Bookmarks?

    Why did I lose my Bookmarks?

    Clarification:
    I believe now you potentially lose all extensions, plug-ins when you use the new reset function, but you will let me know.
    If that is the case, your find corrupt file method maybe better. However, I reviewed the two help articles and there appear to be more files than just the delete search.json file and a possible search.sqlite file in the Firefox Profile Folder. I am confused. Then I have to find the folders. I think help articles mentioned how to find the profile containing the files, but not sure.

  • Using timer/counter with PCI-6221/USB-6210 to control timed-loop VI

    Dear all,
    I need to ask about two devices and one of their functionalities, PCI-6221 and USB-6210. For our NI-based system, we need to control some timings in a Timed-Loop vi, for that currently we are using PCI-6221 and we give external TTL signal (at 1 kHz) to it,
    recenntly we need to make some changes and for that we found USB 6210 DAQ to be more suitable, but we need to clear ourselves on some specific things.
    Can the counter/timers functions available in the either PCI 6221 or USB 6210 can be used to control the Timed-loop VI by giving external clock or by using their own internal clock source?
    Although we are using external clock with the PCI 6221 but we want to know about the usage of their internal clock, also are controlling timed-loop also possible for USB-6210
    Also... What if we use the RTOS, are they still able to control the timed-loop VI  without giving any 'EXTERNAL CLOCK' and using the internal clock sources of the DAQs
    Waiting for reply,
    Bests,
    RaJaf
    Solved!
    Go to Solution.

    Ben,
    I having read previous email which I send earlier with general overview, we discussed in more detail within our team and I am giviing the specific answers.
    Please check in RED the most recent answers. Blue are the questions/suggestions by your side.
    1.    Using Internal hardware clock of PCI-6221 would enable us get rid of external clock, but how to divert the internal hardware clock to the current settings. Any idea  (can you provide us with some reference manul for otherwise). I mean is there some flag-bit etc. or VI
    2.       Is it also meant that with the installation of RTOS the timed-loop can directly get the timing source from the internal hardware clock PCI-6221? --- How???
    3.       In order to make desktop to work as RT system, what is the hardware (motherboard, processor, etc..) requirement? What are the LabVIEW modules (specific name) that needed to be installed? Our platform is LabVIEW 8.6. (Currently we have windows-7 with i7 core processor)
    What kind of application are you intending for this system? ---- high-speed laser scanning system.
    Are you most concerned about accuracy, speed, or responsiveness? To control the laser mirror scanner to move at 1 kHz or 2 kHz speed. On the other hands, using PCI-5105 (128 MB memory) as a DAQ for real-time/on-the-fly data processing.
    Bests,
    RAJAF

  • Why is the word count different when I use word count from the tools menu to the number at the bottom of my mac word document

    Why is the word count different when I use word count from the tools menu to the number at the bottom of my mac word document

    This forum is for Apple's defunct office suite 'AppleWorks' - since the word count is not in the places you mention I assume you are talking about Microsoft Word? Though it's just possible someone in this forum might also use Word and know the answer, you would stand a higher chance of getting an answer in Microsoft's own forums. You could also try asking in the forum applicable to your operating system - Lion, Mavericks or whatever - on the reasonably chance of finding someone familiar with Word.

  • Why did I lose my contact distribution lists with IOS 7?

    Why did I lose my contact distribution lists in my calendar after upgrading to IOS 7?

    Disregard ... I found what happened.

  • Why did i lose apps when i synced with a new computer

    why did i lose apps when i synced with a new computer

    Because ipod touch will sycn with one computer at a time.  Syncing to another wil erase the current content.
    You should copy everything from your old computer to your new one.
    You can redownload apps:
    Downloading past purchases from the App Store, iBookstore, and iTunes Store

  • Why do I lose the playlist I have created on my ipod touch every time I sync with itunes?

    Why do I lose the playlists I havae created on my ipod touch every time I sync with itunes?

    If I go to contacts for a split second the + sign is there and then it goes. Also on Mail,Contacts, Calendars in Settings opens and then in a split second goes back to desk top. As I lost my earlier ipod touch had to change password to gmail but cant change it on my ipod as  cant get to settings! Help please?

  • Why do I lose type effects

    Why do I lose type effects on my printed page such as emboss, bevel and drop shaodow (in Photoshop CS6) when I save my file as a jpeg or pdf?

    Most likely you simply have your printing/ PDF options set to not rasterize non-vector data and since al lthese effects are pixel-based, you simply lose them. Just enable that option and everything should be fine.
    Mylenium

  • Why i get different value when subtractin​g two elements of different arrays then the actual value in a timed loop

    Hi Everyone
    I have a probem in substracting the two elements of two different  1-D arrays. The problem is, I am taking out data from a CCD camera which gives me data in form of 2-D array. So i select 1-D array out of it. Now this CCD output is in a timed loop, hence i am getting data in each loop. I select a perticular array output of the CCD and this is then passed to shift register and in all the loops later on, one of the element of the output array of the CCD is substracted from the same indexed element of the selected array. For reference i have pasted the snap shot of the block diagram. In this snap shot you see three probes. The value at the prob 1 is 232, at probe 2 is 255 and at 3 is 4294967273, where as actually i sould have a value of -23 since i am substacting prob 1 and probe 2 values. Since the value of probe 2 will always remain at 255 as i have fixed it by choosing an array form CCD and i checked the value of probe 1 which never goes above 255 so why do i get this false value here.
    Can you please help me in problem.
    Regards
    Chauhan
    Attachments:
    clip_image0011.gif ‏15 KB

    Your data is U32 (unsigned integer) which does not have negative values. According to unsigned integer math, "negative" results will wrap.
    You need to work in a datatype that is appropriate for what you want to do. How many significant bits do you have in the raw data?
    Message Edited by altenbach on 03-17-2008 11:15 AM
    LabVIEW Champion . Do more with less code and in less time .

  • Why do I lose the quality of my fonts in dreamweaver after slicing in photoshop ?

    why do I lose the quality of my fonts in dreamweaver after slicing in photoshop and saving it for web with the highest quality ?  Itried everything from different font to highest resolution.

    Resolution means nothing on the web.  Most browsers render images at 72 dpi (slightly higher on some mobile devices).
    What matters on the web is the number of pixels contained in the image (i.e. 500px wide x 325px high) and the file type used to save it (PNG, JPG or GIF).
    http://www.sitepoint.com/gif-jpg-png-whats-difference/
    Possibly Relevant Link:
    http://alt-web.com/Articles/Custom-Web-Fonts.shtml
    Nancy O.

Maybe you are looking for

  • How to enable variable highlighter on Vista (JDeveloper 10.1.3.3)

    I have been working with JDeveloper for a while I have tried the 10.1.3.3 & the new preview 2 on my Windows Vista laptop, but I can't get the open source update Varible highlighter and code colorizer to work. I have tried everything with the 10.1.3.3

  • FTP adapter deployment failed after restart of the server

    Hi, I have a single node 11g server. I had created some outbound connection pools for the ftp adapter. When I created them they were working fine. But after the restart of the server the FTP Adapter state in the summary of deployment page is showing

  • IBooks is not displaying some books

    As many others, iBooks is not displaying all my collection. If I manually try to add any missing epub (by dragging and dropping) I get a message saying "This book is already in your library. Do you want to replace it with the one you're adding?" And

  • Need help with CATS WebDynpro

    <h4>System Landscape</h4> ERP 6.0 - HR ERP 6.0 - Financials EP 7.0 SP13 u2013 MSS 1.0, ESS 1.0 Scenario: We are trying to implement the CATS functionality in the portal so that contractors can enter their time and managers can approve time from withi

  • MacBook Pro on 10.6 can't see shared printers

    I just updated my Macbook Pro last week to 10.6.   I have my old desk top mac running 10.3.9 and serving up shared printers. I just realized my laptop now does not see the shared printers.  DId Apple make it so that 10.6 won't play nice with earlier