Current version of the library returns 0 in event.light in case of saturation. As a value of 0 could be a valid value in absolute darkness (tested by me) it is better to return a value > 65535 to report saturation and return false from getEvent in that case!
This change request returns 65536 (1 more than max possible value) and false from getEvent in case of saturation.
Successfully tested in my own application and backward compatible.
As event.light is declared as a float in Adafruit_Sensor_ESP.h a value of 65536 is a valid value and should not crash existing applications of the library.
As getEvent was returning always true the change should not crash existing applications of the library.
Current version of the library returns 0 in event.light in case of saturation. As a value of 0 could be a valid value in absolute darkness (tested by me) it is better to return a value > 65535 to report saturation and return false from getEvent in that case!
This change request returns 65536 (1 more than max possible value) and false from getEvent in case of saturation.
Successfully tested in my own application and backward compatible.