Quantcast
Channel: Counter/Timer topics
Viewing all articles
Browse latest Browse all 1271

Counting and Outputting In The Same Program

$
0
0

Hello Eveyone.

 

I'm using a Daq 6211 to count the pulses of two quadrature encoders. With this same Daq 6211, I now want to control two hobby servo motors which both use PWM as their control technique.

 

I have successfully created separate V.I's in which I can count the encoder values just fine and another to control the servo's. 

 

My problem arises when I want to use both in the same VI. I know there are only two counters on this DAQ 6211 and therefore one encoder and one servo are sharing the same clock. I also understand I can't output a PWM signal and count in from the encoders at the same time.

 

I'm using them in State Machine however and both will never be running simultaneously but rather in different states. When i transition from the encoder state to the servo state i get the error. 

 

"NI Platform Services: The specified resource is reserved. The operation could not be completed as specified."

 

I know why this is happening but does anbody know of a way to use counters in such a way, ie to count and to output in different parts of a VI??.

 

Thanks in advance.


Viewing all articles
Browse latest Browse all 1271

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>