Optima DMC-1xxx and DMC-18x2 Command Reference
CE
i
49
CE
FUNCTION: Configure Encoder
DESCRIPTION:
The CE command configures the encoder to the quadrature type or the pulse and direction
type. It also allows inverting the polarity of the encoders which reverses the direction of
the feedback. Note: when using a servo motor, the motor will run away. The
configuration applies independently to the main axes encoders and the auxiliary encoders.
When the MT command is configured for a stepper motor, the auxiliarty encoder (used to
count stepper pulses) will be forced to pulse and direction.
ARGUMENTS: QE n,n,n,n,n,n,n,n or CEA = n
where
n is an integer in the range of 0 to 15. Each integer is the sum of two integers M and N which
configure the main and the auxiliary encoders. The values of M and N are:
m = Main encoder type
n =
Auxiliary encoder type
0
Normal quadrature
0
Normal quadrature
1
Normal pulse and direction
4
Normal pulse and direction
2
Reversed quadrature
8
Reversed quadrature
3
Reversed pulse and direction
12
Reversed pulse and direction
For example: n = 10 implies m = 2 and n = 8, thus both encoders are reversed quadrature.
n = ?
Returns the value of the encoder configuration for the specified axes.
USAGE: DEFAULTS:
While Moving
Yes
Default Value
0
In a Program
Yes
Default Format
2.0
Command Line
Yes
Controller Usage
ALL CONTROLLERS
OPERAND USAGE:
_CEn contains the value of encoder type for the axis specified by `n'.
RELATED COMMANDS:
"
MT
"
Specify motor type
EXAMPLES:
CE 0, 3, 6, 2
Configure encoders
CE ?,?,?,?
Interrogate configuration
V = _CEA
Assign configuration to a variable
Note: When using pulse and direction encoders, the pulse signal is connected to CHA and the
direction signal is connected to CHB.