-
Notifications
You must be signed in to change notification settings - Fork 2
readWord()
This function is used to communicate directly with the VCNL4010 and read a word (2 bytes) from a specific address. It is exposed as a public function call, but all of the normal functionality of the VCNL4010 is accessible via the other calls in the library and this function is not normally required.
It is intended for advanced use where calls to I2C are to be made directly.
VCNL4010 Sensor(); // Instantiate class
...
while(!Sensor.begin()); // loop until initialized
uint16_t returnValue = readWord(VCNL4010_AMBIENT_LIGHT_REG);
Serial.print("The raw value of the Ambient light register is ");
Serial.print(returnValue);
Serial.println(".");
Overview
Installation
Class Instantiation
begin()
setProximityHz()
setLEDmA()
setProximityFreq()
setAmbientLight()
setAmbientContinuous()
setProximityContinuous()
setInterrupt()
getAmbientLight()
getProximity()
getInterrupt()
clearInterrupt()
readByte() (advanced)
readWord() (advanced)
writeByte() (advanced)
-none-
CheckDistance.ino
DisplayMeasurements.ino
RegressionTests.ino
WakeOnInterrupt.ino