Motion Triggered Camera With Raspberry Pi

Introduction: Motion Triggered Camera With Raspberry Pi

Raspberry Pi with HC-SR501 Passive Infrared Sensor to detect squirrel's appearance, and then trigger SONY A6300 to record the video at the best angle and distance.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: What You Need:

  • A camera, I used SONY A6300
  • Raspberry Pi, mine is version 2 model B
  • HC-SR501 motion sensor, with some cables

For a list of supported camera, please check here:

http://gphoto.org/proj/libgphoto2/support.php

Step 2: Connect the Sensor to the Pi

5V, GND, and any GPIO pin

Remember the pin number, you will need it in the python script.

Step 3: Connect the Rest

  1. Make sure the camera is in PC Remote mode (SONY A6300)
  2. Connect the Raspberry Pi to the camera
  3. Connect the power source to the Raspberry Pi

For a list of supported camera, please check here:

http://gphoto.org/proj/libgphoto2/support.php

Step 4: Setup the Raspberry Pi

Please follow the steps at my GitHub:

https://github.com/seesunmoon/rpi_camera_sensor

Then you can do some tests.

Step 5: Do Something Fun

You can use this setup to capture some wild animals you couldn't do before.

Step 6: Some Sample Videos. Enjoy!

1 Person Made This Project!

Recommendations

  • Finish It Already Speed Challenge

    Finish It Already Speed Challenge
  • Arduino Contest 2020

    Arduino Contest 2020
  • First Time Author Contest

    First Time Author Contest

3 Discussions

0
furtive
furtive

Question 3 days ago on Step 6

Thanks for the information on turning a camera into a wildlife trap. Can the camera be triggered to take a photo rather than start filming video?

1
furtive
furtive

Answer 3 days ago

To answer my own question, I guess just need to change the subprocess call in the python script to replace "--set-config", "movie=1", "--wait-event="+str(movie_length) +"s", "--set-config", "movie=0"] with --capture-image

I'll order the bits needed and will give it a try.

0
seesunmoon
seesunmoon

Reply 3 days ago

Yes! Thanks