Hi there!
I have one of this ePIR sensors:
There is not available a datasheet, so i cannot know how to wire it.
What i only know is that is should be powered by 3.3V. But anythng else.
Here there is an example of code:
http://news.jeelabs.org/2009/03/29/reading-out-an-epir-motion-sensor/
but it uses other devide (JeeNode).
So, any idea how to wire it to arduino? Any example?
Thanks!!
There is a datasheet linked from the Sparkfun page, just a matter of feeding it 3.3 volts and hooking its digital output to an arduino digital input at its most basic I'd say.
The data sheet is there.
Ive had it working within a few minutes.
I googled for a couple of examples like:
http://news.jeelabs.org/2009/03/29/reading-out-an-epir-motion-sensor/
Take note of the resistor needed to put it in serial mode.
and the ldr if you need the onboard light sensor function.
Look at the diagram on page 56 for the Serial interface circuit diagram.
Gordon
Thanks to both!!
Thanks for the datasheet! it provide a lot of information. yes, i saw the example, but there was an scheme of how to wire it. I will try it.
Thanks!
Hey I'm not sure if you were aiming at the Hardware Mode, but I'm trying to setup the circuit for Serial Mode and running into problems.
I've got the sample circuit setup from Figure 13 of the pdf (http://www.sparkfun.com/datasheets/Sensors/Proximity/SEN-09587-PS0284.pdf )... I noticed the figure shows 100k for R1, whereas the text says 10k... :-\ all I have is 10k so that's what I"m using...
To poll the serial interface, I'm using the code from JeeLabs (http://news.jeelabs.org/2009/03/29/reading-out-an-epir-motion-sensor/ ). This isn't returning anything other than the hard-coded println("\n[ePIR]") in Serial Monitor.
#include <NewSoftSerial.h>
NewSoftSerial ss(1,0);
static char getch() {
while (!ss.available())
;
return ss.read();
}
void setup() {
Serial.begin(57600);
Serial.println("\n[EPIR]");
ss.begin(9600);
}
void loop() {
ss.print('a');
Serial.print(getch());
ss.print('b');
Serial.println((uint8_t) getch(), DEC);
delay(1000);
}
Just wondering if anyone else is having the same problems or whether I'm just a twit.
Thanks,
Brett
Nevermind! I'm a dimwit! If you notice I was trying to use pins 0 and 1 for serial communication! Bad! Simply switching the pins to 2 and 3 brought the serial communications back!
Hi,
For the moment i wired it without arduino, by the use of 100K pots, and it runs perfectly. Next weekend i will try to connect it to arduino.
Now i will try again by the use of a 10K resitance such as you did in order to see the differences!
Thanks for all your comments!
system
December 19, 2010, 3:24pm
8
Connection to pin 6 is necessary for normal work of sensor ?