Page 1 of 1

Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 10:11 am
by Dubman
Hi, I have a python script working with the pi camera module (with Rpi 3 board) and a PIR sensor that triggers email alerts when an intruder is detected.
But how would I go about adding a second camera to the same Rpi, in such a way that every time the (one) sensor triggers an alert, both cameras would supply separate images of the captured images, from different angles? Thanks

Re: Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 10:46 am
by spock
the rpi3 (and even rpi4) only supports one pi camera module.

the compute module (+ compute module io board) supports two pi camera modules...

so you would have to use an usb camera as a second camera or use the compute module.



edit:
i would prefer if the normal raspberry pi 4 had 2 CSI connectors and got rid of the DSI connector. who needs the DSI connector if there are two hdmi ports? :)

Re: Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 11:41 am
by wildfire
spock wrote:
Thu Jul 04, 2019 10:46 am
i would prefer if the normal raspberry pi 4 had 2 CSI connectors and got rid of the DSI connector. who needs the DSI connector if there are two hdmi ports? :)
Perhaps you would but I'm sure others who (like myself) bought the Official 7" touch screen would probably disagree.

Re: Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 2:04 pm
by aBUGSworstnightmare
spock wrote:
Thu Jul 04, 2019 10:46 am
edit:
i would prefer if the normal raspberry pi 4 had 2 CSI connectors and got rid of the DSI connector. who needs the DSI connector if there are two hdmi ports? :)
I would disagree! Who needs to cameras would be my question to you!
Yes, there are two HDMI connectors, but the DSI 7in has touch input which is not available via HDMI.

Re: Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 2:18 pm
by alphanumeric
Ditto to wanting the DSI. Now with the Pi 4 I can plug in a second monitor and not have to jump through hoops to have it work with the official 7 inch touch screen. Just a few mouse clicks, or screen touches lol.
I also use the CSI, I have a several headless 3A+'s running motion eye with official Pi cameras attached. With short ribbon cables its a nice compact setup.
Anyway, as already posted you will need to go with a USB or GPIO connected camera to run two if one is the Pi Foundation camera. Get that working and then worry about triggering both at the same time.

Re: Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 2:28 pm
by jbeale
Add a second pi? Even the Pi Zero supports a camera, and the price is minimal. This gives you the freedom to position anywhere you want, instead of needing a long camera cable. You can have a command sent over the LAN trigger the photo on the second unit. Programs like PiKrellCam http://billw2.github.io/pikrellcam/pikrellcam.html make it convenient to do this sort of thing, although you still need to do a bit of scripting.

If you really don't want a second Pi, then just add a USB camera.

Re: Adding second camera to Rpi 3?

Posted: Thu Jul 04, 2019 2:38 pm
by alphanumeric
If your only taking pictures / snapshots a Pi zero will likely be fine. I tried using a Pi Zero with Motion Eye and IMHO it just wasn't up to the task of streaming video over WIFI. Lots of lag and gitter. Also keep in mind that the CSI connector on the Pi Zero is smaller than the one on the other Pi's. You need a special camera cable for the Pi Zero and official camera. The cable supplied with the camera won't plug into a Pi Zero's CSI connector.

Re: Adding second camera to Rpi 3?

Posted: Fri Jul 05, 2019 5:59 am
by Dubman
I do have a second Rpi 3, but would it be complicated to get it working with the current system, which is a Rpi 3 plus PIR sensor that triggers email alerts on detection of intruders? I mean, would the one PIR sensor be sufficient? I assume I would need to connect the second Rpi and its camera module by LAN to the router, and the Python script would need modificaton? Thanks

Re: Adding second camera to Rpi 3?

Posted: Fri Jul 05, 2019 9:47 am
by alphanumeric
Thats something I haven't tried. My cameras are basically all independent of each other. They all connect over my WIFI and are viewable from a web browser. Motion eye will take pictures if motion is detected in the camera image. I played with it a bit but never really got it working the way I wanted. I either got no pictures or +100 pictures of a blurred Blue Jay.
I have a PIR sensor and an Ultrasonic sensor. At one time I was going to have a go at using them with one of my cameras but couldn't find my round 2it. ;)

Re: Adding second camera to Rpi 3?

Posted: Fri Jul 05, 2019 11:22 am
by alphanumeric
Just happened on this a few minutes ago, have a look see it might help.
https://www.instructables.com/id/Bird ... tor-V20/

Re: Adding second camera to Rpi 3?

Posted: Sat Jul 06, 2019 10:10 am
by spock
aBUGSworstnightmare wrote:
Thu Jul 04, 2019 2:04 pm
I would disagree! Who needs to cameras would be my question to you!
Yes, there are two HDMI connectors, but the DSI 7in has touch input which is not available via HDMI.
i would have many ideas for two cameras. 3D or 360° movie captures, surveillance like the original poster,...

there are many displays that work with HDMI and do touch over USB. they also are cheaper than the official DSI display. so i am quite surprised that so many people seem to use the DSI connector. :)

Re: Adding second camera to Rpi 3?

Posted: Sat Jul 06, 2019 11:19 am
by alphanumeric
I have my Pi foundation 7 inch screen mounted to an aluminum frame. Being able to bolt the Pi to the back of the display with a nice short cable works out nicely for me. Different strokes for different folks. My setup is portable enough to move it from one room to another with my Pi and monitor in one hand, power supply in the other.

Re: Adding second camera to Rpi 3?

Posted: Sat Jul 06, 2019 4:33 pm
by W. H. Heydt
spock wrote:
Thu Jul 04, 2019 10:46 am
edit:
i would prefer if the normal raspberry pi 4 had 2 CSI connectors and got rid of the DSI connector. who needs the DSI connector if there are two hdmi ports? :)
What? And have to get new screens if I decide to upgrade three of my systems? Sorry...no. Let me add to that....NO!

Re: Adding second camera to Rpi 3?

Posted: Tue Jul 09, 2019 12:55 pm
by Dubman
Thanks for the suggestions. I'm hoping to find the simplest possible solution.

Re: Adding second camera to Rpi 3?

Posted: Tue Jul 09, 2019 12:59 pm
by gordon77
Use a USB camera