Code Monkey home page Code Monkey logo

homebridge-infrared-motion-sesnor-gpio's Introduction

homebridge-contact-sensor

This Homebridge plugin enables you to control a infrared motion sensor switch.

Setup

  1. Wire a infrared motion senor to your Raspberry Pi.

  1. Install this plugin
npm i -g homebridge-gpio-motion-sensor
  1. Rename the sample-config.json to config.json and integrate your sensor in the accessories array. The pins of the Raspberry Pi require root rights to control them. Therefore you have to save your config file not in your users directory. Put it under /root/.homebridge/config.json. If you are already running homekit with other apps integrate the accessories into your config.json and move your config file to the path above.

Accessory JSON config looks like:

{
    "accessory": "MotionSensor",
    "name": "MotionSensor1",
    "pin": 2
}

homebridge-infrared-motion-sesnor-gpio's People

Contributors

killerameise avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

homebridge-infrared-motion-sesnor-gpio's Issues

Documentation Issue

For anyone having issues:

The ReadMe shows the PIR pin connected to PIN 3 (GPIO 2), however the correct PIN value in the config.json for that case would be 3 instead of 2. It uses the PIN number, not the GPIO number as the input.

Also PIN 3 (GPIO 2) is used for I2C, PIN 7 (GPIO 4) would be a better choice.

Change devices status when receive remote IR

Hi, do you know if with this i could change status of devices like tv, for example, if receive IR power HEX, it change tv status on homekit from turned on to turned off.. This would be awesome...

Waiting time before new state change

Hello,
I've installed successfully you plugin, thanks, it's great!!
Could you maybe add a possibility to set a waiting time in the config, so that when it's activated, it cannot be activated again during xx seconds (like 30 seconds for example). To be a bit similar to what Eve motion does.

Thanks

Error: Could not locate the bindings file.

Having some problems getting this plugin to run.

Tried installing globally, locally, logged in as root, using sudo, without sudo, but the error remains the same. My other plugin (homebridge-telldus) works just nicely.

When starting homebridge (whether standard user, root or sudo) I get the below error. Any idea?

[2017-12-28 19:07:58] ====================
[2017-12-28 19:07:58] ERROR LOADING PLUGIN homebridge-gpio-motion-sensor:
[2017-12-28 19:07:58] Error: Could not locate the bindings file. Tried:
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/build/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/build/Debug/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/build/Release/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/out/Debug/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/Debug/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/out/Release/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/Release/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/build/default/epoll.node
→ /usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/compiled/9.3.0/linux/arm/epoll.node
at bindings (/usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/bindings/bindings.js:88:9)
at Object. (/usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/epoll/epoll.js:1:99)
at Module._compile (module.js:660:30)
at Object.Module._extensions..js (module.js:671:10)
at Module.load (module.js:573:32)
at tryModuleLoad (module.js:513:12)
at Function.Module._load (module.js:505:3)
at Module.require (module.js:604:17)
at require (internal/module.js:11:18)
at Object. (/usr/lib/node_modules/homebridge-gpio-motion-sensor/node_modules/rpi-gpio/rpi-gpio.js:6:20)
[2017-12-28 19:07:58] ====================

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.