Giter Club home page Giter Club logo

homebridge-bh1750's Introduction

homebridge-hc-sr501

Homebridge plugin for the bh1750 light sensor on a Raspberry Pi

Installation of other plugins

I assume that this Guide was followed, so your homebridge config file is under /var/homebridge and you used the systemd version. Create a folder called other_plugins in that hombridge folder and checkout this repository inside that newly created folder.

Now you want to alter the file you placed under /etc/default/homebridge accordingly

# Defaults / Configuration options for homebridge
# The following settings tells homebridge where to find the config.json file an$
#HOMEBRIDGE_OPTS=-U /var/homebridge
HOMEBRIDGE_OPTS=-U /var/homebridge -P /var/homebridge/other_plugins -D

# If you uncomment the following line, homebridge will log more
# You can display this via systemd's journalctl: journalctl -f -u homebridge
#DEBUG=*

You might need to run a systemctl command to update the config file. The system should inform you about the specific comand if you enter sudo service hombridge stop. After you have executed the suggested command you'll want to enter sudo service hombridge restart. Homebridge should now be aware of any additional plugins within the /var/hombridge/other_plugins folder.

Now run the following code to install the dependencies.

cd /var/hombridge/other_plugins/homebridge-bh1750
npm i

You can now add the configuration to your config.json

Wiring

You might want to google BH1750 and raspberry pi together. There are plenty of tutorials on how to wire these. You can see this guide here for instance.

Configuration

This is an example configuration file

{
    "accessory" : "bh1750",
    "name" : "BH1750FVI Light Sensor",
    "serial" : "6B4A3603-1EC9-4965-8A3F-F84887C2C90C",
    "model" : "BH1750FVI",
    "autoRefresh" : 300
}
Key Description
accessory Required. Has to be "bh1750"
name Required. The name of this accessory. This will appear in your homekit app
serial Optional. The serial number for this accessory.
model Optional. The model for this accessory.
autoRefresh Optional. The number of seconds until a new value is read from the sensor and pushed to HomeKit.

homebridge-bh1750's People

Contributors

lucavb avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

shidevil

homebridge-bh1750's Issues

Readme?

Hi Luca,
I have a BH1750 around here and like the idea of including it to my homebridge setup. Do you see a chance of providing a minimal readme for your plugin?
I guess that just installing the plugin won't do the job. For example, I was wondering where I'd specify the GPIO that my sensor is connected to, and so on...
Thanks in advance
Michael

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.