Characteristic Locus
Inheritance System.Object > Apds9960
Inherited Members System.Object.ToString() System.Object.Equals(System.Object) System.Object.Equals(System.Object, System.Object) System.Object.ReferenceEquals(System.Object, System.Object) System.Object.GetHashCode() System.Object.GetType() System.Object.MemberwiseClone()
Namespace Meadow.Foundation.Sensors.Motion
Assembly APDS9960.dll

Syntax

public class Apds9960

Constructors

Apds9960(IIODevice, II2cBus, IPin, Byte)

Create a new instance of the APDS9960 communicating over the I2C interface.

Declaration
public Apds9960(IIODevice device, II2cBus i2cBus, IPin interruptPin, byte address = 57)

Parameters

Type Name Description
IIODevice device
II2cBus i2cBus

SI2C bus object

IPin interruptPin
System.Byte address

Address of the I2C sensor

Methods

DisableGestureSensor()

Declaration
public void DisableGestureSensor()

DisableLightSensor()

Declaration
public void DisableLightSensor()

DisableProximitySensor()

Declaration
public void DisableProximitySensor()

EnableGestureSensor(Boolean)

Declaration
public bool EnableGestureSensor(bool interrupts)

Parameters

Type Name Description
System.Boolean interrupts

Returns

Type Description
System.Boolean

EnableLightSensor(Boolean)

Declaration
public void EnableLightSensor(bool interrupts)

Parameters

Type Name Description
System.Boolean interrupts

EnablePower(Boolean)

Declaration
public void EnablePower(bool enable)

Parameters

Type Name Description
System.Boolean enable

EnableProximitySensor(Boolean)

Declaration
public void EnableProximitySensor(bool interrupts)

Parameters

Type Name Description
System.Boolean interrupts

GetLEDDrive()

Declaration
public byte GetLEDDrive()

Returns

Type Description
System.Byte

GetProximityGain()

Declaration
public byte GetProximityGain()

Returns

Type Description
System.Byte

GetProxIntHighThresh()

Declaration
public byte GetProxIntHighThresh()

Returns

Type Description
System.Byte

GetProxIntLowThresh()

Declaration
public byte GetProxIntLowThresh()

Returns

Type Description
System.Byte

IsGestureAvailable()

Declaration
public bool IsGestureAvailable()

Returns

Type Description
System.Boolean

ReadAmbientLight()

Declaration
public ushort ReadAmbientLight()

Returns

Type Description
System.UInt16

ReadBlueLight()

Declaration
public ushort ReadBlueLight()

Returns

Type Description
System.UInt16

ReadGesture()

Declaration
public Apds9960.Direction ReadGesture()

Returns

Type Description
Apds9960.Direction

ReadGreenLight()

Declaration
public ushort ReadGreenLight()

Returns

Type Description
System.UInt16

ReadProximity()

Declaration
public byte ReadProximity()

Returns

Type Description
System.Byte

ReadRedLight()

Declaration
public ushort ReadRedLight()

Returns

Type Description
System.UInt16

SetLEDDrive(Byte)

Declaration
public bool SetLEDDrive(byte drive)

Parameters

Type Name Description
System.Byte drive

Returns

Type Description
System.Boolean

SetProximityGain(Byte)

Declaration
public void SetProximityGain(byte drive)

Parameters

Type Name Description
System.Byte drive

SetProxIntHighThresh(Byte)

Declaration
public void SetProxIntHighThresh(byte threshold)

Parameters

Type Name Description
System.Byte threshold

SetProxIntLowThresh(Byte)

Declaration
public void SetProxIntLowThresh(byte threshold)

Parameters

Type Name Description
System.Byte threshold