Counter stuck at zero

Hi,
I'm using LabVIEW 2014 on Windows 64 bit to acquire displacement data from a digital encoder as follows: Renishaw linear encoder --> NI 9411 digital in --> cDAQ-9174 --> Windows machine.
I have a VI that records the displacement at 5000 Hz. It's been working fine for weeks but suddenly, the displacement value (i.e. the count) stays stuck at zero no matter how much displacement there is.
Displacement data is also being used in a SoftMotion feedback loop.  That is working fine.  I am even using SoftMotion commands to create a displacement history, which looks right (this displacement history is limited to low frequency activation by the nature of SoftMotion so I created this second way of measuring displacement to get to high frequency).  Point being, I'm confident the linear encoder is working fine.
I am extremely puzzled because I haven't changed anything of substance that I can think of.  I did switch the cDAQ9174 to a different USB cable os I started with the hypothesis that I had screwed up connectivity somewhere in hardware.  The cDAQ 9174 and the NI 9411 both pass Self Test in NI MAX.  I checked continuity of the relevant cable pin by pin and it is fine.  Then I started trying to get more insight into the value of the counter.  I have a number of versions of this VI and they all report that the counter is flatline at zero no matter how much displacement there is in the system.  I ran the VI in highlight execution mode to look for clues and I spotted something that seems slightly odd, at least to me.  The counter is identified as cDAQ1/_ctr*.  Does anyone know what that means?
Attached are screenshots of the VI with and without highlight execution turned on in case anyone sees anything in there that I'm missing.
Thanks,
John

Hey John,
I didn't see anything strange in your screenshots. The cDAQ1/_ctr* just means that there are more characters following "_ctr", but by default highlight execution only includes 11 characters. You can see the same behavior in a few of your other constants.
When you changed USB cables, did you change any of the inputs to the 9411? Is everything still configured to match the Connections for Counters and 9411 specifications?

