电路图
首页 > 消费电子 >卫生保健/数码视听 > 运动激活摄像头
运动激活摄像头

运动触发相机 2026/02/27

我制作了一个相对简单的附件,用于我的佳能单反相机,以创建一个使用Arduino的运动触发相机。这部分大多基于并受启发于The Honey Jar的间隔计项目。我对他的电路做了一些更改,使用4N35光耦合器代替簧片继电器。

以下是您需要的材料:

佳能单反相机,使用2.5mm耳机插孔进行远程快门/对焦控制。我使用的是XSi,但其他型号也应该工作。

Arduino板(我使用了Duemilanove)

(2) 4N35光耦合器(可通过All Electronics等渠道获取,不知道Radio Shack是否有)

2.5mm立体声耳机插头

(2) 1k电阻

来自Parallax的被动红外运动探测器

来自Parallax的带3针接头的延长线

盒子用于容纳所有部件

运动探测器非常敏感,因此我在盒子上切了一个小孔,以尝试减少其视野。这在晚上可能不是大问题,但在白天会不断产生误报。

首先将一些电线焊接到2.5mm耳机插头上。然后按照下图示意图连接插头和电子部件:

运动触发相机

我使用的源代码是:

/**********************

Motion Activated Camera

Dan Bridges 2009

For schematics and more documentation see:

https://www.dayofthenewdan.com/projects/motion-camera

**********************/

boolean focus = false;

int shutterPin = 2;

int focusPin = 3;

int PIRPin = 4;

int shutterPressDelay = 200;

int focusPressDelay = 200;

int interPictureDelay = 500;

void setup(){

pinMode(shutterPin, OUTPUT);

pinMode(focusPin, OUTPUT);

}

void loop(){

if (digitalRead(PIRPin)) {

takePicture();

delay(interPictureDelay);

}

}

void takePicture() {

//If you want the camera to focus first set

//the focus variable to true.

if (focus) {

digitalWrite(focusPin, HIGH);

delay(focusPressDelay);

digitalWrite(focusPin, LOW);

delay(250);

}

digitalWrite(shutterPin, HIGH);

delay(shutterPressDelay);

digitalWrite(shutterPin, LOW);

}

间隔计

相同的电路(减去PIR探测器)也可以用作标准间隔计。将来我可能会添加一个电位器和一个LCD屏幕,以允许自定义时间间隔。

提问/讨论

这里还没有内容,您有什么问题吗?

我要提问/讨论

可能感兴趣的电路图
可能感兴趣的器件
推荐帖子