LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using Z-Index on Linear Encoder to determine Absolute Position

Frank,

 

The reason for changeing the Z-Index properties is to be able to use reference marks on a linear encoder to determine absolute position as a part of a "homing" routine.  How I envision this working is the encoder is moving and returning a value with the Z-Index disabled.  At some point based upon either internal or external signals it is determined that the slide is approaching "home."  At this point, the Z-Index is enabled so that when the encoder reaches the next reference mark, the it sets the value to the Z-Index Value which in this case would be zero.  Then the Z-Index would be disabled again.

0 Kudos
Message 11 of 16
(1,676 Views)

You're correct that you can't have multiple tasks accessing the same counter.  I'm not sure if you can do an on-demand sample while also running a buffered acquisition, maybe not.  I don't quite understand what you mean by using the Sample Clock from the Z-Index to get the current position.  Do you have the ability to stop motion at some point, such that you could run a homing sequence, then stop the motor and the DAQ task and reconfigure without losing position?  If so, you might use a sequence of three tasks: 1) buffered acquisition of two points, 2) load the Z reset value and run to the next Z mark (or back to one of the ones found in the previous step), 3) normal operation with Z reload disabled.

0 Kudos
Message 12 of 16
(1,667 Views)

Coming from a machine tool background, an absolute position encoder should not need "homing". What you would need to do is "reference" your counter value when you mechanically connect everything. With your device at a fixed and repeatable distance, your need to measue that distance or set it to a known dimension. The absolute position feature comes into play after turning everything off and back on again. The encoder should know where your are at. does the counter card have internal batteries for this?

 

http://content.heidenhain.de/presentation/basics/en/index/N10338/N10395/N10395.html

 

Some absolute measurement info in here.

http://www.heidenhain.de/fileadmin/pdb/media/img/571_470-24.pdf

 

will read your counter card specs in a minute, but does it mention support for absolute position control?

0 Kudos
Message 13 of 16
(1,665 Views)

Re-read the original message.  The encoder is not an absolute encoder, but it has unevenly spaced Z index marks.  The user can determine absolute position by measuring the number of relative encoder counts between any two consecutive index marks.  That distance is unique across the entire travel distance, so it allows the user to determine absolute position.  It is still necessary to find those two index marks when the system starts.

0 Kudos
Message 14 of 16
(1,657 Views)

Oops!!. Sorry about that. Look in the pdf file about distance coded reference marks and a formula for them. Must pass two of them after powerup

0 Kudos
Message 15 of 16
(1,653 Views)

I am using Linear Encoder from Renishaw.  As mentioned in earlier blog, first move the motor very slowly and check where index is re-setting, going to zero (homing routine)..  Then stop mtor immediately and read count position.  Since, it will stop some number of steps (motor steps, stepper motor) further from the real zero position.  Based on your encoder to motor driver pulse (assuming stepper) ratio set the motor current position to correlated number.  The above step is run when Z is enabled.  Then disable Z and you should be okay. Z enable is part of DAQmx active channel property.  You need to implement that state within your code.

 

 

0 Kudos
Message 16 of 16
(1,607 Views)