Application Notes
MCode: Configuring Liberty MDrive Inputs
Home > Resources > Application Notes > MCode: Configuring Liberty MDrive Inputs
Description
The input setup (Is) command is used to set the functionality of all inputs, digital and analog. The parameters define the input point to be configured, the desired functionality, and the active response state high or low.
Applicable
- Liberty* MDrive
Requirements
- +5 to +24 VDC supply (if using sourcing inputs).
- Input devices
- Cabling: 22 AWG shielded twisted pairs for I/O, Shielded twisted pair for power, AWG determined by length and current.
Details
Is – Input setup command
The input setup (Is) command is used to set the functionality of all inputs, digital and analog. The parameters define the input point to be configured, the desired functionality, and the active response state high or low.
Digital inputs
Usage
When applied to the digital inputs 1 – 4 the input setup command is utilized thus:
Is=<input #>, <function>, <active>
Example:
1 | Is=2,5,1 ‘configure input 2 to be a soft stop input. |
Digital input functions
All digital input parameters are listed in the table below.
Inputs | |
---|---|
Input | Notes |
1 | May be programmed to any function, not available in NEMA 17 sizes |
2 | Maybe programmed to any function except capture |
3 | Maybe programmed to any function except capture |
4 | Maybe programmed to any function except capture |
Functions | |
Function | Description |
0 | General purpose input (default) |
1 | Homing function will function as specified by the homing command (HM). |
2 | Limit + will function as specified by the limit command (LM). |
3 | Limit —, will function as specified by the limit command (LM). |
4 | G0 input, will run program at address 1 upon activation. |
5 | Soft stop, stops motion with deceleration and halts program execution. If program is paused (PS), input is ignored. |
6 | Pause, pause/resume program with motion |
7 | Jog +, Will Jog motor in the positive direction at Max. Velocity (VM). The Jog Enable (JE) Flag must be set for this to function. |
8 | Jog —, Will Jog motor in thenegative direction at max. velocity (VM). The jog enable (JE) flag must be set for this to function. |
11 | Reset, When set as RESET input, then the action is equivalent to a ^C entered into a terminal. Note: If setting the input to sourcing, active true, ground the input first or a reset will occur. |
12 | Capture input witll operate with the Trip Capture (TC) trip to run a subroutine when active NOTE: THIS FUNCTION APPLIES TO INPUT 1 ONLY! |
Active | |
State | Description |
0 | Active when LOW |
1 | Active when HIGH (default) |
Analog Input
Usage
When used to setup the analog input, the Is command is used in this manner:
Is=5, <mode>, <level>
Example:
1 | Is=5,9,1 ‘configure the analog input to be a voltage input with a range of 0 to 10 volts |
Analog input details
Modes | |
---|---|
Description | |
9 | Voltage mode (default) |
10 | Current mode |
Levels | |
Description | |
0 | 0 to +5V (voltage mode), 0 to 20 mA (current mode) (default) |
1 | 0 to 10V (voltage mode), 4 to 20 mA (current mode) |
Encoder inputs
Usage and details
The encoder index mark only has one settable parameter, which is the active response state.
Is=6,0,<active>
This can be active when LOW (0, default) or active when HIGH (1).
General input usage commands
Mnemonic | Function | Usage example | Description |
---|---|---|---|
Individual input point control commands | |||
I<input> | Read an individual input state as 1 or 0 | PR I4 | Read the state of input 4 |
CL k3, I4=1 | Call subroutine k3 when I/O 4 is ACTIVE (1) | ||
Binary coded decimal (BCD) commands | |||
IN | Read all logic inputs as a group. | PR IN | Read inputs1 – 4 as a group (response will be 0 – 15 based on I1 being LSb and I4 being MSb) Note on NEMA 17 models the response range will be 0-7. |
Input filtering commands | |||
D<input>=<0-255> | Set the input filtering to time in milliseconds | D1=150 | Set the filter for input 1 to 150 milliseconds. Input must be stable for 150 msec before the change will be detected. |
Input trip | |||
TI=<input>, <subroutine> | Sets the operation of an input trip | TI=2, K3 | Execute subroutine labeled K3 when input 2 is active. |
When it comes to your form, fit and function requirements, don’t settle. Get precisely what you need working with us. We know motion.
Contact us with any questions about how we can help you with your motion application or for assistance with your IMS products.