Skip to content
Vasily edited this page Sep 27, 2025 · 124 revisions

Common usage plan

PartDesign workbench

  1. Create robot Parts (Std_Part) with body (PartDesign_Body) and LCS (local coordinate system) of joint places. Like this - parts You can also import parts from other CAD systems (FreeCAD supports many formats).

RobotCAD (OVERCROSS) workbench

  1. Create Robot
  2. Create Links and Joints. Tip: enable "show all" in links properties and fill Label and Label2 (Label 2 used as name of link, joint in URDF).
  3. Fill Links properties: Real, Visual Tip: Real and Visual can be same object. Tip: Only one solid body for link supported currently. Also nested parts in other parts with non-zero placement used as Real, Visual, Collision are not supported.
  4. Fill Joints with Links (parent, child)
  5. Do "Set placement - as system" or "Set placement - by orienteer" of "Origin" of joint.
  6. Do "Set placement - as system" of "Mounted placement" of link (optional). This is necessary if the zero coordinate of the object is not at the junction position or necessary to correct orientation of link.
  7. Create Collisions based on tool - "Box from bounded box" (or sphere, cylinder).
  8. Choose material of whole robot or individual links
  9. Use mass and inertia automatic calculation tool. Tip: Do it before export (because project changes can influence to inertia).
  10. Use "Export URDF" tool (it will create ROS 2 package with launchers for RViz and Gazebo).
  11. (optional) Use "External extended code generator" tool. It will generate startup script and docker related code with all dependencies (in that case you dont need to install ROS2 or Gazebo manually).
    1. Run: cd docker/iron && bash run_basic.bash in generated project . It will build and run container with project and let you container shell. After you can run Gazebo by ROS2 launcher. See README.md generated in package.

"Set placement - as system" tool.

Upstream docs

Command-SetPlacement - docs of old "Set Placement" (deprecated) tool.

New tool "Set placement - as system" works in a similar way but always transfer firt orienteer (second selection) to position of second orienteer (third selection) and in relate to this transfer will be moved link or joint.

Fist Set Origin of join and after (optional) Set MountedPlacement of link.

Tips:

Usage of face as reference for LCS - "Inertia" attachment type can help in some cases where need to place LCS on face.

Set Origin of join

The Origin property of the joint, which will then be the origin tag of the export URDF. Origin is joint transform from parent link.

You can directly change Origin of joints (click to ellipsis at property, change and click to apply).

Automatic ways of setting Origin of joint by:

"Set placement - by orienteer" tool.

Select (with pressed Ctrl):

  1. joint,
  2. LCS (target) where joint should be,

Joint will be moved to placement of target LCS.

OR

"Set placement - as system" tool.

Select (with pressed Ctrl):

  1. joint,
  2. LCS (source) in child Link,
  3. LCS (target) anywhere (f.e. in parent link).
  4. Click to "Set placement - as system" tool.

Source LCS will be moved to placement of target LCS and related Joint will be moved relative to source LCS. Source LCS and Joint will in same relative placement as before move.

Set MountedPlacement of link.

The MountedPlacement is used to bring the shapes that constitute the link to the correct position. This placement is the transform from the origin of the shape to the location of the joint that is parent of this link.

You can directly change MountedPlacement of links (click to ellipsis at property, change and click to apply).

Automatic way of setting MountedPlacement of link by "Set placement - as system" tool.

Select (with pressed Ctrl):

  1. link,
  2. LCS (source) (point where joint must be connect to shape of this link, orientation of LCS will be orientation of this link),
  3. joint or any object (f.e. LCS)
  4. Click to "Set placement - as system" tool.

Source LCS will be moved to placement of target joint or any other selected object (f.e. LCS) and related link will be moved relative to source LCS. Source LCS and link will in same relative placement as before move.

Set placement of sensor

Add sensor link (sensor body) and sensor pedestal (sensor stand for convenience of placement) - optional.

Connect (with joints) links in next way: Any robot link -> sensor pedestal link (optional) -> sensor body link.

Set placement of sensor pedestal link with any Set placemnt tools.

Set placement of sensor body link with "Set placement - sensor" tool. Select any face (it will be sit place of sensor body link) of sensor pedestal link and any face of sensor body link, click "Set placement - sensor" tool (that links must be in joint before). It will orientate parent joint of sensor body link and X-axis (red) will see to forward of sensor.

(Optional) If X-axis (red) see to back rotate parent joint of sensor body link by Y-axis, in that case you also should correct Mounted Placement of Sensor body link by "Set placement - as group" tool and 2 LCS (one on sensor body link back face and second on sensor pedestal link face for sensor). See example of sensor placed on side face of sensor pedestal where used "Set placement - as group" for correction of MountedPlacement.

robotcad_correction_of_mountedplacement_of_sensor_body_link1

In many cases after align X-axis (red) you also should align Z-axis (blue). You should rotate that joint (parent joint of sensor body link) by X-axis (red) and align Z-axis (blue) to top.

Correct position of parent joint of sensor body link is X-axis see to forward of sensor, Z-axis see to top of sensor. Like at screenshoot (sensor on front face of pedestal).

robotcad_sensor_orientation2

You see 2 different examples (sensor on side face of pedestal and sensor on front face of pedestal) on screens.

Add any sensor for links (from sensors tool) to sensor body link.

Now you able to see your sensor view in Gazebo (after generate and run package). Some sensors, such as the camera, are also automatically binded to ROS2 (bind is in launch file), and you will see the sensors topics in ROS2. For other sensors, you need to add the binding of the sensor from Gazebo to ROS2 in the launch file manually.

Making collisions by "Box from bounding box" (sphere, cylinder):

  1. Select link or links and press "Box from bounding box" (sphere, cylinder) tool. Collisions created.

Tip: you can enable or disable display of generated collisions in FreeCAD by changing "Show Collisions" option in Robot element.

If you clear Collision property of Link and want to see what collision link also deleted turn off/on "Show Collisions" of Robot. It will delete collision links. This toggle also way to recreate collision links if you have binded new collision objects.

Auto calculation mass and inertia

  1. Choose material of whole robot or individual link by tool - "Set material to whole robot or link".
  2. Press tool - "Calculate mass and inertia".

It is all you need to do for calculating mass and inertia.

Tip:: Setted inertia can be very small and you will not see it in link properties (because of limit on the number of decimal places), but you must see mass after successed inertia calculation. Also command will throw red messages if something wend wrong.

Tutorials (russian language, use translator):

Robocar step by step (a lot of screenshots)

STEP file to robot in simulation - video

Custom multicopter model to simulation, PX4 + ROS2 + Gazebo

Install to Ubuntu

Install to Windows via WSL

Other tutorials

Core principles:

Core principles inherited from CROSS