Reading ONLY IR light from light sensor (non-visible)

Hi,



I’m testing a Digital Light sensor TSL2561 with an Arduino.

Using the example code and library from Seeed (http://wiki.seeedstudio.com/Grove-Digital_Light_Sensor/), I get lux values which correspondent to my room: dark or in bright light. Good.



Now, I only want to detect IR light and not any visible light.

How do I do that? :?:



When in a dark room, using a IR lamp(torch) I see the lux value rise. But this same value also rises when I move the sensor in sunlight, so the sensor registers both visible and IR light.

I looked at the only function suplied with the example (for Arduino) which is readVisibleLux(). This calls </s>calculateLux(0,0,0)<e> , which is defined as </s>unsigned int iGain, unsigned int tInt,int iType)<e> .

I attached the example code and lib.



How should I set the sensor to only register (invisible) IR light? I tried several values for those parameters, but non gets me to what I want.



Thanks in advance.



Regards,



Cyril
Digital_Light_TSL2561 example code and lib.zip (4.78 KB)

Hi:

TSL256X has two photodiodes. One of the photodiodes(CH0) is sentive to both visible and infrared light, while the second photodiode (CH1) is sensitive primarily to infrared light.CH1 digital output is used to compensate for the effect of the infrared component of light on the CH0 digital output. LUX is calculated by using CH0 and CH1. We can only get CH0 and CH1’s data, and we cann’t register IR light only according to TSL2561’ datasheet.