Skip to content

Kinematics

Configuring kinematic joints


Joints are the objects that describe the way rigid bodies move relative to each other. Kinematic joints are an essential part of any robotic system, as they allow movements.

Kinematic joints can be classified into different types, based on the type of movement they allow. For example, hinge joints allow for rotational movement, while prismatic joints allow for linear movement. By combining the kinematic joints, you can create a wide range of movements and manipulate objects in a variety of ways. For example, a car's wheels are attached to the car frame by a hinge joint. They can only rotate around a specific axis. A multi-body system is thus composed of several objects connected by joints forming a kinematic chain.

At any time, the kinematic chain can be seen from the INTERACT Menu > Physics > Show Kinematic graph.


XDE provides several types of joints :

Fixed Joint

A fixed joint constrains all degrees of freedom with respect to the parent object.
In the Unity inspector, a fixed joint only has one parameter: the object to which the selected object is attached to. If there is no parent object, the object is fixed with respect to the world. A fixed joint is not necessarily static: it can be attached to a moving rigidbody.

XdeRigidbody picking

You can use the picker icon on any XdeRigidbody field to directly pick a XdeRigidbody in your 3D view.

Free Joint

A free joint moves freely along and between the axes of the six degrees of freedom (meaning that it can freely rotate and translate). If gravity is enabled, the object will be in free fall.

40% center

Hinge Joint

A hinge joint - also called a revolute joint - only allows one rotation with respect to a specific axis.

  • Parent Body: the preceding body in the kinematic chain
  • Configuration Transform: the frame in which the axis and center of the joint is expressed (usually the object itself)
  • Axis: the axis of the joint (which can be a combination of axes)
  • Initial Position: the position of the joint at the beginning of the simulation
  • Damping: add physical damping in the joint
  • Friction: add static friction in the joint

Hinge limits

You can set limits that exceed 360°. This way, you can create a rotation with multiple turn limits.

Guess axis computation

The most probable hinge axis is computed on physicalization. This computation can be long on large models and can be disabled from Unity's preference window.

Prismatic Joint

A prismatic joint only allows one translation with respect to a specific axis.

  • Parent Body: the preceding body in the kinematic chain
  • Configuration Transform: the frame in which the axis and center of the joint is expressed (usually the object itself)
  • Axis: the axis of the joint (which can be a combination of axes)
  • Initial Position: the position of the joint at the beginning of the simulation
  • Min/Max limit: to configure joint limits
  • Damping: add physical damping in the joint
  • Friction: add static friction in the joint

Ball Joint

A ball joint allows 3 rotations around a specific center point.

  • Parent Body: the preceding body in the kinematic chain.
  • Configuration Transform: the frame in which the center of the joint is expressed (usually the object itself).
  • Center: the center of the joint.
  • Initial Velocity: the velocity of the joint at the beginning of the simulation
  • Rotation Damping: add physical damping in the joint

Mapped joint

A mapped joint allows control over a specific degree of freedom with another joint.

When the controlling unit joint position changes, the position of this joint also changes. The two positions are linked by a scale factor and an offset, using the following relation:

position_mapped = offset + scale * position_controlling

If the map joint is a hinge joint while the controlling joint is a prismatic one, note that the conversion is 1 meter <-> 1 radian.

This joint can be used to simulate gears or belt systems.

Backlash

If you want to simulate the backlash of the gear, you can set a parent hinge joint on the same axis. Limit this joint range to the backlash angular value and set friction to zero. When your gear will turn in one direction, the hinge joint will move first due to the low friction. When it is at the angular limit, it can't move further, and your mapped joint will be driven.

Belt joint

You can also configure a belt joint by setting a positive ratio, which will lead to both wheels turning in the same direction.

Helical joint

A Helical joint allows one rotation and one translation linked together by a constant pitch. This is the same motion as a screw.

  • Lead: Amount of linear travel in millimeters for a full turn.
  • Min/Max limit: Angular joints limits in degrees. Since translation and rotation are linked, any limit on rotational movement will also lock the translation accordingly.

ISO metric screw

Lead is equal to pitch if your screw is single-start threadform, which is the common case. You can find pitch values for the ISO screw here.

Left-Handed threads

Unity uses an indirect coordinate systems (left-handed). The helical joint thread is therefore also left-handed. To use a right-handed thread, consider using a negative lead value.

Weldable joint and weld property

It is generally not possible to change the kinematic graph at runtime. You can tune and modify properties, but it is not possible to change them e.g. a Hinge joint into a Prismatic joint.

However, a joint can be welded to its parent body. A welded joint become fixed to its kinematic ancestor. Leave the Parent body field empty to weld the object to the environment. This property can be modified at runtime. You can for example lock a joint when it reaches a specific position.

There is a special kind of joint - Weldable joint, which is a joint that acts similarly to a free joint or a fixed joint depending on whether or not you weld it.

This is very useful for assembly process simulation, when you need to manipulate parts and fix them to another body.

