TSL2561 overexposed ?

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
Viald
Normal user
Posts: 16
Joined: 11 Jul 2018, 15:42

TSL2561 overexposed ?

#1 Post by Viald » 24 Nov 2018, 19:12

Hi.
I use a TSL2561 to measure outside lux value. The probe could be oriented directly to the sun. With a lot of sun and absolutely no cloud, the lux value drop down from ~32K to very low value and then starts increase again.
I don't know if the problem comes from the probe which is saturated or from ESPeasy algorithms.
Below a graph example.
Image 578.jpg
Image 578.jpg (101.99 KiB) Viewed 10875 times
To exclude issue from the probe, I have connected a second one to the same bus, despite the fact that the value are not exactly the same, the behaviour is the same.

My goal is to be able to know if there is enough sun to open shutters during winter.

Thanks for your help.

Viald
Normal user
Posts: 16
Joined: 11 Jul 2018, 15:42

Re: TSL2561 overexposed ?

#2 Post by Viald » 28 Nov 2018, 18:11

No idea ?

User avatar
budman1758
Normal user
Posts: 301
Joined: 15 Apr 2017, 05:13
Location: Riverside CA USA

Re: TSL2561 overexposed ?

#3 Post by budman1758 » 30 Nov 2018, 01:24

Can you provide more information on your setup? Wiring, cable lengths, ESP module and what particular version of the firmware you are using?
This might help..... ;)
"The glass is twice as big as it needs to be".

Viald
Normal user
Posts: 16
Joined: 11 Jul 2018, 15:42

Re: TSL2561 overexposed ?

#4 Post by Viald » 01 Dec 2018, 09:00

Yes, sure.
1 Wemos: https://goo.gl/nkX8v4
2 Lux sensors: https://goo.gl/2e13wB
1 Temperature sensor: Dallas 18B20

Wires are very short, no more than 8 cm, for the moment I'm just doing test
IMG_20181201_085424.jpg
IMG_20181201_085424.jpg (3.88 MiB) Viewed 10803 times
I'm currently running this release
Image 593.jpg
Image 593.jpg (110.86 KiB) Viewed 10803 times

User avatar
budman1758
Normal user
Posts: 301
Joined: 15 Apr 2017, 05:13
Location: Riverside CA USA

Re: TSL2561 overexposed ?

#5 Post by budman1758 » 01 Dec 2018, 18:57

I know that there have been problems with ESPEasy running 2 of the same I2C devices at the same time. For example if you attempt to use 2 OLED devices of the same type it will not work correctly even if the I2C address are different and they are separate tasks. This may be the problem in your case. Try using a single sensor and see what happens.

Edit. In your first post its impossible to see the time frame in your graph. Also it appears you are running on battery. Is the ESP sleeping between measurements and if so how much awake time are you allowing to read the sensor? A pic of your device settings might shed some LUX too. :)
"The glass is twice as big as it needs to be".

ao16
Normal user
Posts: 19
Joined: 03 Oct 2018, 23:51

Re: TSL2561 overexposed ?

#6 Post by ao16 » 01 Dec 2018, 19:49

Hello Viald,
I am targetting to the same application as you do - using TSL2561 for rollerblind control.
I am using 3 of them at the same I2C of a NodeMCU and additionally a BME280.
My NodeMCU is continously running from a power supply, the NodeMCU supply itself is buffered/filtered
with different capacitors from small ceramic ones to 2200uF electrolytic, no sleep of the ESP in use.

Reason why three of the TSL2561:
one is pointing to East, one to South and one to West - to determine also which rollerblinds need to be closed.

I have seen a similar behaviour as you experienced with big steps during a sunny day,
however until now I was not able to narrow down the issue because all the recent F/W's I tried until now
were not stable and stopped communicating through WiFi within few hours.
Hence my recorded meausurement values are very incomplete, I never was able to record a whole day.

Since a few days, I am using an old ESPEasyFW (22nd May 2018) on this sunlight detector NodeMCU
that seems to be a lot more stable and now I managed to record the sunlight exposition of a whole day...
however as it is winter here in the northern hemisphere I had no real direct sunlight anymore...sun elevation is too low now.

As I will hopefully get more "complete day" results now in the next time I will keep monitoring this issue.
If I get a conclusion, I will share this with you.

The displayissue that budman mentioned with more than one display is a different issue
- as the individual addressing via LCD-command is not available yet.

Definetly, three TSL2561 at the same I2C on ESPEasy are working.

What I anyhow additionally use are two pull-up resistors on I2C of about 4k7.
I am using the same TLS2561 PCBs as you, if I remember right they have built-in pull-ups
however this additional 4k7's are just for beeing to the safe side.


regards,

ao16

ao16
Normal user
Posts: 19
Joined: 03 Oct 2018, 23:51

Re: TSL2561 overexposed ?

