Skip to content

Commit ae47c67

Browse files
committed
Gimbal: add depth camera to gimbal_small_2d
Signed-off-by: Rhys Mainwaring <rhys.mainwaring@me.com>
1 parent 3791592 commit ae47c67

1 file changed

Lines changed: 98 additions & 0 deletions

File tree

models/gimbal_small_2d/model.sdf

Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,5 +186,103 @@
186186
</axis>
187187
<pose>0 0 0.02 0 0 0</pose>
188188
</joint>
189+
190+
<link name='camera_link'>
191+
<pose degrees="true">0 0 0 -90 -90 0</pose>
192+
<inertial>
193+
<mass>0.01</mass>
194+
<inertia>
195+
<ixx>0.00001</ixx>
196+
<ixy>0</ixy>
197+
<ixz>0</ixz>
198+
<iyy>0.00001</iyy>
199+
<iyz>0</iyz>
200+
<izz>0.00001</izz>
201+
</inertia>
202+
</inertial>
203+
<visual name='visual'>
204+
<pose>0 0 0 0 0 0</pose>
205+
<geometry>
206+
<cylinder>
207+
<radius>0.025</radius>
208+
<length>0.050</length>
209+
</cylinder>
210+
</geometry>
211+
<material>
212+
<ambient>0.4 0.4 0.4</ambient>
213+
<diffuse>0.4 0.4 0.4</diffuse>
214+
<specular>0.1 0.1 0.1 1.0</specular>
215+
</material>
216+
</visual>
217+
<collision name='collision'>
218+
<pose>0 0 0 0 0 0</pose>
219+
<geometry>
220+
<cylinder>
221+
<radius>0.025</radius>
222+
<length>0.050</length>
223+
</cylinder>
224+
</geometry>
225+
</collision>
226+
<sensor name="camera" type="camera">
227+
<gz_frame_id>camera_link</gz_frame_id>
228+
<pose degrees="true">0 0 0 0 0 0</pose>
229+
<camera>
230+
<horizontal_fov>2.0</horizontal_fov>
231+
<image>
232+
<width>640</width>
233+
<height>480</height>
234+
</image>
235+
<clip>
236+
<near>0.05</near>
237+
<far>15000</far>
238+
</clip>
239+
</camera>
240+
<always_on>1</always_on>
241+
<update_rate>10</update_rate>
242+
<visualize>1</visualize>
243+
<plugin name="GstCameraPlugin"
244+
filename="GstCameraPlugin">
245+
<udp_host>127.0.0.1</udp_host>
246+
<udp_port>5600</udp_port>
247+
<use_basic_pipeline>true</use_basic_pipeline>
248+
<use_cuda>false</use_cuda>
249+
</plugin>
250+
</sensor>
251+
<sensor name="depth_camera" type="depth_camera">
252+
<gz_frame_id>camera_link</gz_frame_id>
253+
<pose degrees="true">0 0 0 0 0 0</pose>
254+
<camera>
255+
<horizontal_fov>1.05</horizontal_fov>
256+
<image>
257+
<width>256</width>
258+
<height>256</height>
259+
<format>R_FLOAT32</format>
260+
</image>
261+
<clip>
262+
<near>0.1</near>
263+
<far>20.0</far>
264+
</clip>
265+
</camera>
266+
<always_on>1</always_on>
267+
<update_rate>10</update_rate>
268+
<visualize>1</visualize>
269+
</sensor>
270+
</link>
271+
<joint name='camera_joint' type='revolute'>
272+
<parent>tilt_link</parent>
273+
<child>camera_link</child>
274+
<axis>
275+
<xyz>0 0 1</xyz>
276+
<dynamics>
277+
<damping>0.5</damping>
278+
</dynamics>
279+
<limit>
280+
<lower>0</lower>
281+
<upper>0</upper>
282+
</limit>
283+
</axis>
284+
<pose>0 0 0 0 0 0</pose>
285+
</joint>
286+
189287
</model>
190288
</sdf>

0 commit comments

Comments
 (0)