03-20-2013 10:26 AM
Can someone please expain how to combine reading the inputs and sampling a clock in same task on a NI-9401. I have an application I need to read changing inputs while the clock is sampling one of the input lines. If I configure a task to read inputs and one to sample the clock, Labview reports the - 200022 error. Is there a way to combine the 2 tasks to avoid the error?
03-21-2013 12:40 PM
Hi QRP,
Which chassis are you using with your NI-9401? You won't be able to create two digital input tasks with the 9401. You also won't be able to use the clock to sample inputs while also sampling it on one task. It is possible however to internally route the clock signal to a counter input task which you can use to measure frequency, edges, pulse width, etc. Please refer to this knowledgebase for routing signals internally http://digital.ni.com/public.nsf/allkb/8A85E97855EDADC98625730C00065F58 . Regards
Doug W
03-21-2013 01:56 PM
Hi Doug, thanks for your reply. The 9401 is tied into a 9188 chassis. Will you look at the attached VI and let me know how I could resolve it. I think I understand what your saying, but maybe if you look at the sample code it will give you a better idea of what is going on that is causing the reserve error to occur. Currently I need read inputs coming back from a motor while also monitoring counts/steps from that motor. The Step/count is wired in on cDAQ9188-1718DFBMod3/port0/line4 for the cnt1 and I need to monitor input lines 5-7 for directional data on the same port. I think this is where the problem is, having the counter run on the same port I need to pull inputs from, not sure though. Maybe you have a better idea on how to configure this to work properly since I'm not an expert with the 9401 module. Have a look at the code and let me know what you think.
Thank you so much!
03-21-2013 03:40 PM
Here is also the missing .ctl for running VI. Thanks again for helping.
03-21-2013 09:54 PM
I figured out what the problem was. Thanks again.