LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Sampling Rotary Encoder- Error -201319

Hi all,

I am trying to sample voltages while using the rotary encoder as my sample clock. Every time the encoder rotates a degree it outputs a signal and I'm using that signal to sample values at that instant.

 

I keep getting Error -201319:

Possible reason(s):

Sample Clock pulse occurred before the previous sample was acquired from all channels in the task. Use a Sample Clock rate that allows time for the device to acquire samples from all channels. If you are using an external Sample Clock, ensure that clock signal is within the jitter and voltage level specifications and without glitches.

 

My program is shown below:

system_imge.JPG

0 Kudos
Message 1 of 7
(4,003 Views)

Update:

I have solved this via a Digital Filter through the timing diagram property node.

Message 2 of 7
(3,988 Views)

Hi,

Could you explain or show how you solved this problem, maybe attaching a imagen of your code?

Thank you so much.

0 Kudos
Message 3 of 7
(3,557 Views)

@edisson.castano wrote:

Hi,

Could you explain or show how you solved this problem, maybe attaching a imagen of your code?

Thank you so much.


You are replying to a 2 year old thread.  

 

However, Its worthwhile to come back at this for clarity.  I will make some assumptions about the OPs situation.

 

Likely, the OP encountered some glitches coming from his rotary encoder (Not too surprising considering that there would be vibrations in the rotary encoder's shaft that would manifest as glitches on the rising and falling edges)

Enabling digital filtering of the sample clock sourced from that encoder would ignore the glitches until the pulse width was at least 1/2 of the min width specified in the filter. available from the DAQmx Timing Property node

Example_VI.png


"Should be" isn't "Is" -Jay
0 Kudos
Message 4 of 7
(3,552 Views)

Hi Jeff,

First, thanks for the answer, also could you show me an example for using this property node, as location inside block diagram and connection for correct operation?

Thanks again.

0 Kudos
Message 5 of 7
(3,546 Views)

 I'll make you this deal.

 

Show code by snippet tell us what hardware you  are using and explain what you see.  I'm on a phone so.... no LabVIEW.


"Should be" isn't "Is" -Jay
0 Kudos
Message 6 of 7
(3,540 Views)

Hi Jeff,

I am acquiring a pressure signal from an internal combustion engine timing by an external clock (encoder), code starts to acquire but after a moment this stops and show two error types 201319 or 200019. Hardware is PCIe-6351 for data acquisition. 

0 Kudos
Message 7 of 7
(3,521 Views)