I have ordered a peephole camera but when I use it, realized that there is no auto recording function (activated by motion detection). Then I started to investigate how it works.
To record a video, you should
1- keep pressed power button almost 2 secs.
2- press record button then It starts recording one minute video and stops.
3- keep pressed power button almost 3 secs to power off. (because it stays on after recording).
Now we have to use a PIR sensor to sense if there is a people or not..
Step 1: PIR Sensor
Automatic induction: to enter the sensing range of the output is high, people leave the sensor range automatically delay off high, output low. Ultra-small size.
Repeatable trigger: the sensor output high, the delay period, if there is human activity in its sensing range, the output will remain high until people leave after the high variable delay lOW (automatically extended sensor module detects the human body after every activity a delay period, and the last time an event is the starting point of the delay time).
We also need a mcu to check output of PIR sensor and operate the Peephole camera buttons. In this project I choose arduino again. It's easy to use.
Step 2: Relay Module & High Voltage Generator & OLED Screen
We use this relay module to push Power & Record button and also making electric shock.
High Voltage Generator
input voltage: DC 3 V to 6 V
Input current: 2 A - 5 A High pressure type: the type of pulse current Output voltage: 400000 v(Please pay attention to safety) High pressure discharge distance between: 10 mm - 20 mm The output high voltage wire length: 100 mm Input power cord length: 100 mm (the red line is positive) Wiring: Red and green power connection red line:"+" green line "-" output : the other side ,same color cable
Step 3: Soldering on Camera Circuit for Relay Module
First of all, we remove the screws and cut the connection of battery case Then solder
*2 cables to battery cables, we supply voltage by using an adapter.
*2 cables to Power button pins for on/off electric shock feature
*2 cables to Connection ponits of Power button pins (on motherboard) (for the relay module)
*2 cables on the record pushbutton (for the relay module)
Finally, do not forget to cut the cables of buffer , It can be very disturbing
Step 4: High Voltage Generator
We will add this feature to scare away any intruder from our door..
Third relay is for voltage generator.
Step 5: CODE
Code was translated in to English,
Turkish statements are shown in the pictures.
HAREKET ALGILAMA --> MOTION DETECTION
HAREKET VAR ---> MOTION IS DETECTED
KAYIT BASLATILIYOR --> START RECORDING
ELEKTROSOK KAPALI --> ELECTRIC SHOCK OFF