#7 Post by ao16 » 01 Dec 2018, 19:58

just in addition, here's my setup of the TSL2561:

Image


and the setup of one of the three TSL2561:


Image
TSL2561.JPG
TSL2561.JPG (57.3 KiB) Viewed 10788 times
The values are zero as it is very dark right now ;-)
Attachments
Devices.JPG
Devices.JPG (49.04 KiB) Viewed 10788 times

MadNBG
New user
Posts: 3
Joined: 28 Oct 2018, 20:11

Re: TSL2561 overexposed ?

#8 Post by MadNBG » 06 Dec 2018, 19:18

Well, why don't you just add a thin filter? A foil, or a Glas - something that dims the sun a little little bit.
The sensor-value / curve is only a bit lower then, but you still can see your curve. And a potentially overexposure is corrected.

In my cases such adjustments do work - i only need to know, if its dark enough to power on the light. I don't care if the Sensor tells me 500 or 400.

Viald
Normal user
Posts: 16
Joined: 11 Jul 2018, 15:42

Re: TSL2561 overexposed ?

#9 Post by Viald » 07 Dec 2018, 09:49

Thank you all.

@budman1758 This is not the issue. I have the same result with one lux sensor

@oa16 No sure that it's a firmware issue. I did the same test with an official Fibaro Lux sensor (FGMS-001). And I have exactly the same behaviour. So I think that when the sensor is fully exposed to the sun, we reach the maximum of his capacity which is 36000 Lux. At this state, the sensor returns wrong value.

@MadNBG It could be a solution, we have to find a filter which is able to reduce 100 000 lux (max sun light) to 36 000 lux (max sensor) and to be sure with such strong filter we are still able to correctly measure when the sun goes down.

Ton_vN
Normal user
Posts: 300
Joined: 21 Oct 2016, 15:20
Location: Hengelo (Ov)/ NL
Contact:

Re: TSL2561 overexposed ?

#10 Post by Ton_vN » 17 Apr 2020, 16:31

Configuration: WEMOS D1Pro + ESPEasy R147
WEMOS at mains-supply.

Similar effect observed in a setup with 2*TLS2561+1*BH1750 at same I2C-bus.

1st TLS2561 looking +30 degrees east (from south) and 2nd TLS2561 looking 30 degrees west (from south).
Both of them lock at the same time when lightlevel seems to exceed approx. 25kLux
Presently each day Weather is bluesky and the pcbs all time fully exposed to light: effect is repeatable.

The BH1750 at same I2C-bus has no problem to deal with the higher lightlevels.

Somebody with an explanation & a remedy?
Last edited by Ton_vN on 17 Apr 2020, 17:06, edited 1 time in total.

TD-er
Core team member
Posts: 8643
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: TSL2561 overexposed ?

#11 Post by TD-er » 17 Apr 2020, 16:37

The latest sources of ESPEasy using this sensor (latest as in roughly 9 months ago) do have an option to "extend" the range.

When exposed in full sunlight, one of the 2 sensors (IR) is over exposed very soon.
This does change the ratio of both sensors leading to a completely incorrect value if you use the default formula as described in the datasheet.
So what the latest changes in ESPEasy do, is to gather some information on what the ratio of both sensors is and extend that range using the last known ratio (or 1:3 when unknown).
Without this extended range, the latest sources just look at the "non-IR" sensor when the IR one is saturated.
This will at least prevent the computed value to drop significantly when you exceed the 20 - 30k value.

Ton_vN
Normal user
Posts: 300
Joined: 21 Oct 2016, 15:20
Location: Hengelo (Ov)/ NL
Contact:

Re: TSL2561 overexposed ?

#12 Post by Ton_vN » 17 Apr 2020, 17:09

@TDer

Thanks for the hint & explanation!
Then remedy seems simple:
just upgrade to latest ESPEasy v2.x 'Normal' release

seersucker
Normal user
Posts: 24
Joined: 11 May 2020, 17:01

Re: TSL2561 overexposed ?

#13 Post by seersucker » 11 May 2020, 17:38

My experience with this sensor is mixed. Firstly it saturates at around 37KLux, and Esp-Easy stops outputting values. So it can't be situated in direct sunlight. For me that wasn't important as I use it to determine Sunset lux levels. But the IR saturation behaviour mentioned here shouldn't be happening, so I tried the Extended Autogain option. But at lowish light outputs, 300 Lux or so, it becomes "noisy" in this mode, with the Ratio fluctuating between 30 second samples. So neither option is satisfactory.
In short, disappointing. Time to try another sensor.

My first post here, although I have been using ESP-Easy for a couple of years now. Thanks for the great work!

From Domoticz:
overcast day, steady light conditions..jpg
overcast day, steady light conditions..jpg (20.35 KiB) Viewed 8744 times

Post Reply

Who is online

Users browsing this forum: No registered users and 28 guests