# How to access BlueROV2 camera stream

**URL:** https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384
**Category:** General Discussion
**Created:** [July 9, 2024, 10:07pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384 "2024-07-09T22:07:37Z")
**Posts on this page:** 9
**Page:** 2

<div class="post-metadata">

### Author: ![ssicari](https://avatars.discourse-cdn.com/v4/letter/s/ce7236/32.png) [@ssicari](https://discuss.bluerobotics.com/u/ssicari)
#### Post date: [July 30, 2024, 6:28pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/21 "2024-07-30T18:28:52Z")

</div>

No we used the code out of the box. We tested running it on a linux machine with ubuntu 22.04. The ubuntu machine has plenty of resources but has very bad latency. We were getting about 1 frame every 4-5 seconds. I will add we also tested out changing the code after having latency problems running the given code and couldn’t get that to perform any better.

---

<div class="post-metadata">

### Author: ![patrickelectric](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/patrickelectric/32/2162_2.png) [@patrickelectric](https://discuss.bluerobotics.com/u/patrickelectric)
#### Post date: [July 31, 2024, 5:11pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/22 "2024-07-31T17:11:02Z")

</div>

Hi @ssicari,

In this case, it appears to be a problem with the libav installed in your machine. I would recommend changing the `avdec_h264` with another h264 decoder.

In my machine I have the following:

libav: avdec\_h264: libav H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 decoder  
nvcodec: nvh264dec: NVDEC H.264 Decoder  
vulkan: vulkanh264dec: Vulkan H.264 decoder

libav works without problems.

You can test the pipeline using the following command:

```auto
gst-launch-1.0 udpsrc port=5600 caps='application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264' ! rtph264depay ! avdec_h264 ! queue ! autovideosink

```

---

<div class="post-metadata">

### Author: ![ssicari](https://avatars.discourse-cdn.com/v4/letter/s/ce7236/32.png) [@ssicari](https://discuss.bluerobotics.com/u/ssicari)
#### Post date: [August 5, 2024, 4:12pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/23 "2024-08-05T16:12:54Z")

</div>

Thank you that works now. Weirdly enough the same code that was giving me problems also works now without being changed. Perhaps it was related to our camera having problems due to the resistors being pushed against the camera mount. I fixed that last week and it all seems to be working now

---

<div class="post-metadata">

### Author: ![qimg](https://avatars.discourse-cdn.com/v4/letter/q/f4b2a3/32.png) [@qimg](https://discuss.bluerobotics.com/u/qimg)
#### Post date: [March 29, 2025, 2:40pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/24 "2025-03-29T14:40:27Z")

</div>

hello, I am able to see the video in blue os, but fail to play it in VLC

 ![IMG_20250329_223903](https://us1.discourse-cdn.com/flex019/uploads/bluerobotics/original/2X/0/05f944289888fa6844c5e3a36bea2756fed9e288.jpeg)  
 ![IMG_20250329_223858](https://us1.discourse-cdn.com/flex019/uploads/bluerobotics/original/2X/2/20fe05509dd1455dcb584f7738207d7e91c94b80.jpeg)

---

<div class="post-metadata">

### Author: ![tony-white](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/tony-white/32/13297_2.png) [@tony-white](https://discuss.bluerobotics.com/u/tony-white)
#### Post date: [March 29, 2025, 6:13pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/25 "2025-03-29T18:13:49Z")

</div>

Hi @qimg -  
Try that with an H264 stream, not MJPG!

---

<div class="post-metadata">

### Author: ![qimg](https://avatars.discourse-cdn.com/v4/letter/q/f4b2a3/32.png) [@qimg](https://discuss.bluerobotics.com/u/qimg)
#### Post date: [March 30, 2025, 4:59am UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/26 "2025-03-30T04:59:40Z")

</div>

Is blue os not able to get rtsp with mjpg? I want to add url video in cockpit, can it work?

---

<div class="post-metadata">

### Author: ![tony-white](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/tony-white/32/13297_2.png) [@tony-white](https://discuss.bluerobotics.com/u/tony-white)
#### Post date: [March 31, 2025, 4:18am UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/27 "2025-03-31T04:18:11Z")

</div>

Hi @qimg -  
BlueOS and Cockpit do not support MJPG video currently. An H264 stream should work just fine though!

---

<div class="post-metadata">

### Author: ![tritonkeller](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/tritonkeller/32/14168_2.png) [@tritonkeller](https://discuss.bluerobotics.com/u/tritonkeller)
#### Post date: [June 12, 2025, 3:43pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/28 "2025-06-12T15:43:51Z")

</div>

So, I am also trying to integrate a MJPG stream.

I’m actually trying to troubleshoot another [issue](https://discuss.bluerobotics.com/t/no-video-stream-waterlinked-ugps-integration/20116/6), but I’m currently away from our ROV. My goal is to integrate an [off-the-shelf camera](https://www.walmart.com/ip/Onn-4K-Webcam-with-Autofocus-and-Swivel-Head/13518318667?classType=REGULAR) with a ROV clone (just the Pi4+Navigator). In my infinite wisdom, I left the spare BR low-light camera in our lab and won’t have it for the next month of testing. Thus, I assumed any USB camera would suffice.  
When I plugged in the camera to the USB 3.0 port on the Pi, I only see 2 options for the stream encoding.

 ![Screenshot 2025-06-12 083238](https://us1.discourse-cdn.com/flex019/uploads/bluerobotics/original/2X/2/274b2cb621a77714a88ec2129ee2822ee361b8fb.png)  
The MJPG allows for 30fps, while YUYV only allows for 1fps for me. It appears that I can create a UDP stream, as _sometimes_ the stream will be created, and I can view it in VLC using the SDP link. The UDP address doesn’t show anything on VLC.  
 ![Screenshot 2025-06-12 083039](https://us1.discourse-cdn.com/flex019/uploads/bluerobotics/original/2X/9/96ad9acfe4e606abe525a004d9bb8a56809047b9.png)  
More often than not, after restarting the Pi, the stream works for the first minute or two (on VLC), then cuts out and will not be accessible from VLC. During none of this time is the stream visible on QGC or Cockpit. Also, the BlueOS video streams page often automatically deletes the video stream or displays a timeout or no video streams available error.  
My question: is the MJPG-encoded camera able to be displayed on QGC? Based on the fact I can sometimes see it on VLC, I assume video is being sent, but I can’t quite tell.

---

<div class="post-metadata">

### Author: ![joaoantoniocardoso](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/joaoantoniocardoso/32/8377_2.png) [@joaoantoniocardoso](https://discuss.bluerobotics.com/u/joaoantoniocardoso)
#### Post date: [June 12, 2025, 8:18pm UTC](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384/29 "2025-06-12T20:18:10Z")

</div>

> My question: is the MJPG-encoded camera able to be displayed on QGC? Based on the fact I can sometimes see it on VLC, I assume video is being sent, but I can’t quite tell.

It does work with QGC if you use RTSP instead of UDP for that. Be aware, though, that a 30fps 1080p MJPG stream can use up to around 50Mbps of bandwidth.

Here’s an example, using our [Low-Light HD USB Camera](https://bluerobotics.com/store/sensors-cameras/cameras/cam-usb-low-light-r1/):

 ![image](https://us1.discourse-cdn.com/flex019/uploads/bluerobotics/original/2X/c/c1ae5ebc4a258a5d458e766b4d4a53096e86f293.png)

[Previous page](https://discuss.bluerobotics.com/t/how-to-access-bluerov2-camera-stream/17384.md?page=1)
