python-tsl2591
python-tsl2591 copied to clipboard
integration_time plus **1** second (fixed) blocked reliable measures
https://github.com/maxlklaxl/python-tsl2591/blob/290ef844d8a939eb6674f241f0b17af8667764c0/tsl2591/read_tsl.py#L158
Typo here: () missing time.sleep(0.120self.integration_time+1) # takes minimal 1 second + 0.120self.integration_time
You want: time.sleep(0.120*(self.integration_time+1))
Fastest working is: time.sleep(0.105+0.100*self.integration)
Seconded! I use a local copy of this helpful repository and fixed it there but never reported here, sorry...
The initial clue for that comes form the official Adafruit driver and datasheet: https://github.com/adafruit/Adafruit_TSL2591_Library/blob/master/Adafruit_TSL2591.cpp#L316-L320 in combination with https://github.com/adafruit/Adafruit_TSL2591_Library/blob/master/Adafruit_TSL2591.h#L84