Motion PIR Sensor // weird stuff ...

Hi there!

I’ve just bought a new PIR Sentor, and I’m trying to make it work, just changing the state of a LED depending on the sensor value.

The sensor is this one you can find on “cool components” website.

First of all, I’ve been trying many different codes.

And at the end, I just get some weird stuff, the led is kind of blinking, even if there is nothing detectable. And I’m extremely sure there is nothing to detect.

Should I use the digital values ? Or the analog values ?

Also, I tried to change the wires … the black (alarm, weird again, why not ground?) on the ground, and the brown(ground) on the INPUT pin 2.

And from this, I don’t even get anything more. 0 informations.

Do you think it’s possible I just broke my component?

A little help and explanations would be great :slight_smile: I’m kind of a noob with arduino …

Thank you a lot :slight_smile:

Edit: Maybe nothing is broken, but maybe I’m magnetic, without event touching the wires, I my fingers are close enough I trigger the system … and led blinks very fast !

Anyone ?

one more weird stuff :D

When my Mac is plugged for power, I get 4 cyclic values in the analogRead, when the mac is unplugged ... I get some workable values.

Do someone now the value of the digital "HIGH"?

Do you have the datasheet of the PIR sensor? It will contain all information needed how to connect to it.

Do someone now the value of the digital “HIGH”?

Try Serial.println(HIGH, DEC);

Show us your circuit please, and a direct web link to the sensor on the vendor’s site wouldn’t hurt either.

PS, from wiring.h:

#define HIGH 0x1
#define LOW  0x0