# How to add stereo camera to UAV in gazebo

**URL:** <https://discuss.px4.io/t/how-to-add-stereo-camera-to-uav-in-gazebo/26570>\
**Category:** ROS 1 / ROS 2\
**Created:** [March 14, 2022, 12:21pm UTC](https://discuss.px4.io/t/how-to-add-stereo-camera-to-uav-in-gazebo/26570 "2022-03-14T12:21:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![JaimeParker](https://discuss.px4.io/user_avatar/discuss.px4.io/jaimeparker/32/10003_2.png) [@JaimeParker](https://discuss.px4.io/u/JaimeParker)\
**Post date:** [March 14, 2022, 12:21pm UTC](https://discuss.px4.io/t/how-to-add-stereo-camera-to-uav-in-gazebo/26570/1 "2022-03-14T12:21:42Z")

</div>

I’ve tried the Monocular camera, and it works successfully.  
I edit the launch file like this:

```xml
    <!-- vehicle model and world -->
    <arg name="est" default="ekf2"/>
    <arg name="vehicle" default="iris"/>
    <!-- add stereo camera for iris -->
    <arg name="my_camera" default="iris_fpv_cam"/>
    <arg name="world" default="$(find mavlink_sitl_gazebo)/worlds/empty.world"/>
    <!-- also need to revise sdf -->
    <arg name="sdf" default="$(find mavlink_sitl_gazebo)/models/$(arg my_camera)/$(arg my_camera).sdf"/>
    <!-- <arg name="sdf" default="$(find mavlink_sitl_gazebo)/models/$(arg vehicle)/$(arg vehicle).sdf"/> -->

```

then I use `rostopic list` command, part of topics below:

```auto
/iris/usb_cam/camera_info
/iris/usb_cam/image_raw
/iris/usb_cam/image_raw/compressed
/iris/usb_cam/image_raw/compressed/parameter_descriptions
/iris/usb_cam/image_raw/compressed/parameter_updates
/iris/usb_cam/image_raw/compressedDepth
/iris/usb_cam/image_raw/compressedDepth/parameter_descriptions
/iris/usb_cam/image_raw/compressedDepth/parameter_updates
/iris/usb_cam/image_raw/theora
/iris/usb_cam/image_raw/theora/parameter_descriptions
/iris/usb_cam/image_raw/theora/parameter_updates
/iris/usb_cam/parameter_descriptions
/iris/usb_cam/parameter_updates

```

it works, so I tried the same way on stereo

```xml
<arg name="my_camera" default="iris_stereo_camera"/>

```

then `rostopic list`  
but nothing related to `iris` or `image` has shown up, nothing in `rqt_image_view` either.  
I’m confused and don’t know why, I’d thank you for any advice!

---

<div class="post-metadata">

**Author:** ![JaimeParker](https://discuss.px4.io/user_avatar/discuss.px4.io/jaimeparker/32/10003_2.png) [@JaimeParker](https://discuss.px4.io/u/JaimeParker)\
**Post date:** [March 15, 2022, 6:23am UTC](https://discuss.px4.io/t/how-to-add-stereo-camera-to-uav-in-gazebo/26570/2 "2022-03-15T06:23:23Z")

</div>

use model in px4, not in .gazebo/models

---

<div class="post-metadata">

**Author:** ![Pooyanght](https://discuss.px4.io/user_avatar/discuss.px4.io/pooyanght/32/16077_2.png) [@Pooyanght](https://discuss.px4.io/u/Pooyanght)\
**Post date:** [October 1, 2024, 4:16pm UTC](https://discuss.px4.io/t/how-to-add-stereo-camera-to-uav-in-gazebo/26570/3 "2024-10-01T16:16:52Z")

</div>

What do you mean by this? how should this be done?
