CM1-T

RSLogix

RSLogix Resources

See Datasheets and Downloads to download the UDTs, AOIs and sample program.

User Data Types

Direct Control Operation

CM1T_Axis

The CM1-T_Axis data type defines how the bytes are assigned withing the IO message.

Name

Data Type

Description

Input

SINT[36]

Data coming from the CM1-T

Output

SINT[28]

Data going to the CM1-T

us50Counter

DINT

Motor 50us counter

ModeOfOperation

SINT

Select control mode

ModeOfOperationDisplay

SINT

Current control mode

Controlword

CM1T_Controlword

Control operation

DriveStatus

CM1T_DriveStatus

Drive status

PositionTarget

DINT

Target position for position move

SpeedTarget

DINT

Max speed for target move

TorqueTarget

INT

Max torque for target move

AccelerationTarget

INT

Acceleration for target move

DecelerationTarget

INT

Deceleration for target move

PositionActual

DINT

Actual position of the motor

TargetActual

DINT

1ms target position of the motor

PositionError

DINT

Error between actual and target

SpeedActual

DINT

Actual speed of the motor

CurrentActual

INT

Actual current percentage of the motor (0.1% rated)

OverloadActual

INT

0.1% of overload torque

DCVoltage

INT

24V DC input value at 0.1V

AnalogIN

INT

10bit analog input (0-1023)

DigitalIN

SINT

Read digital inputs

DigitalOUT

SINT

Set digital outputs

Temperature

SINT

Drive temperature in °C

ErrorCode

SINT

ErrorCode is currently reserved and returns 0.
Use MotorStatus to get motor error information

ReadAddress1

INT

Address of register to read

ReadValue1

DINT

Value of read register

ReadValueAddress1

INT

Address of the current read register

WriteValue1

DINT

Register write value

WriteRegister1

INT

Write register address

CM1T_Controlword

Name

Data Type

Description

Start

BOOL

Start/New set point

Halt

BOOL

Halt current motion

Relative_Move

BOOL

Execute position move as relative

Speed_Control

BOOL

Execute move as a speed only move

Disable

BOOL

Disable the drive

Reset_Error

BOOL

Reset error with rising edge

Set_to_Zero

BOOL

Set the current position to zero with rising edge

Home

BOOL

Home the motor with rising edge

CM1T_DriveStatus

Name

Data Type

Description

StatusValue

SINT

Motor status and error type

StatusValue1

SINT

Additional motor status

In_Position

BOOL

Motor is in position and ready to move

Moving

BOOL

Motor is currently moving

Disabled

BOOL

Drive is disabled

Error

BOOL

Drive is in error state

MoveComplete

BOOL

Move is completed

NewStartRequired

BOOL

Rising edge required to restart motion

HomeAchieved

BOOL

Homing has been achieved

CML Operation

CM1T_CMLAxis

The CM1-T_CMLAxis data type defines how the bytes are assigned withing the IO message.

Name

Data Type

Description

Input

SINT[60]

Data coming from the CM1-T

Output

SINT[44]

Data going to the CM1-T

us50Counter

DINT

Motor 50us counter

DriveStatus

CM1T_DriveStatus

Drive status

PositionActual

DINT

Actual position of the motor

TargetActual

DINT

1ms target position of the motor

PositionError

DINT

Error between actual and target

SpeedActual

DINT

Actual speed of the motor

CurrentActual

INT

Actual current percentage of the motor (0.1% rated)

OverloadActual

INT

0.1% of overload torque

DCVoltage

INT

24V DC input value at 0.1V

AnalogIN

INT

10bit analog input (0-1023)

DigitalIN

SINT

Read digital inputs

DigitalOUT

SINT

Set digital outputs

Temperature

SINT

Drive temperature in °C

ErrorCode

SINT

(1) - ErrorCode is currently unused and returns 0. Use MotorStatus to get motor error information

WriteValue

DINT[5]

Register write value (array)

Address of register to read

