Simple Arm - 4-DOF serial manipulator¶
Kinematic chain¶
base_link (box)
└─ base_shoulder_joint [revolute Z]
shoulder_link (cylinder)
└─ shoulder_upper_arm_joint [revolute Y]
upper_arm_link (cylinder)
└─ upper_arm_forearm_joint [revolute Y]
forearm_link (cylinder)
└─ forearm_ee_joint [fixed]
end_effector_link (sphere)
What this example demonstrates¶
Origin.above(geometry)- lifts each link so its bottom face sits at z = 0, avoiding manual offset arithmeticInertial.from_geometry()- auto-dispatches to the correct inertia formula (box, cylinder, or sphere) from the geometry object aloneJointLimitandJointDynamicson every revolute jointrobot.save()writing both.urdfand.xacroby inferring the format from the file extension
Running the example¶
python3 examples/simple_arm.py
Output files are written to examples/simple_arm/:
File |
Description |
|---|---|
|
URDF robot description |
|
Xacro equivalent |
|
Plain-text kinematic tree |
Quick visualisation: copy
simple_arm.urdfinto the online URDF viewer for instant validation and 3D preview without any local ROS install.