Optima DMC-1xxx and DMC-18x2 Command Reference
TS
i
194
TS
FUNCTION: Tell Switches
DESCRIPTION:
TS returns status information of the Home switch, Forward Limit switch Reverse Limit
switch, error conditions, motion condition and motor state. The value returned by this
command is decimal and represents an 8 bit value (decimal value ranges from 0 to 255).
Each bit represents the following status information:
Bit Status
Bit 7
Axis in motion if high
Bit 6
Axis error exceeds error limit if high
Bit 5
A motor off if high
Bit 4
Undefined
Bit 3
Forward Limit Switch Status inactive if high
Bit 2
Reverse Limit Switch Status inactive if high
Bit 1
Home A Switch Status
Bit 0
Latched
Note: For active high or active low configuration (CN command), these bits are '1' when the
switch is inactive and '0' when active.
ARGUMENTS: TS nnnnnnnnnn
where
n is A,B,C,D,E,F,G or H or any combination to specify the axis or axes
No argument will provide the status for all axes
USAGE: DEFAULTS:
While Moving
Yes
Default Value
-
In a Program
Yes
Default Format
3.0
Command Line
Yes
Controller Usage
ALL CONTROLLERS
OPERAND USAGE:
_TS contains the current status of the switches.
EXAMPLES:
V1=_TSB
Assigns value of TSB to the variable V1
V1=
Interrogate value of variable V1
015 (returned value)
Decimal value corresponding to bit pattern 00001111
Y axis not in motion (bit 7 - has a value of 0)
Y axis error limit not exceeded (bit 6 has a value of 0)
Y axis motor is on (bit 5 has a value of 0)
Y axis forward limit is inactive (bit 3 has a value of 1)
Y axis reverse limit is inactive (bit 2 has a value of 1)
Y axis home switch is high (bit 1 has a value of 1)
Y axis latch is not armed (bit 0 has a value of 1)