During the simulation, different methods of a XdeWeldableJoint may be interesting to call:

  • Unweld(): to switch from a Fixed Joint to a Free Joint
  • Weld(): to switch from a Free Joint to a Fixed Joint
  • SetParent(): to change the connected body (the joint must be unwelded beforehand).

Weldable joint

It is preferable to use a Weldable joint rather than a Free joint in order to have access to more options.

Cylindrical joint

There might be situations in which you need to have both translation and rotation, an example being the simulation of a door lock. You can also set custom limits on translation or rotation.

Alt text
  • Parent Body: the preceding body in the kinematic chain
  • Configuration Transform: the frame in which the axis and center of the joint is expressed (usually the object itself)
  • Center: the local position of the axis of the joint (which can be a combination of axes)
  • Axis: the rotation (and translation) axis of the joint (which can be a combination of axes), in local coordinates
  • Initial Position: the position of the joint at the beginning of the simulation
  • Rotation Damping: add physical damping in the joint (rotation)
  • Translation Damping: add physical damping in the joint (translation)

Planar joint

If you need to constrain on a plane and also allow rotation, you should use this joint. Note that there are no limits on this joint.

Alt text
  • Parent Body: the preceding body in the kinematic chain
  • Planar Frame: the frame in which the axis and center of the joint is expressed (usually the object itself)
  • Center: the local position of the axis of the joint (which can be a combination of axes)
  • Reference Position: the target position towards which the current position moves, at any time of the simulation (if it's different to the initial position, you need to have a damping other than zero)
  • Initial Position: the position of the joint at the beginning of the simulation
  • Initial Angle: the orientation of the joint at the beginning of the simulation
  • Angular Damping: add physical damping in the joint (rotation)
  • Linear Damping: add physical damping in the joint (translation)

Point on line joint

You should use this joint if you need to constrain translation along a single axis, but additionally require complete freedom to rotate around all axes. This joint constrains translation in the same way that a prismatic joint does. Rotation is however not constrained at all, which is what differentiates a point on line joint from a prismatic joint.

Alt text
  • Parent Body: the preceding body in the kinematic chain
  • Configuration Transform: the frame in which the axis and center of the joint is expressed (usually the object itself)
  • Center: the local position of the axis of the joint (which can be a combination of axes)
  • Axis: the axis of the joint (which can be a combination of axes)
  • Reference Position: the target position towards which the current position moves, at any time of the simulation (if it's different to the initial position, you need to have a damping other than zero)
  • Initial Position: the position of the joint at the beginning of the simulation
  • Initial Rotation Velocity: the angular velocity of the joint at the beginning of the simulation
  • Initial Translation Velocity: the translation velocity of the joint at the beginning of the simulation
  • Damping: add physical damping in the joint
  • Translation Damping: add physical damping in the joint (translation)
  • Min/Max Prismatic Limit: to configure the joint's translation limits

Alt text

Joint axis

Joint axis is set in the configuration transform local pivot frame.

To ease the selection of your joint axis we have introduced the Pick Axis tool. It allows you to pick a specific surface or edge of your part directly from the 3D scene like in your favorite CAD software:

Pick axis

While using the pick axis tool, you can press I to invert the direction of the detected axis.

Triangle mode

When complex shapes are not detected, switching to triangle mode detection might help. Using Shift+T allows users to select the normal of a Triangle. Use again Shift+T to get back to shape detection.

  • Initial angle/position: initial angle/position at runtime. For instance, if you want your robot to be in a given configuration when starting the simulation. The initial configuration must stay between joint limits.

  • Reference angle/position: The reference angle/position is an offset along the joint axis. You can use it to have the same frame in both your INTERACT simulation and in your real world model. You can then use the same angle or distance value for your joint. Changing the reference angle/position shifts the initial and limits position accordingly.

Closed loop

Closed-loop dynamics refers to the relationship between the motion and force of closed-loop mechanisms. A robot mechanism is said to be closed loop if it includes one or more kinematic loops, which are cycles in the mechanism’s connectivity graph.

To close the kinematic loop, INTERACT > Physics > Create closed loop. It creates a child GameObject with a default hinge joint, albeit without the XdeRigidbody component. This hinge joint have two bodies field: Child body and Parent body.

Closed chain kinematic can be created using the Child body/Parent body relationship.

A joint constraint cannot be actuated or monitored.

Multiple joints

It is not possible to add multiple joints on the same gameobject to combine movements. In order to combine joints, you must create additional gameobject, even if they are just empty.

A common problem is that the system created is likely over-constrained. Over-constrained system might prevent any movement. In this case, it is advised to relax one constraint by replacing a joint by another with more degrees of freedom.

Most frequently, you can replace one of the Hinge joint in the system by a Point on line joint. Another common substitution is to replace an Hinge joint by a Ball joint.

Replace a joint

To replace a joint, you can re-physicalize (Shift+P) a XdeRigidbody and select another joint. Axis and limits will be kept if applicable. For example, a Point on line joint will keep the same axis as an hinge joint.