ReadValue

DINT[5]

Value of read register (array)

WriteAddress

INT[5]

Write register address (array)

ReadAddress

INT[5]

Read address register (array)

ReadValueAddress

INT[5]

Address of the current returned read register (array)

CM1T_CMLDriveStatus

Name

Data Type

Description

StatusValue

SINT

Motor status and error type

StatusValue1

SINT

Additional motor status

In_Position

BOOL

Motor is in position and ready to move

Moving

BOOL

Motor is currently moving

Disabled

BOOL

Drive is disabled

Error

BOOL

Drive is in error state

HomeAchieved

BOOL

Homing has been achieved

Add-On Instructions

Direct Control Operation

The following tables outlines the available add-on instructions

Name

Description

Required

CM1T_DataExchange

Exchanges data between the drive and the drive variable

Yes

CM1T_Enable

Enables the motor

No

CM1T_Disable

Disables the motor

No

CM1T_ClearFault

Clears any faults on the drive

No

CM1_TControlMode

Set the type of control mode required

No

CM1T_MoveAbsolute

Executes an absolute position move

No

CM1T_MoveRelative

Executes a relative position move

No

CM1T_MoveSpeed

Executes a speed move

No

CM1T_MoveTorque

Executes a torque move

No

CM1T_MoveHome

Executes a home routine

No

CM1T_ReadRegister

Read a motor register value

No

CM1T_WriteRegister

Write a value to a motor register

No


CM1T_DataExchange

This AOI is required if any other AOIs are used. One instance is required for each CM1-T axis being controlled.

It has a number of functions

  1. It exchanges data between the motor connections and the motor/drive tag.

  2. It places the Controlword bits into the Controlword data type

  3. It retrieves the drive status and places it into the DriveStatus variable.

dataexchange.PNG
Parameters

Operand

Type

Format

Description

CM1T_DataExchange

CM1T_DataExchange

Tag

Instance tag for the AOI

DriveInput

AB:ETHERNET_MODULE_SINT_32Bytes:I:0

Tag

Module defined connection input for the CM1-T

DriveOutput

AB:ETHERNET_MODULE_SINT_20Bytes:O:0

Tag

Module defined connection output for the CM1-T

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Execution

Condition

Action

Prescan

  • Initialize tag and local variables

  • rung-condition-out is set to false

Rung Condition - TRUE

  • Process DataExchange

  • rung-condition-out is set to true

Rung Condition - FALSE

N/A - rung-condition-out is set to false

CM1T_Enable

This AOI enables the motor and drive. Torque will be present.

enable.PNG
Parameters

Operand

Type

Format

Description

CM1T_Enable

CM1T_Enable

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  1. Drive disable bit is set to false (drive is enabled)

  2. rung-condition-out is set

    1. true - when drive status bit shows drive enabled

    2. false - when drive status bit show drive disabled

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_Disable

This AOI disables the motor and drive. Torque will not be present

disable.PNG
Parameters

Operand

Type

Format

Description

CM1T_Disable

CM1T_Disable

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  1. Drive disable bit is set to true (drive is disabled)

  2. rung-condition-out is set

    1. true - when drive status bit shows drive disabled

    2. false - when drive status bit show drive enabled

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_ClearFault

This AOI clears any drive fault/error condition. This will also enable the motor. The rung-out-condition indicates the drive error state (true or false).

Parameters

Operand

Type

Format

Description

CM1T_ClearFault

CM1T_ClearFault

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Execution

Condition

Action

Prescan

N/A

rung-condition-in is true

  • Assert clear error bit

  • rung-condition-out is set

    • true - when drive status bit shows drive error

    • false - when drive status bit shows no drive error

rung-condition-in is false

  • Deassert clear error bit

  • rung-condition-out is set

    • true - when drive status bit shows drive error

    • false - when drive status bit shows no drive error

CM1T_ControlMode

This AOI set the motion control mode.

ControlMode.PNG
Parameters

