~csiro-asl/csiro-asl-ros-drivers/trunk

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
<!-- test_skid_steer.env.xml 
    A skid-steer car model, loaded into an environment with the custom_ode_physics plugin  -->
<Environment>
    <Robot name="chassis_and_wheels">
        <KinBody name="car">
            <Body name="chassis" type="dynamic">
                <mass type="box">
                    <total>2</total>
                </mass>
                <Geom type="box">
                    <Extents>1.0 0.3 0.2</Extents>
                </Geom>
            </Body>
            <Body name="front_left_wheel" type="dynamic">
                <mass>
                    <total>0.3</total>
                </mass>
                <offsetfrom>chassis</offsetfrom>
                <Translation> 0.515 0.65 -0.25 </Translation>
                <Geom type="cylinder">
                      <radius>0.375</radius>
                      <height>0.24</height>
                      <diffuseColor>0.05 0.05 0.05</diffuseColor>
                </Geom>
            </Body>
            <Body name="rear_left_wheel" type="dynamic">
                <mass>
                    <total>0.3</total>
                </mass>
                <offsetfrom>chassis</offsetfrom>
                <Translation> -0.515 0.65 -0.25 </Translation>
                <Geom type="cylinder">
                      <radius>0.375</radius>
                      <height>0.24</height>
                      <diffuseColor>0.05 0.05 0.05</diffuseColor>
                </Geom>
            </Body>
            <Body name="front_right_wheel" type="dynamic">
                <mass>
                    <total>0.3</total>
                </mass>
                <offsetfrom>chassis</offsetfrom>
                <Translation> 0.515 -0.65 -0.25 </Translation>
                <Geom type="cylinder">
                      <radius>0.375</radius>
                      <height>0.24</height>
                      <diffuseColor>0.05 0.05 0.05</diffuseColor>
                </Geom>
            </Body>
            <Body name="rear_right_wheel" type="dynamic">
                <mass>
                    <total>0.3</total>
                </mass>
                <offsetfrom>chassis</offsetfrom>
                <Translation> -0.515 -0.65 -0.25 </Translation>
                <Geom type="cylinder">
                      <radius>0.375</radius>
                      <height>0.24</height>
                      <diffuseColor>0.05 0.05 0.05</diffuseColor>
                </Geom>
            </Body>
            <Body name="steer_hub_left" type="dynamic">
                <mass type="box">
                    <total>0.1</total>
                </mass>
                <offsetfrom>chassis</offsetfrom>
                <Translation> 0.515 0.4 -0.25 </Translation>
                <Geom type="box">
                    <Extents>0.01 0.01 0.01</Extents>
                </Geom>
            </Body>
            <Body name="steer_hub_right" type="dynamic">
                <mass type="box">
                    <total>0.1</total>
                </mass>
                <offsetfrom>chassis</offsetfrom>
                <Translation> 0.515 -0.4 -0.25 </Translation>
                <Geom type="box">
                    <Extents>0.01 0.01 0.01</Extents>
                </Geom>
            </Body>
            <!--<Joint name="joint_flwheel_chassis" type="hinge2" circular="true">
                <Body>chassis</Body>
                <Body>front_left_wheel</Body>
                <offsetfrom>chassis</offsetfrom>
                <Anchor> 0.515 0.4 -0.25</Anchor>
                <axis1> 0 0 1 </axis1>
                <axis2> 0 1 0 </axis2>
            </Joint>
            <Joint name="joint_frwheel_chassis" type="hinge2" circular="true">
                <Body>chassis</Body>
                <Body>front_right_wheel</Body>
                <offsetfrom>chassis</offsetfrom>
                <Anchor> 0.515 -0.4 -0.25</Anchor>
                <axis1> 0 0 1 </axis1>
                <axis2> 0 1 0 </axis2>
            </Joint>-->
            <Joint name="joint_flwheel_chassis0" type="hinge" circular="true">
                <Body>steer_hub_left</Body>
                <Body>chassis</Body>
                <offsetfrom>chassis</offsetfrom>
                <Anchor> 0.515 0.4 -0.25</Anchor>
                <axis> 0 0 1 </axis>
            </Joint>
            <Joint name="joint_flwheel_chassis1" type="hinge" circular="true">
                <Body>steer_hub_left</Body>
                <Body>front_left_wheel</Body>
                <offsetfrom>chassis</offsetfrom>
                <Anchor> 0.515 0.4 -0.25</Anchor>
                <axis> 0 1 0 </axis>
            </Joint>
            <Joint name="joint_frwheel_chassis0" type="hinge" circular="true">
                <Body>steer_hub_right</Body>
                <Body>chassis</Body>
                <offsetfrom>chassis</offsetfrom>
                <Anchor> 0.515 -0.4 -0.25</Anchor>
                <axis> 0 0 1 </axis>
            </Joint>
            <Joint name="joint_frwheel_chassis1" type="hinge" circular="true">
                <Body>steer_hub_right</Body>
                <Body>front_right_wheel</Body>
                <offsetfrom>chassis</offsetfrom>
                <Anchor> 0.515 -0.4 -0.25</Anchor>
                <axis> 0 1 0 </axis>
            </Joint>
            <Joint name="joint_rlwheel_chassis" type="hinge" circular="true">
                <Body>chassis</Body>
                <Body>rear_left_wheel</Body>
                <offsetfrom>rear_left_wheel</offsetfrom>
                <Anchor> 0 0 0</Anchor>
                <axis> 0 1 0 </axis>
            </Joint>
            <Joint name="joint_rrwheel_chassis" type="hinge" circular="true">
                <Body>chassis</Body>
                <Body>rear_right_wheel</Body>
                <offsetfrom>rear_right_wheel</offsetfrom>
                <Anchor> 0 0 0</Anchor>
                <axis> 0 1 0 </axis>
            </Joint>
            
        </KinBody>
        <Translation> 0 0 0</Translation>
    </Robot>
    <KinBody name="terrain_kin">
        <Body name="terrain" type="static">
            <Geom type="box">
                <Extents>500 500 0.1</Extents>
            </Geom>
        </Body>
        <Translation> 0 0 -1.0</Translation>
        <!-- lets make the car roll a little -->
        <RotationAxis>1 0 0 0</RotationAxis>
    </KinBody>
    <physicsengine type="csiro_ode">
        <csiro_odeproperties>
            <contact body0="terrain" body1="front_left_wheel">
                <friction>0.6</friction>
                <model>Approx1 SoftCFM SoftERP</model>
                <cfm>0.0001</cfm>
                <erp>0.95</erp>
            </contact>
            <contact body0="terrain" body1="front_right_wheel">
                <friction>0.6</friction>
                <model>Approx1 SoftCFM SoftERP</model>
                <cfm>0.0001</cfm>
                <erp>0.95</erp>
            </contact>
            <contact body0="terrain" body1="rear_right_wheel">
                <friction>0.6</friction>
                <model>Approx1 SoftCFM SoftERP</model>
                <cfm>0.0001</cfm>
                <erp>0.95</erp>
            </contact>
            <contact> 
                <friction>0.5</friction>
                <model>SoftCFM SoftERP</model>
                <cfm>0.000000001</cfm>
                <erp>0.999999</erp>
            </contact>
            <contact body0="terrain" body1="rear_left_wheel">
                <friction>0.6</friction>
                <model>Approx1 SoftCFM SoftERP</model>
                <cfm>0.0001</cfm>
                <erp>0.95</erp>
            </contact>
            <gravity>0 0 -9.81</gravity>
            <SelfCollision>true</SelfCollision>
            <autodisable>on</autodisable>
            <linearthreshold>0.1</linearthreshold>
            <angularthreshold>0.5</angularthreshold>
            <disabletime>0.05</disabletime>
            <!--<solver>QuickStep</solver>-->
            <solver>NormalStep</solver>
       </csiro_odeproperties>
  </physicsengine>
  <!--<physicsengine type="ode">
  
  </physicsengine>-->
</Environment>