Skip to content

Latest commit

 

History

History
58 lines (36 loc) · 674 Bytes

README.md

File metadata and controls

58 lines (36 loc) · 674 Bytes

tsl2561

node interface for the TSL2561 luminosity sensor

Install

$ npm install tsl2561

Usage

var tsl2561 = require('tsl2561');

var device = "/dev/i2c-1"
var address = 0x39;

var sensor = new tsl2561.Tsl2561(device, address);

var luminosity = sensor.lux();

Raspberry Pi Setup

$ sudo vi /etc/modules

Add these two lines

i2c-bcm2708 
i2c-dev
$ sudo vi /etc/modprobe.d/raspi-blacklist.conf

Comment out blacklist i2c-bcm2708

#blacklist i2c-bcm2708

Load kernel module

$ sudo modprobe i2c-bcm2708

Questions?

http://www.twitter.com/johnnysunshine