Operand

Type

Format

Description

CM1T_Disable

CM1T_ControlMode

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

ControlMode_Value

DINT

Immediate/Tag

A value that sets the type of control mode required

0 - POSITION
1 - SPEED
2 - TORQUE

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Sets ModeOfOperation value and Controlword bits to set the control mode required

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_MoveAbsolute

This AOI will execute an absolute position move.

MoveAbsolute.PNG
Parameters

Operand

Type

Format

Description

CM1T_MoveAbsolute

CM1T_MoveAbsolute

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Position

DINT

Immediate/
Tag

Target absolute position

Speed

DINT

Immediate/
Tag

Target speed

Acceleration

INT

Immediate/
Tag

Target acceleration

Deceleration (optional)

INT

Immediate/
Tag

Target deceleration
(uses acceleration if set to 0)

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and sets start bit

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_MoveRelative

This AOI will execute a relative position move.

MoveRelative.PNG
Parameters

Operand

Type

Format

Description

CM1T_MoveRelative

CM1T_MoveRelative

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Position

DINT

Immediate/
Tag

Target absolute position

Speed

DINT

Immediate/
Tag

Target speed

Acceleration

INT

Immediate/
Tag

Target acceleration

Deceleration (optional)

INT

Immediate/
Tag

Target deceleration
(uses acceleration if set to 0)

Start

BOOL

Immediate/
Tag

0 → 1 transition will execute a new relative move.

If a motion is currently in process it will increment relative to the current position

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and sets start bit as per Start input variable

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_MoveSpeed

This AOI will execute a speed move.

MoveSpeed.PNG
Parameters

Operand

Type

Format

Description

CM1T_MoveSpeed

CM1T_MoveSpeed

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Speed

DINT

Immediate/
Tag

Target speed

Acceleration

INT

Immediate/
Tag

Target acceleration

Deceleration (optional)

INT

Immediate/
Tag

Target deceleration
(uses acceleration if set to 0)

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and start the speed move

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_MoveTorque

This AOI will execute a torque move.

MoveTorque.PNG
Parameters

Operand

Type

Format

Description

CM1T_MoveSpeed

CM1T_MoveSpeed

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Torque

INT

Immediate/
Tag

Target torque

MaxSpeed

DINT

Immediate/
Tag

Target speed

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and start the torque move

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_ReadRegister

This AOI loads a register address to read. It returns the register value. The value is returned when the ReadRegister (output) address and the ReadValueAddress (input) address are equal.

ReadRegister.PNG
Parameters

Operand

Type

Format

Description

CM1T_ReadRegister

CM1T_ReadRegister

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Address

INT

Immediate/
Tag

Address of register to read

Value

DINT

Tag

Tag to load the returned value

Done

BOOL

Tag

Optional output indicating the value has been returned.

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and start the torque move

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_WriteRegister

This AOI loads a register address and value to write. Once the write cycle is complete the done output is set.

WriteRegister.PNG
Parameters

Operand

Type

Format

Description

CM1TWriteRegister

CM1T_WriteRegister

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Address

INT

Immediate/
Tag

Address of register to write

Value

DINT

Immediate/
Tag

Tag/value to load into the write value

Done

BOOL

Tag

Optional output indicating the value has been written.

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and start the torque move

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CML Operation

The following tables outlines the available add-on instructions

Name

Description

Required

CM1T_CMLDataExchange

Exchanges data between the drive and the drive variable

Yes

CM1T_CMLReadRegister

Reads a motor register

No

CM1T_CMLWriteRegister

Writes to a motor register

No

CM1T_CMLDataExchange

This AOI is required if any other CML AOIs are used. One instance is required for each CM1-T axis being controlled.

It has a number of functions

  1. It exchanges data between the motor connections and the motor/drive tag.

  2. It retrieves the drive status and places it into the DriveStatus variable.

CMLDataExchange.PNG
Parameters

Operand

Type

Format

Description

CM1T_DataExchange

