How do I use daqmx to get encoder direction/count on M-series board?

I have an incremental dual channel  encoder from Rotalink. I want to take angular postion and angular speed from this encoder. My NI DAQ card is PCI 6221 which belongs to M series. First, soft-timing was used to get anuglar postion and sampling rate is set at 1Hz. The vi program works well. However, it does not produce  good results when the sampling frequency is increased to 100Hz. So I turned to hardware-timing. The example, "Find example>> Hardware Input and Output>>DAQmx>>Counter Measurements>>Position>>Meas Angular Pos-buff ext Clk.vi" gets the readings. A function generator which can produce pulses at the frequency rang from 1Hz-1Mhz was wired to PFI9 in accordance with "
You need to find your PFI pin numbers to know what to wire A,B and Z to on your m-series board, to do this go into max right click NI-DAQmx Tasks click Create New DAQmx Task >> Counter Input >>Position>>Linear, and setup the task for your measurement. It will tell you what the PFI lines are. You then need to look at the wiring diagram and connect it to the correct pins." as an external clock. The channel A and B were wired to PFI8 and PFI10 respectively. However, it still gives errors like 200284. Comments are grealy appreciated!

Hi Zibin
I have been trying to work out what is not working I need some more information
What frequency is your function generator actually generating?
What have you set your time out value to?
What exact errors are you getting and when do you get the error?
What would really be helpful is if you could send me your code because by the sound of it, it should just work the card is more then capable of doing what you want so chances are it is the code.
Regards
Tim M
NI UK

