Home > Other >Special Application Circuits > DIY an indoor and outdoor webcam

DIY an indoor and outdoor webcam

Source: InternetPublisher:念念Brown Keywords: DIY design webcam Updated: 2024/12/17

Have you ever wanted to add a little more security to your neighborhood but didn't want to buy an expensive 1080p webcam, or just wanted to make one yourself? Well, that's exactly what this article is about!

First, you will need the following parts:

Pi Camera

Pi Zero W

Cable adapter

Waterproof DC jack

5v 2A DC Power Supply

And the following tools:

iron

drill

screwdriver

Step 1: Download and Flash Rasbian Jessie Lite

poYBAGK_sdiAf65rAALlePBNryg798.png

Visit https://goo.gl/KJcV7F to download the zip file, then extract it to flash using win32 disk imager, found here: https://goo.gl/VgGrNm.

Step 2: SD Card

poYBAGK_sdSAEL-2AAEudY4swqk687.png

In the boot partition, the one you see on Windows, add a file called wpa_supplicant.conf and edit it in Notepad. Copy and paste the code below, then edit the SSID and password variables.

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev update_config=1 network={ ssid=“SSID” psk=“PASSWORD” }

Then add a blank ssh.txt file to enable ssh.

Step 3: Connect to the Pi via SSH

poYBAGK_sc-AfvVWAAEMvvGpGC8411.png

I used Fing to scan my network to find the Raspberry Pi, and then connected via SSH using Putty (https://goo.gl/d7nFtq).

Step 4: Setting up PiCam

pYYBAGK_scuAAsUVAAFSY8XumiE655.png

This is easy: copy the following command into your terminal and it should now be able to run on its own.

sudo apt-get update

sudo apt-get dist-upgrade

sudo apt-get install git

git clone https://github.com/silvanmelchior/RPi_Cam_Web_Interface.git

cd RPi_Cam_Web_Interface 。/install.sh

Step 5: Setting up PiCam

pYYBAGK_sceAE8XDAAH_pCoMivI346.png

The subfolder field is what you get the camera from (ex: 192.168.1.12/camera); this can be anything you want. Everything else is ready to go!

We’re not going to restart yet because we still need to open the camera, so select “No” when it asks.

Step 6: Open the camera

poYBAGK_scKAHntJAADuPrvkUlg224.png

We are now going to turn on the camera. Run raspi-config:

sudo raspi-config

Then select Interface Options and then Camera. A message will pop up saying "Do you want to turn on your camera", select yes, then select yes again when asked to restart.

Step 7: Focus the camera

poYBAGK_sb2Af5iRAACSLHS7r-Q473.png

Adjust the lens until it's perfect and it should be in focus no matter the distance of the object. The live video feed has no lag so it's very easy.

Step 8: Assemble the box

pYYBAGK_sbmAeZyxAAKv3Zq4Vd0865.png

Solder the wires as per the images I provided. I recommend checking the polarity of the DC jack before connecting, but 5v will usually go to the shorter pin and GND will usually go to the longer pin. Use hot glue to hold everything in place; make sure not to get any glue set in the connectors if you want to remove them later. I used some brackets to hold the camera in place. This is fairly effective, but remember they may not be very solid so you need to be a little gentle with them.

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号