# Using OV9782 image sensor for VIO on VOXL 2

Source: https://forum.modalai.com/topic/3989/using-ov9782-image-sensor-for-vio-on-voxl-2
Category: Autonomy: VIO, Mapping and Navigation (https://forum.modalai.com/category/19/autonomy-vio-mapping-and-navigation)
Tags: vio
Posted: 2024-12-02 22:44:15 UTC by svempati
Replies: 3 · Views: 827

## svempati · 2024-12-02 22:44:15 UTC

I am trying to implement Visual Inertial Odometry using the QVIO server to find the local XYZ positions, but the documentation only mentions it working with the tracking camera (Camera and IMU Calibration section in https://docs.modalai.com/voxl-qvio-server-0_9/#resetting-vio).

Would I be able to use the OV7982 image sensor on VOXL 2 so that I get a similar output as the one below when I run `voxl-inspect-qvio`? If that would work, are there additional configurations or parameters I need to change before running VIO?

```
yocto:/$ voxl-inspect-qvio

    T_imu_wrt_vio (m)   |Roll Pitch Yaw (deg)| state| error_code
   -4.96    0.94   -0.00|  17.9  -52.3    9.3| OKAY | 
```

## Reply by Alex Kushleyev (ModalAI staff) · 2024-12-04 04:24:03 UTC

@svempati ,

It should work (that is to say, we have tested QVIO with OV9782), although this is not our standard configuration. You need to modify your `/etc/modalai/voxl-qvio-server.conf` file accordingly:
- update `cam_name` to match the output pipe of the monochrome image from ov9782), you can double check the name using `voxl-portal`
- update camera calibration file (intrinsics) and position / orientation w.r.t IMU (extrinsics) of the new camera. It will help if you position and orient your new camera exactly the same as the old tracking camera

Did you try this?

Alex

## Reply by svempati · 2024-12-04 16:33:29 UTC (in reply to Alex Kushleyev)

@Alex-Kushleyev I haven't yet but will try doing that. I just wasn't sure how to configure the camera for VIO. Thank you!

## Reply by Alex Kushleyev (ModalAI staff) · 2024-12-04 17:30:38 UTC (in reply to svempati)

@svempati, sounds good, let me know if you run into any issues.

You should always test new VIO changes without flying first, by holding the drone in your hand and carrying it around.
If you set it up and QVIO "blows up" as soon as you start moving the drone, this most likely means incorrect extrinsic parameters (most likely camera to imu rotation).

Alex
