# Second Camera Auto Run

**URL:** <https://discuss.bluerobotics.com/t/second-camera-auto-run/11067>\
**Category:** Software\
**Created:** [November 23, 2021, 8:05pm UTC](https://discuss.bluerobotics.com/t/second-camera-auto-run/11067 "2021-11-23T20:05:45Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![EliotBR](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/eliotbr/32/6937_2.png) [@EliotBR](https://discuss.bluerobotics.com/u/EliotBR)\
**Post date:** [November 25, 2021, 4:35am UTC](https://discuss.bluerobotics.com/t/second-camera-auto-run/11067/2 "2021-11-25T04:35:30Z")

</div>

Hi @ugurdemirezen,

> [@ugurdemirezen](#):
>
> When rov runs, I want the code I prepared for the second camera to return

Without information on the camera you’re using or the code you’ve written it’s difficult to help.

By “when rov runs” do you mean when it gets powered on, or when the vehicle is armed?

> [@ugurdemirezen](#):
>
> it must be a .sh file.

Is this a limitation on your end? The [`.companion.rc`](https://github.com/bluerobotics/companion/blob/master/.companion.rc) file that’s used for setup when the ROV is turned on doesn’t have any file type requirements (it runs various python and shell files without issues).

> [@ugurdemirezen](#):
>
> I did it with my raspberry pi 4 but when I do same things with raspberry pi 3 it does not work. (companion version: 0.0.28-18-g690ba0c . I have to use this version because it is the only version that works with DVL)

What is the “it” that you did? Companion 0 isn’t expected to run on Raspberry Pi 4 by default, so I’m unsure how you tried something with Companion 0 that apparently worked on Raspberry Pi 4 but not Raspberry Pi 3.

* * *

Assuming your extra camera has a H264-encoded output option, you might want to try the approach I detailed [here](https://discuss.bluerobotics.com/t/streaming-multiple-usb-cameras-at-once/10479/6), which allows setting up multiple streams with only relatively minor modifications to the existing Companion video streaming code.

---

_[View the full topic](https://discuss.bluerobotics.com/t/second-camera-auto-run/11067)._