Similar Messages

  • LabVIEW 6.1 If For Loop count terminal is zero then value going through the loop is not passed on to the output of the loop

    Hello, one of our customers just encountered an execution error in a vi running under LabVIEW 6.1, which doesn't exist under LabVIEW 5.1 or 6.01. I have a simple vi that has two encapsulated For Loops. Two string arrays go in, one goes out of the outer loop. Inside the outer loop the first array is indexed. The string which results from this indexing is compared with all other strings from the second string array in the inner loop. If it matches one of the strings of the second array, it is not outputted, otherwise this string goes through the inner For Loop to the output of the inner loop and from there to the output of the outer loop. The count
    terminal of the outer/inner loop is connected to the Array Size of the first/second string array. If the second array is empty, that means that the element in test from the first arry cannot match anything from the second array, so the element in test is send to the output of the inner loop and from there to the output of the outer loop. This works fine in LabVIEW 5.1 and 6.01, but NOT in LabVIEW 6.1. In LabVIEW 6.1 the inner loop is never executed if the count value is zero (which is correct), but the data line running through the loop is not executed either, which is different to what LabVIEW 5.1 and 6.01 do. There, the input string is sent to the output of the inner loop correctly even if the loop counter is zero. The solution is easy - I just have to connect the output of the outer loop to the data line BEFORE it enters the inner loop. But: I don't know if this is a LabVIEW 6.1 bug or if it is supposed to be a feature, but it brings some incompatibility in programming between the
    different LabVIEW versions.
    Best regards,
    Gabsi

    Hi,
    When a for-loop runs zero times, all outputs are 'undefined' (and should
    be).
    Besides, how would LV know what the output of a not executed routine should
    be?
    It might be handled differently in LV5 and LV6, which is unfortunate. In
    both cases, the result is undefined.
    It's not a bug. It's just something that should be avoided in any LV
    version.
    > The solution is easy - I just have to connect the
    > output of the outer loop to the data line BEFORE it enters the inner
    > loop. But: I don't know if this is a LabVIEW 6.1 bug or if it is
    In some cases this does the trick. But if the data is changed in the inner
    loop, this will effect the results if the N is not zero.
    Technically, I think the output in this construction is also 'undefined'.
    But LV handles this as expected / desired.
    Another solution is to use a shift register. If N is zero, the input is
    directly passed through to the output.
    Regards,
    Wiebe.
    "Gabs" wrote in message
    news:[email protected]...
    > LabVIEW 6.1 If For Loop count terminal is zero then value going
    > through the loop is not passed on to the output of the loop
    >
    > Hello, one of our customers just encountered an execution error in a
    > vi running under LabVIEW 6.1, which doesn't exist under LabVIEW 5.1 or
    > 6.01. I have a simple vi that has two encapsulated For Loops. Two
    > string arrays go in, one goes out of the outer loop. Inside the outer
    > loop the first array is indexed. The string which results from this
    > indexing is compared with all other strings from the second string
    > array in the inner loop. If it matches one of the strings of the
    > second array, it is not outputted, otherwise this string goes through
    > the inner For Loop to the output of the inner loop and from there to
    > the output of the outer loop. The count terminal of the outer/inner
    > loop is connected to the Array Size of the first/second string array.
    > If the second array is empty, that means that the element in test from
    > the first arry cannot match anything from the second array, so the
    > element in test is send to the output of the inner loop and from there
    > to the output of the outer loop. This works fine in LabVIEW 5.1 and
    > 6.01, but NOT in LabVIEW 6.1. In LabVIEW 6.1 the inner loop is never
    > executed if the count value is zero (which is correct), but the data
    > line running through the loop is not executed either, which is
    > different to what LabVIEW 5.1 and 6.01 do. There, the input string is
    > sent to the output of the inner loop correctly even if the loop
    > counter is zero. The solution is easy - I just have to connect the
    > output of the outer loop to the data line BEFORE it enters the inner
    > loop. But: I don't know if this is a LabVIEW 6.1 bug or if it is
    > supposed to be a feature, but it brings some incompatibility in
    > programming between the different LabVIEW versions.
    > Best regards,
    > Gabsi

  • Process implict cursor records only if the record count is not zero

    Hi All,
    Hope you are doing gud. I have a problem.
    I have a implicit cursor defined as shown below
    for c1 in (select * from table_test order by name)
    loop
    call to some procedures
    end loop;
    My question here is, I want to call the procedures only if the select statement count is non zero and raise an exception if count is zero.
    How would I acheive this..
    Please help
    Thanks all in advance

    user13276239 wrote:
    Hi All,
    Hope you are doing gud. I have a problem.
    I have a implicit cursor defined as shown below
    for c1 in (select * from table_test order by name)
    loop
    call to some procedures
    end loop;
    My question here is, I want to call the procedures only if the select statement count is non zero and raise an exception if count is zero.
    How would I acheive this..
    Please help
    Thanks all in advanceYou can apply count(*) group function,
    begin
    select count(*) into variable_1 from table_name;
    if variable_1 !=0 then --call to procedure
    else raise_application_error(-20000,'Invalid data');
    end if;
    end;

  • Generic counter with leading zeros

    Good evening everybody,
    I was searching the code of a generic counter with leading zeros, but I did not found anything over the Internet. Therefore, I code it all by myself.
    I give you the code, it will maybe helps someone.
    Only needed leading zeros are generated, which means the following sequences :
    0 - 1 - 2 - ... - 7 for a max of 7,or
    00 - 01 - 02 - ... - 23 - 24 - ... - 89 for a max of 89, or
    000 - 001 - 002 - ... - 432 for a max of 432.
    public class LeadingZerosCounter {
      public String[] counters = null;
      public LeadingZerosCounter(int maximum) {
        this.counters = new String[maximum];
      public String[] init() {
        int maxLeadingZeros = 1;
        int index0 = this.counters.length;
        while ((index0 /= 10) >= 10) {
          maxLeadingZeros += 1;
        int counter = 0;
        for (int index1 = 0; index1 < maxLeadingZeros + 1; index1++) {
          while (counter < java.lang.Math.pow(10, index1 + 1)) {
            String stringCounter = new String("");
            for(int index2 = 0; index2 < (maxLeadingZeros - index1); index2++) {
              stringCounter = stringCounter.concat("0");
            stringCounter = stringCounter.concat(new Integer(counter).toString());
            this.counters[counter] = stringCounter;
            System.out.println(this.counters[counter]);
            if (++counter == this.counters.length) {
              return(this.counters);
            else {
              // no action
        return(this.counters);
      public static void main(String[] args) {
        new LeadingZerosCounter(100).init();
    NOTE : the two return are mandatory.
    Try maximum raised to a power of 10 and maximum raised to a power of 10 + constant in [1; 9] to understand.
    If you find any solution to make it faster, please let me know.
    Have a nice day,
    Christophe

    I like Jos' idea better than mine (go figure - he's a better Javanista)....
    public class Counter {   
        private String pattern;
        private int count;
        private int max;
        public Counter(int max) throws IllegalArgumentException {
            if (max < 0) {
              throw new IllegalArgumentException("Max (" + max + ") must be a positive number");
            this.max = max;
            int len = String.valueOf(max).length();
            this.pattern = "%1$0" + len + "d";
        public boolean hasNext() {
            return count <= max;
        public String next() {
            String result = String.format(pattern, count);
            count++;
            return result;
        public static void main(String[] args) {
            // for demo purposes only;
            // replace with command-line arg parsing, if desired...
            String prefix = "picture_";
            String suffix = ".jpg";
            Counter c = new Counter(99);
            while (c.hasNext()) {
                System.out.println(prefix + c.next() + suffix);
            try {
                new Counter(-1);
            } catch (IllegalArgumentException e) {
                System.out.println("test: " + e.getMessage());
    }

  • 5th gen ipod counter stuck at 0:00

    Already tried the 5 r's with no success. which is to say ipod restored and all music seems to be loaded, but will not play with counter stuck on 0:00. Any ideas?

    First, to Athena53, these forums are user to user forums and besides Apple employees who monitor the forums for content, they generally do not answer questions here.
    Second, my own experience with the counter stuck at 0:00 is there is a bug in the 5th generation iPod firmware where when you wake up the iPod, plug in the headphones, then try to play something, it will often get stuck at 0:00. A reset of the iPod gets it out of that state.
    The work around is that the problem is plugging in the headphones first. Instead I start the iPod playing, THEN plug in the headphones and I never get the problem. And I have verified that it always occurs when the headphones are plugged in first then hitting play after the iPod wakes up.
    Regards,
    Patrick

  • Email counter stuck at 17

    email counter stuck at "17" even when no new messages. when new messages come in and get read it still reads "17"?

    Right-click Inbox - Mark Folder Read

  • How to display a row in Cross Tab when the count summary is zero

    My customer wants a row for all possible data, even when the count is zero.  How can I get a row to display when there is no data?  Using an example:  Display status for incidents - possible five statuses, but selection only results in four statuses because no incident were cancelled.  Customer wants all five statuses to display in cross tab with cancelled showing '0' (zero))
    Open
    WIP
    Cancelled
    Pending
    Closed

    This worked for the last guy who had a similar issue.
    Take a look at what it's doing. You should be able to use the same principal to meet your needs...
    I'm assuming that you'll only need to show 4 weeks at a time on your report.
    The easiest way to do it is by creating 8 separate formula fields:
    W1A
    W1RT
    W2A
    W2RT
    ... and so on
    I don't know how your data is coming across but the formula should go something loke this:
    W1A... IF datepart(ww,currentdate) - datepart(ww,) =0 THEN
    W1RT... IF datepart(ww,currentdate) - datepart(ww,) =0 THEN
    W2A... IF datepart(ww,currentdate) - datepart(ww,) =1 THEN
    W2RT... IF datepart(ww,currentdate) - datepart(ww,) =1 THEN
    ... and so on
    If I got you weekly criteria wrong, sorry. It's just a best guess.
    Anyway you should be able get the idea. It gives you the effect of a crosstab without the headaches of a crosstab.
    Hope this works for you,
    Jason
    Edited by: Jason Long on Jun 28, 2008 3:19 AM

  • In Point Stuck Above Zero

    I've been working in a LiveType doc and I cannot get the in point to register zero. I don't have any tracks (as far as I can see) that are taking up space at the beginning -- the first track is flush left against the in point marker.
    Any suggestions regarding what might have gotten 'stuck' into place that's causing my in point to start at 54;12?
    Thanks.

    Somewhere on your hard drive is a file called livetype.plist. Should be in a Library. Spotlight will find it, may take some variations.
    Trash it.
    bogiesan

  • New email count stuck

    I recently updated to Lion and since then, the new mail count of one of my email addresses in mail is stuck on 17 new emails. New emails come in, I see them, read them, delete them, and it still says 17. There are no hidden unread emails. I have even removed the problematic address and re-installed it. Same issue. The 4 other addresses are fine. I didn't realize how much I relied on that count throughout the day! Hoping someone can help.

    If deleting the email accounts and setting them back up again as allan suggested does not work, there might be an issue with the software on the iphone.
    You might want to try the reset and/or restore if necessary.
    If you do reset or restore here is an article from the apple support website that might help out.
    http://docs.info.apple.com/article.html?artnum=305740
    Hope this helps.

  • How I can check in formula field does Source table has rows count more than zero?

    I have 2 tables in data set source: tbl_Quote and tbl_Invoice.
    Report should show an Invoice Number. If an invoice isn't issued yet I want display an Order Number instead of Invoice Number.
    I'm using a formula field for this purpose.
    I tried formulas:
    1. IIF (count({tbl_qteInvoice.ID})=0, {tbl_qteQuotes.QuoteID}, {tbl_qteInvoice.ID})
    2. IIF (ISNULL({tbl_qteInvoice.ID}), {tbl_qteQuotes.QuoteID}, {tbl_qteInvoice.ID})
    But in the report the field is empty. I think this is because of a result of selection request is empty. 
    What function in Formula Editor I can use to check if a result of selection request is empty?
    Thanks.

    When I used the code:
    IF ISNULL({tbl_qteInvoice.ID}) Then  {tbl_qteQuotes.QuoteID}
    Else {tbl_qteInvoice.ID}
    the problem was resolved.
    Thanks to Vissu Pangam!

  • Counting down to zero from a specified number

    I'm sure this is a very simple thing to do, but I can't figure out how. I want to count down from a specified number to 0, then restart counting at that orginal number. The trick is that I need it to place it in a case structure, and have it restart counting when it switches states (i.e. from TRUE to FALSE and vice versa).
    Example: Say I want to count down from 2 (as specified in a constant). Should look like:
    FALSE
    2
    1
    0
    2
    1
    0
    2
    ---TRUE
    2
    1
    0
    2
    1
    ---FALSE
    2
    1
    0
    2
    1
    I'm sure this is easy to do, but I've been wracking my brain!
    Thanks!
    -Brendan

    While I don't know what you mean by "when it switches states", I have attached one solution using an event structure. Here "it" is simply a boolean control that switches states under operator control.
    See if this makes sense to you.
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    DownCounter.vi ‏30 KB

  • Width and heigth stuck at zero

    Hello,
    I have tried to create some Actionscript3 code to load
    pictures. A Loader loads the image and then I create a new Bitmap
    instance from the loader.content.constructor. But this instance has
    always width and height of zero, not matter what I try.
    Output of the attached code:
    DONE(x=0, y=125, w=0, h=0)
    Any help is appreciated.

    what's
    var duplicate:Bitmap = new imageLoader.content.constructor;
    supposed to do?

  • Advanced Data Grid with Count only returns zero

    I'm just getting started with Flex and currently having problems getting the AdvancedDataGrid to count the total number of records for a group. I have the following for the control but all I get in the StudentCount column is 0 for all grouped rows. Can someone point me in the right direction?
    Thanks!
    <mx:Panel x="75" y="10" width="933" height="797" layout="absolute">       
            <mx:AdvancedDataGrid x="65" y="10" id="adg1" designViewDataType="tree" width="821.5"  enabled="true" initialize="gc.refresh();" height="406" selectionMode="singleCell" editable="true">
            <mx:dataProvider>
                <mx:GroupingCollection id="gc" source="{dataXML.ROW}">
                        <mx:Grouping>
                            <mx:GroupingField name="APPLS_AREA_OF_INTEREST_DESC"/>
                            <mx:GroupingField name="APPLS_APDC_DESC">
                                   <mx:SummaryRow summaryPlacement="group">
                                          <mx:SummaryField dataField="APPLS_SSN_FRMT"
                                            label="StudentCount" operation="COUNT"/>
                                      </mx:SummaryRow>
                            </mx:GroupingField>
                        </mx:Grouping>
                </mx:GroupingCollection>
            </mx:dataProvider>
                <mx:columns>
                    <mx:AdvancedDataGridColumn headerText="Interest Desc" dataField="APPLS_AREA_OF_INTEREST_DESC"/>
                    <mx:AdvancedDataGridColumn headerText="Interest Code" dataField="APPLS_AREA_OF_INTEREST_CODE"/>
                    <mx:AdvancedDataGridColumn headerText="Total Students" dataField="StudentCount"/>
                    <mx:AdvancedDataGridColumn headerText="Darton ID" dataField="APPLS_SSN_FRMT"/>
                    <mx:AdvancedDataGridColumn headerText="Name" dataField="APPLS_FULLNAME_LFM"/>
                    <mx:AdvancedDataGridColumn headerText="Phone" dataField="APPLS_PHONE_NUMBER"/>
                    <mx:AdvancedDataGridColumn headerText="APDC Desc" dataField="APPLS_APDC_DESC"/>
                    <mx:AdvancedDataGridColumn headerText="APDC Code" dataField="APPLS_APDC_CODE"/>
                </mx:columns>
            </mx:AdvancedDataGrid>
        </mx:Panel>
    </mx:Application>

    I guess the count function only works on the numeric feilds.

  • Play counts resetting to zero after reaching 100 plays

    I've recently noticed my top played songs drop out of my 25 most played songs smart playlist. It seems to happen every time a song reaches 100 plays. Any ideas on a fix? Also is it possible to manually amend the play counts to get the 2 songs that this has happened to back to their correct play count?

    That is an odd bug. I read one report that iTunes 11 has a playcount bug where if you have "crossfade" enabled it won't increment the play counts. I haven't personally verified that one.
    As for manually incrementing the play counts. This Stack Exchange thread offers several possible methods: http://apple.stackexchange.com/questions/76576/how-do-i-correct-wrong-itunes-pla y-counts

  • Automatic download days count stuck to 63

    I have used an other ID to download some Italian books from the Apple Store on my iPhone 3GS
    I was told that the device was going to be associated with the new Apple ID for 90 days
    But the problem is that the countdown has been stuck to 63 days for the last week.
    Any ideas on how to fix it?
    Regards

    I ended up calling Apple Express Lane
    After asking me a lot of questions they did reset my account.
    So once again I can get my music on my iPhone.
    Regards

Maybe you are looking for

  • Low performance issue with EPM Add-in SP16 using Office Excel 2010

    We are having low performance issues using the EPM Excel Add-in SP16 with Excel 2010 and Windows 7 The same reports using Excel 2007 (Windows 7 or XP) run OK Anyone with the same issue? Thanks

  • Averaging 3D array into 1D array.

    Hi, I have a 3D array containing XY points of several loops and i am trying to average the data points of my array into a 1D array that should contain 1Loop with XY points. Can someone help me out? Thanks  Mutah Qui ose vaincra. Solved! Go to Solutio

  • Where do I find the Adobe PS Camera Raw plug in

    I have Adobe PS CS6 Extended.  Where do I find the Adobe PS Camera Raw plug in ???

  • Initial setup of SAP B-1

    We are in process of setting up SAP B-1 and would like to do it right the first time.  We are a USA based fishing lure manufacturer that has most of the assembly work done overseas.  (Haiti, Mexico, Philippines, China)  Consequently we are subject to

  • Nokia N77 version 3.0747.2.0.3 and Mac OS X Leopar...

    Hi i am using a Mac OS X 10.5.2 (Leopard) Operating system in my computer. Since I updated my Nokia N77's firmware to version 3.0747.2.0.3 yesterday, I couldn't make a successful Bluetooth connection on my Macbook Pro laptop. isync does not work, sen