Introduction: Pi Zero Peep Hole Camera

What follows is are the details of my peep hole webcam built with a Raspberry Pi Zero. I live in a large NYC apartment building and am regularly curious about sounds I hear coming from the hallway, and wish I had an eye outside from my desk. I have successfully used this webcam peep hole rig to identify The Hallway Whistler, among other mysteries. Using the motion detection, one could configure such a system to automatically take/upload photos and videos of door events. But I'm no Linux expert-- I largely followed Tony D's Cloud Cam tutorial on Adafruit for the software configurations required!

For this project you will need:

Step 1: Configure WiFi

Picture of Configure WiFi

First up it's configuration time! Plug in your wireless keyboard/mouse dongle to your powered usb hub and configure the wifi module to join your local network. After your Pi connects to the internet, you can log in to it remotely using SSH from your regular computer, unless you like the punishing tinyness of the keyboard and monitor combo.

Step 2: Configure Camera & Motion

Picture of Configure Camera & Motion

Install motion and configure the setup it as a live webcam, motion-activated photo-taker, timelapse camera, or whatever else your heart desires.

Step 3: Install and Test

Picture of Install and Test

Once everything's working, you can disconnect the monitor and USB hub, leaving only the power supply and wifi module plugged in. Then it's time to attach it to the door.

Since my door is steel, magnets work quite well to suspend a plastic bag of components near the peep hole. At first I tried taping it in place where you look into it. This arrangement wasn't pretty, but it works!

Step 4: Refine

Picture of Refine

The camera was too far from the lens of the peep hole-- I had to open it up and get it closer! My doorbell takes up the rest of the space in the compartment but there was plenty of free space, especially considering I don't need or love my doorbell so much. I swapped the clear plastic bag for an old zip-up makeup bag, and re-installed the cover. The battery arrangement is temporary until I get an extension cord run down the long hallway to my front door.

I also wasn't thrilled with how backlit my subjects looked through the camera, so I tried swapping the regular camera for the Raspberry Pi NoIR camera, with only little improvement in the visibility of facial features. Got any hot tips for getting IR LEDs to shine out the peep hole without reflecting on the plastic and ruining the image? Leave your suggestions in the comments! =D

Step 5: Use It!

Picture of Use It!

I used the monitor from setup as a webcam monitor for this project by plugging it into my computer as an external display. I loaded up the local webcam address and voila, security feed from the front door!


RichardA147 (author)2016-08-29

Pretty Cool. You might Consider for a future upgrade a M12 Peephole lens and M12 adapter for the pi camera.

Very good idea! What focal length would you choose so the image area would exclude the dark inner part of the peephole tube, while still covering the whole image area provided by the peephole fisheye lens? How would it affect focus?

bekathwia (author)RichardA1472016-08-30

Cool, thank you for the suggestion!

BharathK54 (author)bekathwia2016-08-31

Where can I get pizero it is not available in india have the pi zero in stock and will ship internationally at a very reasonable rate.

Ancifero (author)2016-09-06

As they say Russian D&G! (Dorogo and Glupo) is expensive and foolish
You could hang a camera from the outside. In this case - the picture would have been better. And the look around would have been better

sorry. i use google translate.

paulstaf (author)2016-09-06

You could put the camera board ribbon cable through the door frame over the top of the door and double-sided tape it above the door on the outside and put the pi above the door on the inside. Or, you could solder some infrared LEDs to a ribbon cable and put them through the crack in the door frame on the outside above the door as illumination. A thin ribbon cable should pass through the frame without interfering with the door operation.

thegrendel (author)2016-09-02

As an alternative to the camera board, you could also use an el-cheapo webcam plugged into usb (using a powered hub). You'd need a hole drilled through the door or apartment wall for the usb cable, of course.

Great project and creative use of the 'zero.

SexyCyborg (author)2016-09-01

I could never get a decent image through a peephole so 3D Printed a small housing for the camera board, double stick taped it to the outside of the door at the edge and taped the ribbon cable down inside the door where the hinges are. It's pretty tiny and no one has ever messed with it since they don't want to be on camera doing it.

Love your builds BTW!

TedN10 (author)2016-09-01

for Infrared lighting, you could just have a few IR LED's hanging out over the top of the door, pointing down at an angle :)

Maybe even have them only turn on via Motion-detection

PaulB425 (author)2016-08-31

2 requests... maybe

I've worked with regular sized
Pi. Wifi pretty much just works. There really isn't anything to do as
far as "configure wifi". Is there much configuring with zero? If so,
would you be able to describe the process?

In your step 3, what
does that consist of? Is there packages to install? configuration? never
worked with a camera so i'm wondering what's involved.

bekathwia (author)PaulB4252016-09-01

For wifi, the configuring is just the network name and password!

I followed the step by step Cloud Cam tutorial linked in the first step for the configuration of the camera and other software. Tony's guide is perfect, go check it out! This is one of my first Pi projects so I wouldn't purport to actually know what I'm doing... =]

PaulB425 (author)PaulB4252016-08-31

sorry... i meant step 2 above. configure camera and motion

fcristel (author)2016-09-01

Why isn't the video stream more fluid? Is it because of the Pi Zero not being able to handle it?
Great job, btw!

About This Instructable




Bio: Becky Stern is a content creator at Autodesk/Instructables. She has authored hundreds of tutorials about everything from wearable electronics to knitting. Before joining Instructables ... More »
More by bekathwia:Tips for Moving in New York CityBecky's Top Projects 2017Making Studio Fall 2017
Add instructable to: