# M500 Camera Feed Upside Down

Source: https://forum.modalai.com/topic/116/m500-camera-feed-upside-down
Category: Development Drones (https://forum.modalai.com/category/44/development-drones)
Tags: m500
Posted: 2021-01-29 04:35:08 UTC by Lynn Koudsi
Replies: 8 · Views: 2045

## Lynn Koudsi · 2021-01-29 04:35:08 UTC

I have an out-of-the-box VOXL M500 that streams the video upside down when running `voxl-rtsp -c 0`. I tried configuring with `voxl-configure-vision-px4 ` but the issue persisted. I haven't calibrated the camera yet, and the image version is at 2.5.2.

Am I missing any steps?

Thanks

## Reply by Chad Sweet (ModalAI staff) · 2021-01-29 04:43:55 UTC

No, it is mounted upside down. we can flip in software though. Will get back to you quickly on how to do it

## Reply by Eric Katzfey (ModalAI staff) · 2021-01-29 15:42:42 UTC

How are you viewing the video? In some viewers, such as VLC, there is a way to rotate the image.

## Reply by Chad Sweet (ModalAI staff) · 2021-01-29 18:47:16 UTC

The simplest method is to flip in your viewer.

If that's not possible, you can use a flipped driver for the IMX214 sensor found [here](https://developer.modalai.com/asset/download/63). Be careful when doing this. Below are the commands (I don't have a board in front of me, but this should be close)
```
adb push libmmcamera_imx214_rot180.so /usr/lib/
adb shell mv /usr/lib/libmmcamera_imx214.so /usr/lib/libmmcamera_imx214_orig.so # this name might be wrong, but something similar
adb shell ln -s /usr/lib/libmmcamera_imx214_rot180.so /usr/lib/libmmcamera_imx214.so
<power cycle the board>
```

If the camera doesn't come up, then revert the above changes and let us know.  Basically you're changing the default driver to one that has the image flipped.

We will fix this by default in an upcoming system image, likely 3.2

## Reply by Lynn Koudsi · 2021-02-24 14:42:17 UTC (in reply to Chad Sweet)

@Chad-Sweet Thanks for the reply Chad! 
I will try your instructions

Also, I've been going through the documentation and I found the voxl-streamer utility, and it looks like it allows orientation. Would that work as well? I'm a little hesitant to try it since I'm on an older version than 3.0.0 and I would want to update only when necessary.

Thanks again

## Reply by Lynn Koudsi · 2021-02-24 14:46:41 UTC (in reply to Eric Katzfey)

@Eric-Katzfey I'm viewing in QGroundControl, so as far as I know, there's no way to flip the video feed, unless you turn the tablet upside down

## Reply by Eric Katzfey (ModalAI staff) · 2021-02-24 15:08:19 UTC

That's correct, QGroundControl has no way to change the video orientation. And yes, voxl-streamer does have an option to rotate the video 90, 180, or 270.

## Reply by Lynn Koudsi · 2021-02-25 00:21:56 UTC (in reply to Chad Sweet)

@Chad-Sweet I tried replacing the driver but it gave me the following error when trying to stream camera 0 ![IMG_20210224_155006.jpg](https://forum.modalai.com/assets/uploads/files/1614212244782-img_20210224_155006-resized.jpg) 

Cameras at ID 1 and 2 worked though (stereo and tracking)

I also configured the cameras as option 3 (Hires + Stereo + Tracking) and it issued the following result:
```
attempting to use camera configuration 3
adding override_cam_id value=1 to /etc/snav/camera.downward.xml
adding override_cam_id value=2 to /etc/snav/camera.stereo.xml
```

I also tried reverting the driver change and reset the configurations to factory settings but the issue persisted. 

One last thing to note is that whatever camera configuration I ended up setting it to, streaming camera at ID 0 does not work anymore. 

Any ideas on how to fix this?

Thanks

## Reply by Lynn Koudsi · 2021-02-26 22:25:22 UTC (in reply to Lynn Koudsi)

Edit: reverting to original driver returns the functionality to default (upside down feed)