Similar Messages

  • How do I use daqmx to get encoder direction/count on E-series board?

    Hardware:
    PCI-6014
    Labview 7.1
    I have a linear actuator and wish to get distance/direction.  The
    motor has a quad encoder with phase A and B only.  I connected the
    lines according the the E-series, PFI-8 and PFI-6, and ground to
    digital ground. I then attempted to design a control with daqmx but
    failed.  I have tried the daqmx examples but none were attempting
    a reverse in direction.  Most examples given for direction change
    are for traditional daq control; i cant make a correlation on what to
    use to substite traditional daq with daqmx vi's. 
    2 questions:
    How do I use daqmx to get encoder direction/count on E-series board?
    Are there low pass filter vi's recommended for each phase connection to stabilize data?
    Thanks,
    Wayne Hilburn

    Hello Wayne,
    Take a look at the Count Digital Events.vi shipping example.  You can find this in LabVIEW by selecting Help >> Find Examples... then browsing to Hardware Input and Output >> DAQmx >> Counter Measurements >> Count Digital Events.
    If you set the "Count Direction" control to "Externally Controlled", you will be able to count up and down depending on which direction you rotate your encoder.  Make sure you wire Phase A to Ctr0 Source and Phase B to P0.6.  P0.6 is the up/down line for counter 0.
    I hope this helps.  Please let me know if you have any further questions.
    Regards,
    Sean C.

  • How can I use applet to get the desktop image of client

    hi,I have a question to ask u.
    How can I use applet to get the desktop image of client? Now I develop a web application and want user in the client to get his current image of the screen.And then save as a picture of jpeg format ,then upload it to the server?
    I have done an application to get the screen image and do upload file to server in a servlet with the http protocal.

    Since the desktop image is on the client's local hard drive, you'll need to look at trusted applets first.

  • How can i use adobe flash media encoder 3

    how can i use adobe flash media encoder 3

    Flash Media Live Encoder is NOT
    "a codec program to change the parameter of the video format"
    Adobe Flash Media Encoder is:
    http://www.adobe.com/devnet/flash/quickstart/video_encoder.html
    Are you just spamming...
    or is there a legit question involved?
    Adninjastrator

  • How do you use WLST to get a deployed Apps name?

    I am writing an application update script to make updating our environments quicker/easier with the following code from an ant build file:
    <wlst debug="true" failOnError="true">
    <script>
    connect('login','pwd','t3://...')
    updateApplication('${app.name}',block='true')
    </script>
    </wlst>
    However, b/c our application has a version in the manifest file, our application name looks like this:
    AppName-BuildNumber-TimeOfBuild
    Since the TimeOfBuild is always different from build to build it is impossible to hard code this value. Is there a way to get the application's name using WLST?
    connect(...)
    cd('AppDeployments')
    This shows me all applications deployed on the server, but inorder to go any farther I need the name of a specific app. I'm sure I am just overlooking an mbean somewhere, but I can't seem to find it! Any ideas??
    Thanks.
    Message was edited by:
    bftanner

    Ok, so I figured out how to get an applications name but I can't get the following script to work from an ant build file:
    <wlst debug="true" failonerror="false">
    <script>
    connect('system','weblogic','t3://...')
    apps=cmo.getAppDeployments()
    for app in apps:
    if app.getName().startswith("4X"):
    stopApplication(app,block='true')
    undeploy(app.getName(),targets='MS1,MS2',block='true')
    deploy('4X','//box/domains/applications/4X.ear',targets='MS1,MS2',stageMode='stage',block='true')
    apps=cmo.getAppDeployments()
    for app in apps:
    if app.getName().startswith("4X"):
         startApplication(app.getName(),block='true')
    </script>
    </wlst>
    When this is run I get the following error:
    BUILD FAILED
    C:\docume~1\dtanner\desktop\RELupdate.xml:134: Error executing the script snippe
    t
    connect('system','weblogic','t3://192.168.0.250:
    7001')
    apps=cmo.getAppDeployments()
    for app in apps:
    if app.getName().startswith("reporting-r
    eport"):
    stopApplication(app,block='true'
    undeploy(app,targets='MS1,MS2',b
    lock='true')
    deploy('reporting-report-server','//bfediapp3/do
    mains/applications/reporting-report-server.war',targets='MS1,MS2',stageMode='sta
    ge',block='true')
    apps=cmo.getAppDeployments()
    for app in apps:
    if app.getName().startswith("reporting-r
    eport"):
    startApplication(app,block='true
    due to:
    Traceback (innermost last):
    (no code object) at line 0
    SyntaxError: ('invalid syntax', ('<string>', 2, 33, '\t\t\t\tapps=cmo.getAppDepl
    oyments()'))
    Any Ideas??? Also, how can you keep the format i.e. tabs and spaces at the front of a line in these forums???
    Thanks.

  • How do I use iPhoto to get photos into 3G phone?

    Hi,
    I was wondering how best to import images into my iPhone 3G for viewing.
    Most of my image files are large high quality 2 -4 MB files.
    Is there an easy way to downsize the files for viewing on the iPhone 3G? Does iPhoto have a setting specific for import/export use with the iPhone?
    How do I set a specific photo as the phone's wallpaper and does it have to be specifically sized to use as wallpaper?

    Photos are synced via itunes. They are optimized automatically for viewing on the iphone.
    The users guide will explain how to set up syncing for your iphone.
    http://manuals.info.apple.com/enUS/iPhone_UserGuide.pdf
    Select a photo on your iphone, hit the icon in bottom left corner, it will give you the option of setting wallpaper.
    Read the guide, it will tell you how to use the iphone.

  • How do I use iCloud to get the info from my old iPhone 5 to my new one?

    I just got a new iPhone 5.  The girl in the store wiped my old phone (also a 5) and assured me that everything was backed up to iCloud and that I'd be able to get all my apps, photos, contacts etc onto the new phone - all i had to do was update the software first. Now that I've updated the software, I don't know how to get everything onto the new phone.  I have no apps, no contacts, nothing!  Can anybody help please?

    Go to Settings>General>Reset, tap Erase All Content and Settings, then go through the setup screens on the phone and when given the option choose Restore from iCloud Backup (see image below).  Be sure it is connected to wifi and your charger as this will take some time to complete.

  • How can I use evaluate to get the instance variable in customized tag

    1.
    At first , I create a class called bean,and declared several params in it and do not define any getter function for the param.
    class bean{
    String param = "test";
    SomeClass scObj = new SomeClass();
    2.
    The second ,I use
    request.setAttribute("beanObj",new bean());
    3.
    And then I wanna use the customized tag to show a text box , then initialize it's value.
    <salt:text name="param" value="beanObj.param">
    <salt:text name="obj" value="beanObj.scObj.func()">
    4.
    I tried the evaluator provided by JexlContext ,Struts, JSTL and it seems that if I do not define the getter for the variable ,I can not get the bean's instance variable's value.
    Expression e = ExpressionFactory.createExpression( value );
    JexlContext jc = JexlHelper.createContext();
    jc.getVars().put(strInitBeanName, request.getAttribute("beanObj"));
    Object obj = e.evaluate(jc);
    the result of the obj is null....
    Can anybody recommand some other evaluator can get the value of a instance variable from an object?

    do you have any other suggestion ? Nops, somebody else may have though. AFAIK, all lookups of the type
    beanName.propertyNameuse reflection on the getXXX() methods to access the property.
    Having said that, I guess you could write one though in a custom tag, using the same - reflection (you will ahve to rely on the java.lang.reflect.Field class quite heavily) - but that would be reinventing the wheel for most other functionality that you would have to include (like looking up the bean in scope etc)
    cheers,
    ram.

  • How can I use JDBC to get the db name in a db url ?

    Hi,
    My program needs to read a database url from a txt file and connect to the specify database. And my program also needs to know what's the database name. So DatabaseMetaData or Driver can retrieve the database name from the url ?
    Please brief me about that.
    thank a lot.

    You need to write a java program to read the text file with buffered streams. Then you need to use this file as a bean.
    In the same file you can have connection to your database.
    get theconnection and related things in your web application.
    Thanx,

  • How do I use Firefox to get Adobe Flash on my computer?

    I am not computer savvy so please make this easy for me to do.

    # Using Firefox go to http://get.adobe.com/flashplayer and download the Flash setup file (install_flash_player.exe)
    # Close Firefox
    # Run the Flash setup file that you downloaded to install Flash

  • How does one use Bonjour, or get it to work?

    Can anyone help me to use Bonjour?   It is a complete mystery to me.

    It's part of the operating system, used to communicate with external devices. There's really nothing you need to do. What makes you think you need to do something?

  • How can i use BAPI_SRM_DOC_GETLIST to get shopping card items/worklists

    Hello,
    I'll like to use BAPI_SRM_DOC_GETLIST to read shopping cart items for approver or/and requestor. I fail to use the correct RMS_ID, SPS_ID and the most important is which property_selections should be entered?
    Is there an alternative BAPI for that? As requirements only BAPIs have to be used. I know the FM SWN_UWL_GET_WORKLIST returns exactly the results i need but it is unfortunately not a BAPI.
    Regards,

    Hi,
    check for all this parameter.
    Short Description:  Reads all saved monitor sets
    BAPI Object  :SystemMonitorSet
    BAPI Method  :GetList
    Function
    You can determine the names of all existing monitor sets using this method. Using these names, you can then determine the names of the monitors that exist in each of the sets.
    Parameters (Import)
    EXTERNAL_USER_NAME
    Name of the user in the external system that initiated the method call
    Parameters (Export)
    MONITOR_SETS
    Table with the names of the existing monitor sets (Structure BAPIMSNAME, that consists of only the component NAME)
    RETURN
    Structure BAPIRET2 with the return values from the method call
    Exceptions
    MSG_EXT_USER_MISSING MSG_CANT_LOG MSG_NOT_LOGGED_ON MSG_NO_MONITOR_SETS_FOUND MSG_UNKNOWN_PROBLEM
    RFC Interface
    function BAPI_SYSTEM_MS_GETLIST
    importing
    EXTERNAL_USER_NAMElikeBAPIXMLOGR-EXTUSERtypeRFC_CHARlength16
    exporting
    RETURNstructureBAPIRET2length552numberoffields14
    tables
    MONITOR_SETSstructureBAPIMSNAMElength60numberoffields1
    exceptions
    Check your monitor sets.

  • How do I use a push button digital trigger with my 6034E DAQ board?

    I am only a Lab View toddler.
    I am currently using a push button, wired to PFIO/TRIG1 and DGND, with a anolog trigger. However noise is causing my program to be triggered. I was told that a digital trigger would help to reduce the random triggering. How do I create a push button digital trigger?
    Thanks

    implement a schmitt trigger.
    Struggling with Labview wrote in message
    <[email protected]>...
    >I am only a Lab View toddler.
    >I am currently using a push button, wired to PFIO/TRIG1 and DGND, with
    >a anolog trigger. However noise is causing my program to be triggered.
    >I was told that a digital trigger would help to reduce the random
    >triggering. How do I create a push button digital trigger?
    >Thanks

  • How do I use NI-Motion tools to directly control a P70360?

    I can currently control a P70360 via modbus commands. I am interested in using NI-Motion routines to do this, if possible. But all the examples and VIs seem to assume there is an intermediary controller card, between the AC Drive and my labview app. I don't need a controller card, I have labview... so, does NI-Motion support direct communication with a P70360?

    Well, never mind. I spoke with NI this morning, and NI-Motion only supports calls to their 73x0 motion controler cards. Silly me for thinking there might have been a ModBus instrument driver deleveloped for the P70360. I'll get back to Dannaher (manufacturer of the AC Drive), and work to tweak my ModBus routines. The problem we're having is it gets out of synch, without sending an error due to stall detection.

  • How do I use time capsule as a direct backup drive only connect to my macbook pro via ethernet cable

    I have recently abandoned my cable internet service provider and am using my iPad as a hotspot via verizon wireless service.  I am trying to reconfigure my time capsule as a back up drive only connected by an ethernet cable. 
    I was able to set it up on my new hotspot wireless net, but do not want to use it that way because of the data usage impact on my verizon wireless account.
    Hopefully there is an easy answer, but it is not intuitively obvious to me. 

    Well I have to say you can do it.. but if you are plugging and unplugging ethernet, you could just as easily plug and unplug an external USB drive.. and it will be faster and more reliable than the TC.
    I explained how to do the TC as a secondary network in the posts here. Look down the bottom of the discussion.
    https://discussions.apple.com/thread/4817218?tstart=30
    If any of that doesn't make sense just post again here..
    You can also do it with wireless if you accept using a USB wireless stick plugged into the Mac.. then you have two wireless clients and can connect simultaneously to two different networks.. using the same principles as above that you remove the gateway and dns problems that arise by manual settings.

Maybe you are looking for