Professional Documents
Culture Documents
K300 ML1400 Indexing Example v1 - 0
K300 ML1400 Indexing Example v1 - 0
K300 ML1400 Indexing Example v1 - 0
Sample Code
1) Introduction
This sample code example shows one method to write Index configurations to the Kinetix
300 drive in Indexing Mode via Class 3 explicit messaging.
The Indexing program code takes the values to configure a motion index profile and writes it
to the Kinetix 300 Index Assembly object.
This document will cover the following items:
Steps required for basic drive setup.
Brief explanation of the program code.
Assembly objects layout.
Page 2 of 7
Sample Code
3) Logix500 Program Code
The example code was written for a MicroLogix 1400 controller. The example code is
located in the following 4 program files:
Note: You will need to modify three (3) message instructions to enter in the IP Address of
the Kinetix 300 drive in your system. They are located as follows:
Example:
Open the MSG Setup Screen.
Go to the MuliHop tab and enter in your IP Address in the To Address box.
Page 3 of 7
Sample Code
4) Assembly Objects Layout
The Input Assembly is identified by Instance 113 and consists of the following 64 bytes (see Appendix C
of the User Manual, 2097-UM001, for detailed descriptions of each of these fields):
Bytes
Bit 7
Bit 6
Reserved
Registration
Captured
Bit 5
Current
Limit
Reached
1-3
4
Reserved
Homed
Homing
Active
Reserved
Reserved
Reserved
Bit 1
Bit 0
Reserved
Reserved
In Position
Fault
Enabled
Reserved
Motion
Complete
Indexing
Active
Ready
In Speed
Window
Zero
Speed
Input A3
Input A2
Input A1
Input C3
Input C2
Input C1
Neg. Limit
Switch
Engaged
Pos. Limit
Switch
Engaged
Reserved
Reserved
Reserved
Input B4
Input B3
Input B2
13-15
16
Bit 2
Reserved
9-11
12
Bit 3
Reserved
5-7
8
Bit 4
Input B1
Input A4
Reserved
Reserved
Reserved
Reserved
17-19
Reserved
Input C4
Reserved
20-23
24-27
28-31
32-35
36-39
40-43
44-47
48-51
52-55
56-59
60-63
Page 4 of 7
Sample Code
The Output Assembly is identified by Instance 114 and consists of the following 52 bytes (see Appendix C
of the User Manual, 2097-UM001, for detailed descriptions of each of these fields):
Bytes
0
Bit 7
Drive
Enable
Bit 6
Bit 5
Bit 4
Reserved
Start
Homing
Abort
Homing
1-3
4-7
Bit 3
Bit 2
Define
Home
Start
Motion
Bit 1
Reserved
Bit 0
Abort
Index
Reserved
Starting Index, applies only if drive mode is Indexing (DINT)
External Reference, applies only if drive mode is External Reference (DINT):
0 = current
1 = velocity
8-11
2 = incremental position
3 = absolute position
4 = incremental registration
5 = absolute registration
2
(REAL)
(REAL)
12-15
16-19
20-23
24-27
28-31
32-35
36-39
40-43
44-47
48-51
Page 5 of 7
(Mode dependant
Sample Code
The Index Assembly is identified by Instance 115 and consists of the following 48 bytes (see Appendix E
of the User Manual, 2097-UM001, for detailed descriptions of each of these fields):
Bytes
0-3
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
4-7
1 = Incremental
2 = Registration Absolute
3 = Registration Incremental
4 = Blended
Index Move Type/Motion Profile (DINT)
8-11
0 = Trapezoidal
1 = S-Curve
12-15
16-19
20-23
24-27
28-31
32-35
36-39
(REAL)
40-43
0 = Stop
1 = Wait For Start
2 = Next Index
44-47
Page 6 of 7
Bit 2
Bit 1
Bit 0
Sample Code
Disclaimer
This sample code delivered by Rockwell Automation is just an example of how to control a
K300 drive.
Disclaimer Of Warranty
THE MATERIALS DELIVERED WITH THIS EXAMPLE ARE PROVIDED "AS IS" WITHOUT
WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION,
ALL IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE,
NONINFRINGEMENT OR OTHER VIOLATION OF RIGHTS. ROCKWELL AUTOMATION DOES NOT
WARRANT OR MAKE ANY REPRESENTATIONS REGARDING THE USE, VALIDITY, ACCURACY, OR
RELIABILITY OF, OR THE RESULTS OF THE USE OF, OR OTHERWISE, RESPECTING THE
MATERIALS MAINTAINED ON OR ACCESSED BY WAY OF THIS SITE OR ANY WEB SITES LINKED TO
THIS SITE. FURTHERMORE, ALL WARRANTIES, CONDITIONS, REPRESENTATIONS, INDEMNITIES
AND GUARANTEES WITH RESPECT TO THE ACCURACY, OPERATION, CAPACITY, SPEED,
FUNCTIONALITY, QUALIFICATIONS, OR CAPABILITIES OF THE SOFTWARE, SYSTEMS AND
SERVICES COMPRISING OR UTILIZED IN THE OPERATION OF THIS CODE, WHETHER EXPRESS OR
IMPLIED, ARISING BY LAW, CUSTOM, PRIOR ORAL OR WRITTEN STATEMENTS BY ROCKWELL
AUTOMATION, OR OTHERWISE (INCLUDING, BUT NOT LIMITED TO ANY WARRANTY OF
SATISFACTORY QUALITY, MERCHANTABILITY, FITNESS FOR PARTICULAR PURPOSE, TITLE AND
NON-INFRINGEMENT) ARE HEREBY EXPRESSLY EXCLUDED AND DISCLAIMED.
Disclaimer Of Liability
UNDER NO CIRCUMSTANCES (INCLUDING NEGLIGENCE) WILL ROCKWELL AUTOMATION BE
LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL, PUNITIVE OR CONSEQUENTIAL
DAMAGES (INCLUDING WITHOUT LIMITATION, BUSINESS INTERRUPTION, DELAYS, LOSS OF DATA
OR PROFIT) ARISING OUT OF THE POSTING (OR THE INABILITY TO POST) OR THE USE (OR THE
INABILITY TO USE) THE DELIVERED CODE EVEN IF ROCKWELL AUTOMATION HAS BEEN ADVISED
OF THE POSSIBILITY OF SUCH DAMAGES.
Page 7 of 7