A standard reference point for motion controllers

A coordinate frame is a point of reference that defines the six degrees of freedom (DoF) in a PLCopen controller. A programmer needs to know how the different coordinate frames interact and which ones are important to understand.

Understanding the differences between the coordinate frames and how they interact with each other is the key to accomplishing successful motion using groups. In Part 4 of PLCopen, the global standard for motion control on IEC 61131-3 programmable controllers, the concept of multi-axis coordinated moves using groups was introduced. Groups are collections of axes on a common mechanism that work together to provide a path of travel in 3-D space. Examples include gantry systems, articulated arm robots, delta robots, or linkage mechanisms; any device where multiple axes work together to provide multi-dimensional motion.

As part of this new capability, the concept of coordinate frames (see reference below) in the controller became an important topic to understand. A coordinate frame is a point of reference that defines the six degrees of freedom (DoF): X, Y, and Z Cartesian coordinates, and Rx, Ry, and Rz angles (known as Euler angles) that describe the rotation about each of the axes. Every mechanism, part, or work cell controlled has its own coordinate frame. Since a PLCopen controller can control multiple groups, with each group acting on multiple parts, it is important to recognize how the different coordinate frames interact, and which are important for the programmer to understand.

Each coordinate frame has an origin that defines the zero point in all coordinates. The directions of each of the coordinate axes are determined by the right-hand rule (see Figure 1). If the index finger is pointing in the positive X direction, the extended middle finger, held at a right angle to the index finger, points in the positive Y direction and the extended thumb points in the positive Z direction.

Angular direction is determined using the right-hand grip rule (see Figure 2). With the thumb pointing in the positive direction of an axis, the direction around which the fingers curl around the axis is the positive rotational direction for that axis.

Motor position

Ultimately, a controller is commanding the position of individual motors. Each axis in the group has its own axis coordinate system (ACS), which is a rotational position of the motor. For most complex mechanisms such as articulated-arm robots, delta robots, and linkage mechanisms, the individual ACS positions don’t mean anything on their own; it’s the coordination of these axes that determine the mechanism’s position through the use of kinematic calculations. These calculations either can be done internally to the controller or by a separate robot controller.

The base coordinate frame for each group is the machine coordinate system (MCS). The manufacturer of the mechanism specifies the origin of the MCS. For articulated arm robots and delta robots, it is usually located at the robot’s base. The controller then performs the kinematic calculations to determine the tool plate coordinate system (TPCS), which is the end of the mechanism itself. This coordinate frame is not useful to the programmer on its own, but it is the origin used to define the position of the tooling. The tooling has its own coordinate frame, the tool coordinate system (TCS).

Commanded position

Generally the tooling is centered on the end of the mechanism, so this may be as simple as an offset in the +z direction of the TPCS, perhaps with an Rz component to account for rotation. The TCS is used most commonly when using jogging and teaching positions, but it isn’t used often in automated motion. The origin of the TCS is the tool center point (TCP), which is the point of interest when commanding a move.When a move in the MCS is called, it is the TCP that moves to that position (see Figure 3).

Since each group has its own MCS origin, moving multiple groups to the same position in space requires each group to have its own commanded position relative to its MCS position. If two picking robots are picking from the same conveyor, for example, individual moves to the same position on the conveyor would require different MCS position commands.

To simplify moving in this type of shared space, each group’s MCS origin can be offset from the origin of the world coordinate system (WCS). Each work cell has only one WCS origin. When individual groups are configured, an offset—with six DoF—to the WCS origin is defined. This allows multiple mechanisms to use a common coordinate frame to simplify programming.

The final coordinate frame for consideration is the part coordinate system (PCS). This frame is used to define the position and orientation of individual objects in world space. The origin of this coordinate frame is on the part itself and moves with the part. This is useful where individual parts are to be acted upon, such as in pick-and-place applications. Other applications include conveyor tracking, where the part is moving down a conveyor line. In this case, the PCS is moving relative to the WCS and MCS origins, so moving a mechanism’s TCP to a specific PCS position must account for the changing offset between the coordinate frames (see Figure 4).

Understanding the differences between the coordinate frames and how they interact with each other is the key to accomplishing successful motion using groups in IEC. The different coordinate systems are used together to accomplish the operation required.

A conveyor tracking example

For example, in a conveyor tracking application, one might first command a move in the MCS to position the TCP to the start of the tracking zone. As the part’s location and orientation is defined, the conveyor tracking routine calculates the offset of the part to the mechanism’s MCS origin. This offset defines the PCS of the part and the relationship of the MCS with the conveyor tracking function, adjusting the PCS offset as the part moves. The user then defines a move in PCS space to pick up the part. Since the PCS offset has six DoF, if the box is turned on the conveyor belt this also can be accounted for. The user then performs a move in PCS space to pick up the part.

The orientation of the tool to match the part is automatic (if desired) as it is accounted for in the offset between the coordinate systems. The same PCS position is used for every pick-up, with only the PCS offset changing when new parts are encountered. Since the conveyor tracking function constantly is updating the offset of the PCS, the TCP also tracks along the positive direction of the conveyor to account for part movement.

Mark Wilder, motion application engineer, Yaskawa America Inc. Edited by Chris Vavra, production editor, Control Engineering, CFE Media, [email protected]

MORE ANSWERS

KEYWORDS: PLCopen, controller, motion control

  • A coordinate frame is a point of reference that defines the six degrees of freedom.
  • Ultimately, a controller is commanding the position of individual motors.
  • Understand the differences between the coordinate frames and how they interact.

Consider this:

What else should be considered when programming coordinate frames in a PLCopen controller?