Luminosity sensor by Texas Advanced Optoelectronic Solutions Inc.. Device combines one broadband photodiode (visible plus infrared) and one infrared-responding photodiode. Sets Gain x1 and 402mS as default.

Dependents:   MusicBoxForFathersDay FTHR_SensorHub Affich_Lum_Moist Projetv0 ... more

Revision:
4:05d322353720
Parent:
3:d60d8198d76d
Child:
5:5b1b625fda6f
--- a/TSL2561.cpp	Tue Feb 20 10:49:43 2018 +0000
+++ b/TSL2561.cpp	Tue Feb 20 10:52:41 2018 +0000
@@ -140,16 +140,6 @@
 }
 
 /////////////// ID ////////////////////////////////////////
-#if 0
-uint16_t TSL2561::read_ID()
-{
-    dt[0] = CMD_SINGLE + TSL2561_ID;
-    _i2c.write((int)TSL2561_addr, (char *)dt, 1, true);
-    _i2c.read(TSL2561_addr, (char *)dt, 1, false);
-    id_number = dt[0] << 8 | dt[1];
-    return id_number;
-}
-#else
 uint8_t TSL2561::read_ID()
 {
     dt[0] = CMD_SINGLE + TSL2561_ID;
@@ -158,7 +148,6 @@
     id_number = dt[0];
     return id_number;
 }
-#endif
 
 uint8_t TSL2561::who_am_i()
 {