Pages: [1]   Go Down
Author Topic: Resistors for this PIR sensor  (Read 617 times)
0 Members and 1 Guest are viewing this topic.
California
Offline Offline
Sr. Member
****
Karma: 2
Posts: 433
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

So I got this Panasonic PIR sensor(EKMC1601113) and I was super relieved at how easy it was to get working but now I want to be sure I'm doing it as well as possible. As a digital input it works perfectly and as analog it seems to go between 0 and 1000. That seems pretty close to both ends like I would imagine it should be but I still want to be sure I'm doing it right. I'm using a 100kohm resistor to pull down to ground and a 10kohm resistor to connect to the arduino inputs. I pretty much just guessed there, is there a more efficient way of deciding those values?

thanks


* PIR.gif (5.05 KB, 626x279 - viewed 27 times.)
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 548
Posts: 46009
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

That appears to be a digital sensor - the output is either HIGH or LOW. That should be input to a digital pin.

Quote
As a digital input it works perfectly and as analog it seems to go between 0 and 1000.
I wouldn't expect anything but ~0 and ~1023.

Quote
but I still want to be sure I'm doing it right.
When connecting to a digital pin, yes. When connecting to an analog pin, no. It's like trying to determine the degree of pregnancy. You either are or you aren't. You can't be a little bit pregnant.

Quote
I'm using a 100kohm resistor to pull down to ground
A 20k would be better.

Quote
and a 10kohm resistor to connect to the arduino inputs.
Why? Something wrong with a simple wire?

Logged

California
Offline Offline
Sr. Member
****
Karma: 2
Posts: 433
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I just figured hooking it up to the analog would tell me how high the high was and how low the low was so I could be sure it wasn't giving me a signal that could become confused.

The resistor to the digital pin was just because I was afraid to fry something and they showed it on the data sheet.

I'll use the 20k to ground if you say that's how it should be done. Thanks.
Logged

Pages: [1]   Go Up
Jump to: