Remarks

Temt6000
Status
Source code GitHub
NuGet package

The TEMT6000 is an analog ambient light sensor.

Code Example

public class MeadowApp : App<F7Micro, MeadowApp>
{
    Temt6000 sensor;

    public MeadowApp()
    {
        sensor = new Temt6000(Device, Device.Pins.A03);

        Task.Run(async () =>
        {
            while(true)
            {
                Console.WriteLine($"Voltage: {await sensor.GetVoltage()}");
                await Task.Delay(500);
            }
        });
    }
}

Sample projects available on GitHub

Wiring Example

To wire a Temt6000 to your Meadow board, connect the following:

Temt6000 Meadow Pin
GND GND
SIG A03
VCC 3V3

It should look like the following diagram:

Characteristic Locus
Inheritance System.Object > Temt6000
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.Light
Assembly Temt6000.dll

Syntax

public class Temt6000

Constructors

Temt6000(IIODevice, IPin)

Create a new light sensor object using a static reference voltage.

Declaration
public Temt6000(IIODevice device, IPin pin)

Parameters

Type Name Description
IIODevice device
IPin pin

AnalogChannel connected to the sensor.

Methods

GetVoltage()

Voltage being output by the sensor.

Declaration
public Task<float> GetVoltage()

Returns

Type Description
System.Threading.Tasks.Task<System.Single>