[software] 添加16DOF早期训练仿真与Sim2Real闭环

This commit is contained in:
2026-07-21 16:15:14 +08:00
parent 9bd22225f9
commit e9e2c946b3
681 changed files with 137221 additions and 8 deletions
@@ -0,0 +1,19 @@
<mujoco>
<worldbody>
<body name="ground" pos="0 0 0">
<geom name="ground_geom" type="plane" size="5 5 0.1" rgba="0.5 0.5 0.5 1"/>
</body>
<body name="base" pos="0 0 0.5">
<freejoint name="base_joint"/>
<geom name="torso_geom" type="box" size="0.15 0.1 0.2" mass="5.0"/>
<body name="left_foot" pos="0.1 0 -0.25">
<joint name="left_ankle" type="hinge" axis="0 1 0" range="-0.5 0.5"/>
<geom name="left_foot_geom" type="box" size="0.05 0.08 0.02" mass="0.2"/>
</body>
<body name="right_foot" pos="-0.1 0 -0.25">
<joint name="right_ankle" type="hinge" axis="0 1 0" range="-0.5 0.5"/>
<geom name="right_foot_geom" type="box" size="0.05 0.08 0.02" mass="0.2"/>
</body>
</body>
</worldbody>
</mujoco>
@@ -0,0 +1,15 @@
<mujoco>
<worldbody>
<body name="base" pos="0 0 0.5">
<geom name="base_geom" type="cylinder" size="0.1 0.05" mass="5.0"/>
<body name="link1" pos="0 0 0.1">
<joint name="joint1" type="hinge" axis="0 0 1" range="-3.14 3.14"/>
<geom name="link1_geom" type="box" size="0.05 0.05 0.2" mass="1.0"/>
<body name="link2" pos="0 0 0.4">
<joint name="joint2" type="hinge" axis="0 1 0" range="-1.57 1.57"/>
<geom name="link2_geom" type="box" size="0.05 0.05 0.15" mass="0.5"/>
</body>
</body>
</body>
</worldbody>
</mujoco>
@@ -0,0 +1,7 @@
<mujoco>
<worldbody>
<body name="object" pos="0 0 0.5">
<geom name="object_geom" type="box" size="0.1 0.1 0.1" rgba="0.8 0.3 0.3 1"/>
</body>
</worldbody>
</mujoco>
@@ -0,0 +1,20 @@
<mujoco>
<worldbody>
<body name="base" pos="0 0 1">
<freejoint name="free_joint"/>
<geom name="base_geom" type="box" size="0.2 0.2 0.1" mass="1.0"/>
<body name="link1" pos="0 0 0">
<joint name="joint1" type="hinge" axis="0 0 1" range="-1.57 1.57"/>
<geom name="link1_geom" type="box" size="0.1 0.1 0.1" mass="0.1"/>
<site name="site1" pos="0 0 0"/>
</body>
<body name="link2" pos="0 0 0">
<joint name="joint2" type="hinge" axis="0 0 1" range="-1.57 1.57"/>
<geom name="link2_geom" type="box" size="0.1 0.1 0.1" mass="0.1"/>
</body>
</body>
</worldbody>
<sensor>
<jointpos name="joint1_pos" joint="joint1"/>
</sensor>
</mujoco>
@@ -0,0 +1,8 @@
<mujoco>
<worldbody>
<body name="object" pos="0 0 1">
<freejoint name="free_joint"/>
<geom name="object_geom" type="box" size="0.1 0.1 0.1" rgba="0.3 0.3 0.8 1" mass="0.1"/>
</body>
</worldbody>
</mujoco>
@@ -0,0 +1,43 @@
<mujoco model="quadcopter">
<compiler angle="radian" autolimits="true"/>
<option timestep="0.002" integrator="implicitfast" gravity="0 0 -9.81"/>
<default>
<geom rgba="0.5 0.5 0.5 1"/>
<site size="0.01" rgba="1 0 0 1"/>
</default>
<worldbody>
<light pos="0 0 3" dir="0 0 -1" diffuse="0.8 0.8 0.8"/>
<geom type="plane" size="5 5 0.1" rgba="0.9 0.9 0.9 1"/>
<body name="base" pos="0 0 0.5">
<freejoint name="root"/>
<inertial pos="0 0 0" mass="1.0" diaginertia="0.01 0.01 0.02"/>
<!-- Central body -->
<geom type="box" size="0.1 0.1 0.02" rgba="0.3 0.3 0.8 1"/>
<!-- Rotor sites at corners -->
<site name="rotor_fl" pos="0.1 0.1 0"/>
<site name="rotor_fr" pos="0.1 -0.1 0"/>
<site name="rotor_rl" pos="-0.1 0.1 0"/>
<site name="rotor_rr" pos="-0.1 -0.1 0"/>
<!-- Visual rotor geoms (non-collision) -->
<geom name="rotor_fl_vis" type="cylinder" size="0.05 0.005" pos="0.1 0.1 0" rgba="1 0 0 0.5" contype="0" conaffinity="0"/>
<geom name="rotor_fr_vis" type="cylinder" size="0.05 0.005" pos="0.1 -0.1 0" rgba="1 0 0 0.5" contype="0" conaffinity="0"/>
<geom name="rotor_rl_vis" type="cylinder" size="0.05 0.005" pos="-0.1 0.1 0" rgba="1 0 0 0.5" contype="0" conaffinity="0"/>
<geom name="rotor_rr_vis" type="cylinder" size="0.05 0.005" pos="-0.1 -0.1 0" rgba="1 0 0 0.5" contype="0" conaffinity="0"/>
</body>
</worldbody>
<actuator>
<!-- Site actuators applying vertical thrust forces -->
<motor name="thrust_fl" site="rotor_fl" gear="0 0 1 0 0 0" ctrlrange="0 20"/>
<motor name="thrust_fr" site="rotor_fr" gear="0 0 1 0 0 0" ctrlrange="0 20"/>
<motor name="thrust_rl" site="rotor_rl" gear="0 0 1 0 0 0" ctrlrange="0 20"/>
<motor name="thrust_rr" site="rotor_rr" gear="0 0 1 0 0 0" ctrlrange="0 20"/>
</actuator>
</mujoco>
@@ -0,0 +1,45 @@
<mujoco model="tendon_finger">
<compiler angle="radian" autolimits="true"/>
<option timestep="0.002" integrator="implicitfast"/>
<default>
<geom type="capsule" size="0.01" rgba="0.8 0.6 0.4 1"/>
<joint type="hinge" axis="0 1 0" range="-1.57 1.57" damping="0.1"/>
<site size="0.005" rgba="1 0 0 1"/>
</default>
<worldbody>
<light pos="0 0 1" dir="0 0 -1" diffuse="0.8 0.8 0.8"/>
<geom type="plane" size="1 1 0.1" rgba="0.9 0.9 0.9 1"/>
<body name="proximal_link" pos="0 0 0.5">
<joint name="proximal_joint"/>
<geom fromto="0 0 0 0 0 0.15" size="0.015"/>
<site name="tendon_p1" pos="0 0.02 0.05"/>
<site name="tendon_p2" pos="0 0.02 0.15"/>
<body name="distal_link" pos="0 0 0.15">
<joint name="distal_joint"/>
<geom fromto="0 0 0 0 0 0.15" size="0.012"/>
<site name="tendon_p3" pos="0 0.02 0.05"/>
<site name="fingertip" pos="0 0 0.15"/>
</body>
</body>
</worldbody>
<tendon>
<spatial name="finger_tendon" width="0.003" rgba="0.2 0.2 0.8 1">
<site site="tendon_p1"/>
<site site="tendon_p2"/>
<site site="tendon_p3"/>
</spatial>
</tendon>
<actuator>
<!-- Tendon actuators for testing different control modes -->
<position name="tendon_position" tendon="finger_tendon" kp="100" ctrlrange="-0.1 0.1"/>
<velocity name="tendon_velocity" tendon="finger_tendon" kv="10" ctrlrange="-1 1"/>
<motor name="tendon_effort" tendon="finger_tendon" ctrlrange="-10 10"/>
</actuator>
</mujoco>