tedyapo / arduino-VEML7700

Arduino driver for VEML7700 ambient light sensor
MIT License
3 stars 6 forks source link

Default ALS_INTEGRATION_100ms clips in direct sunlight #10

Open richardjlyon opened 4 years ago

richardjlyon commented 4 years ago

Hello - thanks for the great library. I noticed that, with the "out of the box"gain set at ALS_GAIN_x2, the sensor clips in direct sunlight to about 2.1 klx. The application note says:

Remark: to avoid possible saturation / overflow effects, application software should always start with low gain: ALS gain x 1/8 or gain 1/4. ALS gain x 2 shows the highest resolution and should only be used with very low illumination values, e.g. if sensor is placed below a very “dark” cover allowing only low light levels reaching the photodiode. (page 3)

Might be worth noting in the README that the device initialises for very low illumination, and to direct the user to the technical note and the setGain() command.