Changeset 16793 for trunk


Ignore:
Timestamp:
06/10/13 12:01:19 (11 years ago)
Author:
tbretz
Message:
Fixed a problem with the 32bit shift operator when evaluating the 40bit incomplete flag; wait for ftmctrl to be in Valid rather than Idle.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/scripts/takeRun.js

    r16744 r16793  
    209209            dim.send("MCP/RESET");
    210210
    211             dim.wait("FTM_CONTROL", "Idle",      3000);
     211            dim.wait("FTM_CONTROL", "Valid",     3000);
    212212            dim.wait("FAD_CONTROL", "Connected", 3000);
    213213            dim.wait("MCP",         "Idle",      3000);
     
    236236        console.out(" - FTM_CONTROL: "+dim.state("FTM_CONTROL").name);
    237237
    238         dim.wait("FTM_CONTROL", "Idle",      3000);
     238        dim.wait("FTM_CONTROL", "Valid",     3000);
    239239        dim.wait("FAD_CONTROL", "Connected", 3000);
    240240        dim.wait("MCP",         "Idle",      3000);
    241241
     242        var str = incomplete.toString(2);
     243        var len = str.length;
     244
    242245        var list = [];
    243         for (var i=0; i<40; i++)
    244             if (incomplete&(1<<i))
     246        for (var i=0; i<str.length; i++)
     247            if (str[str.length-i-1]=='1')
    245248                list.push(i);
    246249
Note: See TracChangeset for help on using the changeset viewer.