You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After a comparison of the CP version of this module with the data sheet, and the Arduino version of the Adafruit VCNL4010 library, I think that this module is not correctly setting the proximity measurement read rate on the chip.
The documentation for this module says that setting the frequency property is supposed to set the proximity read frequency:
The frequency of proximity measurements. Must be a value of:
FREQUENCY_3M125: 3.125 Mhz
FREQUENCY_1M5625: 1.5625 Mhz
FREQUENCY_781K25: 781.25 Khz
FREQUENCY_390K625: 390.625 Khz (default)
See the datasheet for how frequency changes the proximity detection accuracy.
However, the data sheet states that there are 8 modes for the proximity rate register:
In addition, this module is setting the PROXIMITY MODULATOR TIMING ADJUSTMENT (register 15) register at address 0x8f, not the PROXIMITY RATE REGISTER (register 2) at 0x82 (as described in the data sheet and implemented in the Arduino library). Based on this information, I’m pretty sure this is not what was intended, as the register being used changes the frequency of the square wave of the IR signal, not the number of measurements made by the sensor.
The text was updated successfully, but these errors were encountered:
After a comparison of the CP version of this module with the data sheet, and the Arduino version of the Adafruit VCNL4010 library, I think that this module is not correctly setting the proximity measurement read rate on the chip.
The documentation for this module says that setting the
frequency
property is supposed to set the proximity read frequency:However, the data sheet states that there are 8 modes for the proximity rate register:
In addition, this module is setting the PROXIMITY MODULATOR TIMING ADJUSTMENT (register 15) register at address 0x8f, not the PROXIMITY RATE REGISTER (register 2) at 0x82 (as described in the data sheet and implemented in the Arduino library). Based on this information, I’m pretty sure this is not what was intended, as the register being used changes the frequency of the square wave of the IR signal, not the number of measurements made by the sensor.
The text was updated successfully, but these errors were encountered: