Skip to content
This repository has been archived by the owner on May 21, 2024. It is now read-only.

Commit

Permalink
documentation update
Browse files Browse the repository at this point in the history
  • Loading branch information
circuitdb committed Jun 19, 2015
1 parent dd0ec12 commit 27dc03d
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,37 @@
# pimatic-bh1750
Pimatic support for the bh1750 light intensity sensor

### Drivers

I2C drivers need to be loaded in order to create the connection between the physical sensor and the rPI.
You can load them from the terminal (or from the /etc/modules script).

sudo modprobe i2c_dev
sudo modprobe i2c_bcm2708

You might also need to uncomment the following line in /boot/config.txt

dtparam=i2c_arm=on

### Example config

Add the plugin to the plugin section:

```json
{
"plugin": "bh1750"
}
```

Then add a sensor for your device to the devices section:

```json
{
"id": "my-sensor",
"name": "bh1750 example",
"class": "BH1750Sensor",
"device": "/dev/i2c-0",
"address": "0x23",
"interval": 10000
}
```

0 comments on commit 27dc03d

Please sign in to comment.