CM1T_DataExchange

Tag

Instance tag for the AOI

DriveInput

AB:ETHERNET_MODULE_SINT_32Bytes:I:0

Tag

Module defined connection input for the CM1-T

DriveOutput

AB:ETHERNET_MODULE_SINT_20Bytes:O:0

Tag

Module defined connection output for the CM1-T

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Execution

Condition

Action

Prescan

N/A - rung-condition-out is set to false

Rung Condition - TRUE

  • Process DataExchange

  • rung-condition-out is set to true

Rung Condition - FALSE

N/A - rung-condition-out is set to false

CM1T_CMLReadRegister

This AOI loads a register address to read. It returns the register value. The value is returned when the ReadRegister (output) address and the ReadValueAddress (input) address are equal.

CMLReadRegister.PNG
Parameters

Operand

Type

Format

Description

CM1T_ReadRegister

CM1T_ReadRegister

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Slot

SINT

Immediate/
Tag

There are 5 slots available. Enter 1-5.

Address

INT

Immediate/
Tag

Address of register to read

Value

DINT

Tag

Tag to load the returned value

Done

BOOL

Tag

Optional output indicating the value has been returned.

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and start the torque move

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

CM1T_CMLWriteRegister

This AOI loads a register address and value to write. Once the write cycle is complete the done output is set.

CMLWriteRegister.PNG
Parameters

Operand

Type

Format

Description

CM1TWriteRegister

CM1T_WriteRegister

Tag

Instance tag for the AOI

CM1T_Axis

CM1T_Axis

Tag

Working tag for the CM1-T axis

Slot

SINT

Immediate/
Tag

There are 5 slots available. Enter 1-5.

Address

INT

Immediate/
Tag

Address of register to write

Value

DINT

Immediate/
Tag

Tag/value to load into the write value

Done

BOOL

Tag

Optional output indicating the value has been written.

Execution

Condition

Action

prescan

N/A - rung-condition-out is set to false

rung-condition-in is true

  • Processes values and start the torque move

  • rung-condition-out is true

rung-condition-in is false

N/A - rung-condition-out is set to false

Adding CM1-T and AOIs to Project

Download and extract the EtherNet/IP support file.

The file includes the following

  1. Direct Control Operation

    1. CM1T_SampleApplication.ACD - This a sample application built RSLogix. It shows how to

      1. Run the motors in each of the modes

      2. Reset from faults

      3. Enable/Disable the motor

    2. User Data Types (UDT)

    3. Add-On Instructions (AOI)

  2. CML Operation

    1. CM1T_CMLSampleApplication.ACD - RSLogix application to read/write motor registers

    2. CM1T_CMLSampleApplication.crp - Control Room project with CML sample program.

      1. Executes incremental move if variable is set (Run, distance, speed and acceleration set from PLC)

      2. Increments counter variable (Variable read in PLC)

    3. User Data Types (UDT)

    4. Add-On Instructions (AOI)

Direct Control Operation

Import User Data Types (UDTs)

The following steps show how to import the UDTs used by the CM1-T module.

  1. Right click on Data Types → User-Defined and select "Import Data Type..."

    import udt.PNG
  2. Browse to the location where the CM1T_AOI support file was extracted. Select the CM1T_Axis and click import. 

    UDT - CM1T_Axis.PNG
  3. On the Import Configuration window click OK

  4. The CM1T_Axis, CM1T_Controlword and CM1T_DriveStatus should all have been import as shown below. If they were not repeat steps 1-3 with the CM1T_Controlword and CM1T_DriveStatus.

    UDT- all.PNG
Import Add-On Instructions (AOIs)

The following steps show how to import the CM1-T modules AOIs. The only required AOI is CM1T_DataExchange. All the other AOIs depend on this one to populate the data type.

  1. Right click on Add-On Instructions and select "Import Add-On Instruction..."

    Import AOI.PNG
  2. Browse to the extracted AOI folder and select CM1T_DataExchange. Click Import

    AOI window.PNG
  3. On the Configuration Import window click OK.

  4. Repeat steps 1-3 until all required AOIs are imported

  5. The Add-On Instruction tree will look as follows once all AOIs are imported

    AOI-all.PNG
