File size: 16,561 Bytes
602054e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
<mujoco model="ft2_test_fixture">
  <!-- Bench test fixture FT-2: SO-101 loads a board under test (DC barrel jack and a keyed 2-pin header), runs the
       test, unloads. World frame = robot base frame. Bench top at z = 0. -->
  <compiler angle="radian" autolimits="true"/>
  <option integrator="implicitfast" timestep="0.002" cone="elliptic" iterations="20" ls_iterations="20"
          impratio="10" noslip_iterations="0"/>
  <size memory="40M"/>
  <asset>
    <model name="so101" file="robot/so101.xml"/>
    <texture name="grid" type="2d" builtin="checker" rgb1="0.80 0.80 0.78" rgb2="0.76 0.76 0.74" width="64" height="64"/>
    <material name="bench" texture="grid" texrepeat="12 12"/>
  </asset>
  <visual>
    <global azimuth="160" elevation="-35" offwidth="640" offheight="480"/>
    <quality shadowsize="0"/>
    <headlight ambient="0.25 0.25 0.25" diffuse="0.15 0.15 0.15" specular="0 0 0"/>
    <map znear="0.01"/>
  </visual>
  <default>
    <default class="fit">
      <geom condim="3" friction="0.25 0.005 0.0001" solref="0.004 1" solimp="0.95 0.99 0.0005" margin="0"/>
    </default>
    <default class="part">
      <geom condim="4" friction="0.6 0.005 0.0001" solref="0.004 1" solimp="0.95 0.99 0.0005"/>
    </default>
    <default class="deco">
      <geom contype="0" conaffinity="0" group="1"/>
    </default>
  </default>
  <worldbody>
    <light pos="0.2 0.1 1.2" dir="0 0 -1" directional="true" diffuse="0.45 0.45 0.45" specular="0.05 0.05 0.05"/>
    <light pos="-0.3 -0.4 0.8" dir="0.4 0.4 -0.6" directional="true" diffuse="0.15 0.15 0.15" specular="0 0 0"/>
    <geom name="floor" type="plane" size="1 1 0.05" pos="0 0 -0.75" rgba="0.3 0.3 0.32 1"/>
    <geom name="bench" type="box" size="0.32 0.32 0.02" pos="0.14 0 -0.02" material="bench" friction="0.7 0.005 0.0001"/>
    <frame name="mount" pos="0 0 0">
      <attach model="so101" body="base" prefix="robot/"/>
    </frame>
    <camera name="overhead" pos="0.22 0 0.62" xyaxes="0 -1 0 1 0 0" fovy="40"/>

    <!-- Cable rest pads (rubber mats) and harness clamps -->
    <geom name="dc_pad" class="deco" type="box" size="0.045 0.035 0.0003" pos="0.205 0.13 0.0003" rgba="0.45 0.47 0.50 1"/>
    <site name="dc_anchor" pos="0.22 0.25 0.02" size="0.004" rgba="0.2 0.2 0.2 1"/>
    <site name="hdr_anchor" pos="0.22 -0.25 0.02" size="0.004" rgba="0.2 0.2 0.2 1"/>
    <geom name="duct" class="deco" type="box" size="0.02 0.24 0.012" pos="0.33 0 0.012" rgba="0.10 0.10 0.12 1"/>
    <!-- touch-off probes: spring plungers with a switch, fixed to the bench plate -->
    <body name="probe_0_base" pos="0.105 0.065 0">
      <geom name="probe_0_housing" type="cylinder" size="0.007 0.00575" pos="0 0 0.00575" rgba="0.20 0.20 0.22 1"/>
      <body name="probe_0" pos="0 0 0.016">
        <joint name="probe_0" type="slide" axis="0 0 1" range="-0.004 0" stiffness="150.0"
               springref="0.00333333" damping="1" armature="0.002" solreflimit="0.002 1"/>
        <geom name="probe_0_cap" type="cylinder" size="0.004 0.0025" pos="0 0 0.0025" mass="0.003" rgba="0.85 0.45 0.10 1"/>
      </body>
    </body>
    <body name="probe_1_base" pos="0.115 -0.03 0">
      <geom name="probe_1_housing" type="cylinder" size="0.007 0.00575" pos="0 0 0.00575" rgba="0.20 0.20 0.22 1"/>
      <body name="probe_1" pos="0 0 0.016">
        <joint name="probe_1" type="slide" axis="0 0 1" range="-0.004 0" stiffness="150.0"
               springref="0.00333333" damping="1" armature="0.002" solreflimit="0.002 1"/>
        <geom name="probe_1_cap" type="cylinder" size="0.004 0.0025" pos="0 0 0.0025" mass="0.003" rgba="0.85 0.45 0.10 1"/>
      </body>
    </body>
    <body name="probe_2_base" pos="0.27 -0.1 0">
      <geom name="probe_2_housing" type="cylinder" size="0.007 0.00575" pos="0 0 0.00575" rgba="0.20 0.20 0.22 1"/>
      <body name="probe_2" pos="0 0 0.016">
        <joint name="probe_2" type="slide" axis="0 0 1" range="-0.004 0" stiffness="150.0"
               springref="0.00333333" damping="1" armature="0.002" solreflimit="0.002 1"/>
        <geom name="probe_2_cap" type="cylinder" size="0.004 0.0025" pos="0 0 0.0025" mass="0.003" rgba="0.85 0.45 0.10 1"/>
      </body>
    </body>
    <!-- overhead-camera registration targets on the duct cover -->
    <geom name="target_0" class="deco" type="cylinder" size="0.006 0.0002" pos="0.33 -0.16 0.0242" rgba="0.95 0.95 0.95 1"/>
    <geom name="target_1" class="deco" type="cylinder" size="0.006 0.0002" pos="0.33 0 0.0242" rgba="0.95 0.95 0.95 1"/>
    <geom name="target_2" class="deco" type="cylinder" size="0.006 0.0002" pos="0.33 0.16 0.0242" rgba="0.95 0.95 0.95 1"/>
    <geom name="dc_tie" class="deco" type="box" size="0.008 0.006 0.01" pos="0.22 0.254 0.01" rgba="0.10 0.10 0.12 1"/>
    <geom name="hdr_tie" class="deco" type="box" size="0.008 0.006 0.01" pos="0.22 -0.254 0.01" rgba="0.10 0.10 0.12 1"/>

    <!-- Parking socket for the header plug (pose set per cycle), latch side toward socket +y -->
    <body name="holder" pos="0.165 -0.115 0">
      <geom name="holder_floor" type="box" pos="0 0 0.001" size="0.013 0.011 0.001" rgba="0.16 0.30 0.62 1"/>
      <geom name="holder_wall_mx" type="box" pos="-0.009075 0 0.005" size="0.003925 0.011 0.003" rgba="0.16 0.30 0.62 1"/>
      <geom name="holder_wall_px" type="box" pos="0.009075 0 0.005" size="0.003925 0.011 0.003" rgba="0.16 0.30 0.62 1"/>
      <geom name="holder_wall_my" type="box" pos="0 -0.007325 0.005" size="0.00515 0.003675 0.003" rgba="0.16 0.30 0.62 1"/>
      <geom name="holder_wall_py" type="box" pos="0 0.007775 0.005" size="0.00515 0.003225 0.003" rgba="0.16 0.30 0.62 1"/>
    </body>

    <!-- Test fixture nest (pose set per cycle), board under test on two locating pins (vertical slide) -->
    <body name="nest" pos="0.215 0 0">
      <geom name="nest_plate" type="box" size="0.065 0.04 0.006" pos="0 0 0.006" rgba="0.30 0.34 0.42 1"/>
      <geom name="pin_a" class="deco" type="cylinder" size="0.0015 0.004" pos="-0.028 -0.034 0.0136" rgba="0.75 0.75 0.75 1"/>
      <geom name="pin_b" class="deco" type="cylinder" size="0.0015 0.004" pos="0.028 0.034 0.0136" rgba="0.75 0.75 0.75 1"/>
      <!-- test button box on the front strip -->
      <body name="button_box" pos="-0.05 0.02 0.012">
        <geom name="button_housing" type="box" size="0.011 0.011 0.007" pos="0 0 0.007" rgba="0.12 0.12 0.13 1"/>
        <geom name="lamp_pass" class="deco" type="cylinder" size="0.0025 0.0006" pos="0.006 -0.0085 0.0142" rgba="0.05 0.25 0.05 1"/>
        <geom name="lamp_fail" class="deco" type="cylinder" size="0.0025 0.0006" pos="0.006 0.0085 0.0142" rgba="0.25 0.05 0.05 1"/>
        <body name="button" pos="0 0 0.014">
          <joint name="button" type="slide" axis="0 0 1" range="-0.003 0" stiffness="300.0"
                 springref="0.00833333" damping="2" armature="0.005" solreflimit="0.002 1"/>
          <geom name="button_cap" type="cylinder" size="0.006 0.0025" pos="0 0 0.0025" mass="0.004"
                rgba="0.10 0.65 0.25 1" condim="4" friction="0.8 0.005 0.0001"/>
        </body>
      </body>
      <body name="board" pos="0 0 0.012">
        <joint name="board_lift" type="slide" axis="0 0 1" range="0 0.02" damping="0.5" frictionloss="0.05" solreflimit="0.002 1"/>
        <geom name="board" type="box" size="0.035 0.045 0.0008" pos="0 0 0.0008" mass="0.07" rgba="0.10 0.42 0.20 1"/>
        <geom name="chip_u1" class="deco" type="box" size="0.008 0.008 0.0012" pos="-0.012 0.006 0.0028" rgba="0.08 0.08 0.09 1"/>
        <geom name="chip_u2" class="deco" type="box" size="0.004 0.006 0.001" pos="0.018 0.010 0.0026" rgba="0.08 0.08 0.09 1"/>
        <geom name="cap_c1" class="deco" type="cylinder" size="0.003 0.004" pos="0.020 -0.004 0.0056" rgba="0.15 0.25 0.6 1"/>
        <!-- DC barrel jack: frame at the bore mouth, local +x = outward along the bore -->
        <body name="dc_jack" pos="0 0.047 0.0071" quat="0.707107 0 0 0.707107">
          <geom name="dc_housing_vis" class="deco" type="box" size="0.007 0.0045 0.0055" pos="-0.007 0 0" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore0" class="fit" type="box" pos="-0.00615 0.00327977 0.00135853" quat="0.980785 0.19509 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead0" class="fit" type="box" pos="-0.000753553 0.00351403 0.00145556" quat="0.906127 0.18024 -0.0746578 0.37533" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore1" class="fit" type="box" pos="-0.00615 0.00135853 0.00327977" quat="0.83147 0.55557 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead1" class="fit" type="box" pos="-0.000753553 0.00145556 0.00351403" quat="0.768178 0.51328 -0.212608 0.31819" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore2" class="fit" type="box" pos="-0.00615 -0.00135853 0.00327977" quat="0.55557 0.83147 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead2" class="fit" type="box" pos="-0.000753553 -0.00145556 0.00351403" quat="0.51328 0.768178 -0.31819 0.212608" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore3" class="fit" type="box" pos="-0.00615 -0.00327977 0.00135853" quat="0.19509 0.980785 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead3" class="fit" type="box" pos="-0.000753553 -0.00351403 0.00145556" quat="0.18024 0.906127 -0.37533 0.0746578" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore4" class="fit" type="box" pos="-0.00615 -0.00327977 -0.00135853" quat="-0.19509 0.980785 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead4" class="fit" type="box" pos="-0.000753553 -0.00351403 -0.00145556" quat="-0.18024 0.906127 -0.37533 -0.0746578" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore5" class="fit" type="box" pos="-0.00615 -0.00135853 -0.00327977" quat="0.55557 -0.83147 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead5" class="fit" type="box" pos="-0.000753553 -0.00145556 -0.00351403" quat="0.51328 -0.768178 0.31819 0.212608" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore6" class="fit" type="box" pos="-0.00615 0.00135853 -0.00327977" quat="0.83147 -0.55557 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead6" class="fit" type="box" pos="-0.000753553 0.00145556 -0.00351403" quat="0.768178 -0.51328 0.212608 0.31819" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_bore7" class="fit" type="box" pos="-0.00615 0.00327977 -0.00135853" quat="0.980785 -0.19509 0 0" size="0.00535 0.0005 0.00187756" rgba="0.08 0.08 0.08 1"/>
          <geom name="dc_lead7" class="fit" type="box" pos="-0.000753553 0.00351403 -0.00145556" quat="0.906127 -0.18024 0.0746578 0.37533" size="0.0006 0.0005 0.00267756" rgba="0.08 0.08 0.08 1"/>
          <body name="dc_contact" pos="-0.008 0 0">
            <joint name="dc_contact" type="slide" axis="1 0 0" range="-0.003 0" stiffness="500.0"
                   springref="0.004" damping="3" armature="0.002" solreflimit="0.002 1"/>
            <geom name="dc_contact" class="fit" type="box" size="0.0005 0.0024 0.0024" mass="0.002" rgba="0.75 0.7 0.4 1"/>
          </body>
        </body>
        <!-- keyed 2-pin header shroud: frame on the board top, long axis along board x, key slot in the +y wall -->
        <body name="hdr_shroud" pos="0.006 -0.02 0.0016">
          <geom name="hdr_wall_my" class="fit" type="box" pos="0 -0.0043 0.0035" quat="0 1 0 0" size="0.0063 0.0005 0.0035" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_my_lead" class="fit" type="box" pos="0 -0.00465355 0.00714645" quat="0.382683 0.92388 0 0" size="0.0063 0.00075 0.0005" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_px" class="fit" type="box" pos="0.0058 0 0.0035" quat="0 0.707107 0.707107 0" size="0.0038 0.0005 0.0035" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_px_lead" class="fit" type="box" pos="0.00615355 0 0.00714645" quat="0.270598 0.653281 0.653281 0.270598" size="0.0038 0.00075 0.0005" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_mx" class="fit" type="box" pos="-0.0058 0 0.0035" quat="0.707107 0 0 0.707107" size="0.0038 0.0005 0.0035" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_mx_lead" class="fit" type="box" pos="-0.00615355 0 0.00714645" quat="0.653281 0.270598 0.270598 0.653281" size="0.0038 0.00075 0.0005" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_py_r" class="fit" type="box" pos="0.004 0.0043 0.0035" quat="1 0 0 0" size="0.0023 0.0005 0.0035" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_py_r_lead" class="fit" type="box" pos="0.004 0.00465355 0.00714645" quat="0.92388 0.382683 0 0" size="0.0023 0.00075 0.0005" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_py_l" class="fit" type="box" pos="-0.004 0.0043 0.0035" quat="1 0 0 0" size="0.0023 0.0005 0.0035" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_wall_py_l_lead" class="fit" type="box" pos="-0.004 0.00465355 0.00714645" quat="0.92388 0.382683 0 0" size="0.0023 0.00075 0.0005" rgba="0.93 0.91 0.84 1"/>
          <geom name="hdr_floor_vis" class="deco" type="box" size="0.0055 0.004 0.0002" pos="0 0 0.0002" rgba="0.85 0.83 0.76 1"/>
          <body name="hdr_contact" pos="0 0 0.003">
            <joint name="hdr_contact" type="slide" axis="0 0 1" range="-0.003 0" stiffness="250.0"
                   springref="0.0048" damping="3" armature="0.002" solreflimit="0.002 1"/>
            <geom name="hdr_contact" class="fit" type="box" size="0.0040 0.0026 0.0005" mass="0.002" rgba="0.75 0.7 0.4 1"/>
          </body>
        </body>
      </body>
    </body>

    <!-- DC plug: frame at the housing centre, local +x = barrel direction -->
    <body name="dc_plug" pos="0.205 0.13 0.0045" quat="0.707107 -0 -0 -0.707107">
      <freejoint name="dc_plug"/>
      <geom name="dc_body" class="part" type="box" size="0.012 0.0045 0.0045" mass="0.012" rgba="0.13 0.13 0.14 1"/>
      <geom name="dc_band" class="deco" type="box" size="0.002 0.00455 0.00455" pos="0.006 0 0" rgba="0.85 0.75 0.15 1"/>
      <geom name="dc_barrel" class="fit" type="capsule" fromto="0.0145 0 0 0.01975 0 0" size="0.00275" mass="0.002" rgba="0.78 0.78 0.80 1"/>
      <geom name="dc_relief" class="part" type="capsule" fromto="-0.012 0 0 -0.019 0 0" size="0.0025" mass="0.001" rgba="0.13 0.13 0.14 1"/>
      <site name="dc_tip" pos="0.0225 0 0" size="0.0008"/>
      <site name="dc_cable" pos="-0.021 0 0" size="0.0008"/>
    </body>

    <!-- Header plug: frame at the bottom centre, key rib and latch on the +y face -->
    <body name="hdr_plug" pos="0.165 -0.115 0.002">
      <freejoint name="hdr_plug"/>
      <geom name="hdr_body" class="fit" type="box" size="0.005 0.0035 0.010" pos="0 0 0.010" mass="0.006" rgba="0.93 0.90 0.80 1"/>
      <geom name="hdr_rib" class="fit" type="box" size="0.0012 0.00045 0.00325" pos="0 0.00395 0.00375" mass="0.0001" rgba="0.93 0.90 0.80 1"/>
      <geom name="hdr_mark" class="deco" type="box" size="0.0050 0.00175 0.0002" pos="0 0.00175 0.0201" rgba="0.85 0.12 0.10 1"/>
      
      <site name="hdr_cable" pos="0 0 0.021" size="0.0008"/>
      <body name="hdr_latch" pos="0 0.0035 0.011">
        <joint name="hdr_latch" type="hinge" axis="-1 0 0" range="0 0.2" stiffness="0.04"
               springref="0.15" damping="0.002" armature="1e-4" solreflimit="0.004 1"/>
        <geom name="hdr_tab" class="fit" type="box" size="0.002 0.0004 0.004" pos="0 0.0004 0.004" mass="0.0005" rgba="0.93 0.90 0.80 1"/>
      </body>
    </body>
  </worldbody>

  <contact>
    <exclude body1="nest" body2="board"/>
    <exclude body1="hdr_plug" body2="hdr_latch"/>
  </contact>

  <tendon>
    <spatial name="dc_cable" stiffness="20.0" springlength="0 0.15" damping="0.2" width="0.0012" rgba="0.45 0.45 0.47 1">
      <site site="dc_anchor"/><site site="dc_cable"/>
    </spatial>
    <spatial name="hdr_cable" stiffness="20.0" springlength="0 0.27" damping="0.2" width="0.0012" rgba="0.30 0.30 0.32 1">
      <site site="hdr_anchor"/><site site="hdr_cable"/>
    </spatial>
  </tendon>

  <equality>
    <weld name="dc_lock" body1="dc_jack" body2="dc_plug" active="false" solref="0.004 1"/>
    <weld name="hdr_lock" body1="hdr_shroud" body2="hdr_plug" active="false" solref="0.004 1"/>
  </equality>
</mujoco>