Intel® Makers
Intel® Edison, Intel® Joule™, Intel® Curie™, Intel® Galileo
Announcements
Welcome - This is a Peer-to-Peer Forum only. Intel has discontinued these products but you may find support from other customers on this Forum
9873 Discussions

Intel edison breakout board - pir sensor (GPIO connect)

sok
Beginner
1,095 Views

How can i connect the PIR montion sensor to intel edison breakout board?

(1) connect sensor, intel edison breakout board

I used onoff source of node.js modules

----------------------------------------------------------------

var sleep = require('sleep');

var Gpio = require('onoff').Gpio,

pir = new Gpio(165, 'in', 'both');

pir.watch(function(err, value) {

// sleep.msleep(100);

if (err) exit();

console.log('Intruder detected : '+ value);

});

------------------------------------------------------------------

I received invalid result

Please advise me what to do!!

0 Kudos
2 Replies
idata
Community Manager
210 Views

Hi Steveok,

 

 

Thank you for contacting us.

 

 

I just tested your code with the PIR motion sensor that we have here, and it works fine. The difference is that I'm using the Arduino Breakout board because it supports 5V in its GPIOs.

 

 

So, I think that's the issue that you are having, if you are connecting your sensor to 5V it will generate and output signal of 5V, and it can damage your board, because it supports to 1.8V.

 

 

Personally, my recommendation is to use level shifter to avoid this issue. If the problem persist, please try it on another pin.

 

 

I hope you find this helpful.

 

 

Regards,

 

Leonardo R.
idata
Community Manager
210 Views

Hi Steveok,

 

 

Do you have any updates about this? Did it work?

 

 

Regards,

 

Leonardo R.
Reply