Add CM1-T Module

The following steps show how to add an CM1-T module in RSLogix. At present the EtheNet/IP is in testing and the CM1-T is added a a generic module.

  1. Open an existing project or start a new one

  2. In the Controller Organizer expand I/O Configuration and right click on "Ethernet". Select "New Module"

    new module.PNG
  3. Search "Generic", Select "ETHERNET-MODULE" and click Create

    generic.PNG
  4. Fill in the following properties shown below

    module general.PNG
    1. Name: Give the drive a name. E.g. CM1T_Drive, Axis1, LabelXAxis, etc

    2. Comm Format: Data - SINT

    3. IP Address: Enter the IP Address of the CM1-T you are adding.

    4. Connection Parameters

      1. Input: Assembly Instance = 100, Size = 36

      2. Output: Assembly Instance = 112, Size = 28

      3. Configuration: Assembly Instance = 1, Size = 0

    5. Click OK

  5. The Module Properties window should open. If it does not double click on the newly created module inside the Ethernet heading.
    Select the Connection Tab

    module connection.PNG
    1. Set the packet interval as required. Typically this would be 10ms.

    2. Check the boxes as shown in the picture above

The final set of steps below shows how to add the CM1T_DataExchange AOI and configure it to exchange data between the tag created for the CM1-T and the CM1-T module. A single instance of the CM1T_DataExchange should be created per module. There should never be more than one per module.

  1. Add the CM1T_DataExchange AOI to a rung

    new_DataExchange.PNG
  2. Create a CM1T_DataExchange Tag and attached it to this instance. In this example it is called FB_CM1T_DataExchnage

    name - DataExchange.PNG
  3. Expand the DriveInput drop down menu and select the CM1T_Drive module input create earlier

    driveinput.PNG
  4. Expand the DriveOuput drop down menu and select the CM1T_Drive module output create earlier

    output.PNG
  5. Create a new CM1T_Axis tag and attach it to the instruction. This is the tag that will be used in all other AOIs

    CM1T_1 axis tag.PNG


All CM1-T AOIs are now ready to be used. See the example application for more details on running the motor.

Example Logic - Direct Control Operation Sample

The following logic is from the Direct operation sample application. The example shows how to run the motor in each of the modes, enable, disable, halt, and recover from an error.

Unknown Attachment

CML Operation

Import User Data Types (UDTs)

Following the instructions for Direct Control Operation except import 

  • CM1T_CMLAxis

  • CM1T_CMLDriveStatus

Import Add-On Instructions (AOIs)

Follow the instructions for Direct Control Operation except import

  • CM1T_CMLDataExchange

  • CM1T_CMLReadRegister

  • CM1T_CMLWriteRegister

Add CM1-T Module

Follow the instructions for Direct Control Operation except on step 4 enter the following configuration data

CMLIOConfiguration.PNG
  1. Name: Give the drive a name. E.g. CM1T_Drive, Axis1, LabelXAxis, etc

  2. Comm Format: Data - SINT

  3. IP Address: Enter the IP Address of the CM1-T you are adding.

  4. Connection Parameters

    1. Input: Assembly Instance = 101, Size = 60

    2. Output: Assembly Instance = 113, Size = 44

    3. Configuration: Assembly Instance = 1, Size = 0

  5. Click OK

Example Logic - CML Operation Sample

The following sample logic is supplied with the AOIs. It requires the motor to be programmed with a CML program. The program does the following

  1. Motor indexes continuously by the distance amount defined by PLC

  2. Motor indexes with speed and acceleration defined by PLC

  3. Indexing is started and stopped by PLC

  4. A counter showing number of indexes is read by the PLC

CML Operation Sample.PNG