Ball joint in URDF
Hello, guys
I'd like to know how do I create a 3D ball joint using URDF.
I've tried some approaches like trying to create a dummy link, but I had no success.
In my project I have a quadrotor and a ball, I'd like to fix them, so the quad could roll, pitch and yaw on a fixed spot.
Any thoughts about that?
EDIT
I'll give more explanation about my problem.
In my project I want to develop a system for drones to share payload, and I want to avoid the problem of collision keeping them fixed in distance. To achieve that, I had the idea of using a bar, where they would be able to move freely. The image above ilustrates the ideia with one quad.
The problem that I'm facing right now is with the spherical joint between the quad and the ball. I managed to achieve 1 DoF at the moment. I'll copy here the 3 files that I'm using to make it work.
The bar model:
<?xml version="1.0"?>
<robot xmlns:xacro="http://www.ros.org/wiki/xacro">
<xacro:property name="M_PI" value="3.1415926535897931"/>
<xacro:macro name="barra_model" params="name parent *origin">
<joint name="${name}_joint" type="fixed">
<xacro:insert_block name="origin" />
<parent link="${parent}"/>
<child link="barra_baselink"/>
</joint>
<link name="barra_baselink">
<visual>
<geometry>
<sphere radius="0.025"/>
</geometry>
<origin rpy="0 0 0" xyz="0.9875 0 0.1125"/>
<material name="white">
<color rgba="1 1 1 1"/>
</material>
</visual>
<inertial>
<mass value="0.025" />
<origin xyz="0.9875 0 0.1125" rpy="0 0 0" />
<inertia ixx="5.8083e-4" ixy="0" ixz="0" iyy="3.0833e-5" iyz="0" izz="5.9083e-4" />
</inertial>
<collision>
<geometry>
<sphere radius="0.025"/>
</geometry>
<origin rpy="0 0 0" xyz="0.9875 0 0.1125"/>
</collision>
</link>
<joint name="${name}_b2ebase_link" type="fixed">
<parent link="barra_baselink"/>
<child link="${name}_b2"/>
</joint>
<link name="${name}_b2">
<visual>
<geometry>
<box size="0.025 0.025 0.10"/>
</geometry>
<origin rpy="0 0 0" xyz="0.9875 0 0.075"/>
</visual>
<inertial>
<mass value="0.050" />
<origin xyz="0.9875 0 0.075" rpy="0 0 0" />
<inertia ixx="5.8083e-4" ixy="0" ixz="0" iyy="3.0833e-5" iyz="0" izz="5.9083e-4" />
</inertial>
<collision>
<geometry>
<box size="0.05 0.05 0.20"/>
</geometry>
<origin rpy="0 0 0" xyz="0.9875 0 0.075"/>
</collision>
</link>
<joint name="${name}_b1eb2" type="fixed">
<parent link="${name}_b2"/>
<child link="${name}_bhor"/>
</joint>
<link name="${name}_bhor">
<visual>
<geometry>
<box size="2.0 0.025 0.025"/>
</geometry>
<origin rpy="0 0 0" xyz="0 0 0.0125"/>
</visual>
<inertial>
<mass value="0.253" />
<origin xyz="0 0 0" rpy="0 0 0.0125" />
<inertia ixx="5.8083e-4" ixy="0" ixz="0" iyy="3.0833e-5" iyz="0" izz="5.9083e-4" />
</inertial>
<collision>
<geometry>
<box size="2.0 0.025 0.025"/>
</geometry>
<origin rpy="0 0 0" xyz="0 ...