LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Quadrature encoder interface to PCI-6229

Glad to inform that the  encoder link up went about like a breeze and the readings obtained are very stable.

The coding was done based on the attached  VI and virtually no modifications were required. It worked the first attempt.

However I noticed one behaviour : the angle value is retentive. Meaning even after the encoder has stopped, the value remains which is a good thing and expected.  Now how do  I clear the stored value in the  DAQmx read function ? Since  I am using an  incremental encoder, there are many occassions where I would like to "zero" the reading and take fresh values from that point  onwards.

 I am also trying , but can someone modify the attched VI to include an on-demand  reset button ? ( wheels must not be re-invented  Smiley Wink )

Thaanks

Raghunathan
Raghunathan
LabVIEW to Automate Hydraulic Test rigs.
0 Kudos
Message 11 of 16
(1,845 Views)

Raghunathan,

The easiest way to do this would be to stop and restart the task. Another option, which would not require a restart, would be to have a boolean on the front panel control a digital output which is internally routed to the Z index of your counter. Of course, this would require your A or B line to be in some pre-determined state for the Z index to trigger a reset of the count register.

Hope this helps,
Ryan Verret
Product Marketing Engineer
Signal Generators
National Instruments
0 Kudos
Message 12 of 16
(1,661 Views)
' The easiest way to do this would be to stop and restart the task. "

Looked easy . But could not implement it so easily. Would be glad to get some ideas on the implementation with the attcahed VI as a sample.

( I cannot use the Z- bit as the required condition for A,B channels are difficult to be met  by software alone )

Thanks

raghunathan

Raghunathan
LabVIEW to Automate Hydraulic Test rigs.
0 Kudos
Message 13 of 16
(1,647 Views)
OK I think I figured it out. I am attaching the VI where  I have added this functionality. But will have to wait till I get back to the machine to try it out. In the meanwhile any corrections may  please be pointed out.

Thanks

raghunathan
Raghunathan
LabVIEW to Automate Hydraulic Test rigs.
0 Kudos
Message 14 of 16
(1,639 Views)
Chris,

The Measurement Hardware Driver Development Kit (MH DDK) forum is available here:

http://forums.ni.com/ni/board?board.id=90

Please search these forums for a solution, and if you cannot find one, try your post there.

Hope this helps,

Ryan Verret
Product Marketing Engineer
Signal Generators
National Instruments
0 Kudos
Message 15 of 16
(1,627 Views)
Hey people,
I've been looking for the info about the ctr0 and ctr1 for months!!!! well actually I didn't even know about those when I began with my encoder problem.  Anyways thank you guys works perfect now.
 
ZZ
0 Kudos
Message 16 of 16
(1,302 Views)