annuler
Affichage des résultats de 
Rechercher plutôt 
Vouliez-vous dire : 

How do I find the z index of the incremental encoder

Résolu !
Accéder à la solution

Hi,

This might be a simple answer for most people but I am struggling to get the z index position of the incremental encoder. I am using the DAQ assistant to read the encoder and can read the angle out perfectly but I have no idea how to read the z index.

 

Hardware - NI-USB 6229

0 Compliments
Message 1 sur 6
2 630 Visites
Solution
Accepté par l'auteur du sujet adi3012

Just to make sure to ask the obvious - have you double checked your wiring? Are you connected to the pins that you *think* you're connected to? Have you configured the correct pins in your DAQ Assistant?

 

 

Speaking of correct pins:

  • I noticed that in your DAQ Assistant, you have your A, B, and Z terminals set to PFI 13, 11, and 4, respectively.
  • Looking at the pinout diagrams here and here, it looks like CTR 1 (which you've selected) uses PFI 3, 11, and 4.

The difference is that you have have terminal A set to PFI 13, while it looks like it should be PFI 3.

(PFI 3 is both CTR 1 SRC and CTR 1 A. PFI 13 is just CTR 1 OUT.)

 

Now, since I cannot see your setup (and since I really am not experienced with setting up encoders), I do not know what difference this would make (maybe no difference at all).

 

But I wanted to make sure to ask the question, and point out what I noticed. I hope my comment isn't a waste of your time. 😊

-joeorbob

0 Compliments
Message 2 sur 6
2 595 Visites
Solution
Accepté par l'auteur du sujet adi3012

Just to stay clear on terminology, you won't be "reading" the z-index pulse.  You just want to see that the z-index will reset your encoder position back to 100 degrees, right?

 

In addition to checking pinout connections as joeorbob suggested, you should also check your encoder spec sheet for the correct A,B states during the Z-index pulse.  The Z-index pulse will typically be "quarter-cycle gated", meaning that the pulse occurs during only 1 of the 4 possible states of (A,B).  You need to configure your task to match what the encoder hardware is doing.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Compliments
Message 3 sur 6
2 573 Visites

Thanks for the response. So my A, B and Z are set to PF 13, 11 and 14 as I had changed the input terminals.

 

Here's my question - If these are the only 3 settings I use, I can read the encoder just fine but the value never resets (I have at z index - make encoder reading 0).

 

But if I take a wire from PF 14 (z index) and connect it to PF 4 (digital and timing I/O) to count the edges, everything suddenly works. This seems weird to me. Is this how its supposed to be? Am I supposed to be reading the Z index for this to work?

0 Compliments
Message 4 sur 6
2 528 Visites

Clearly, I messed up one of my pinout connections. Thanks a lot guys for your responses

0 Compliments
Message 5 sur 6
2 517 Visites

So my A, B and Z are set to PF 13, 11 and 14 as I had changed the input terminals.

In the DAQ Assistant you posted, you've configured Z for PFI 4 not PFI 14.   Apparently, you've physically wired the Z index to PFI 14 because...

 

if I take a wire from PF 14 (z index) and connect it to PF 4 (digital and timing I/O) to count the edges, everything suddenly works.

Change your configuration to say that Z is wired at PFI 14, then you won't need the physical wire to PFI 4 any more.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Compliments
Message 6 sur 6
2 514 Visites