Remarks

Max44009
Status
Source code GitHub
NuGet package

The Max44009 is an analog ambient light sensor.

Code Example

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

    public MeadowApp()
    {
        var bus = Device.CreateI2cBus();
        sensor = new Max44009(bus);

        while (true)
        {
            Thread.Sleep(1000);

            Console.WriteLine($"Lux: {sensor.GetIlluminance()}");
        }
    }
}

Sample projects available on GitHub

Wiring Example

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

Max44009 Meadow Pin
SCL D08
SDA D07
GND GND
VCC 3V3

It should look like the following diagram:

Characteristic Locus
Inheritance System.Object > Max44009
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 Max44009.dll

Syntax

public class Max44009

Constructors

Max44009(II2cBus, Byte)

Declaration
public Max44009(II2cBus i2cBus, byte address = 74)

Parameters

Type Name Description
II2cBus i2cBus
System.Byte address

Fields

DefaultI2cAddress

Valid addresses for the sensor.

Declaration
public static byte DefaultI2cAddress

Field Value

Type Description
System.Byte

Methods

GetIlluminance()

Declaration
public double GetIlluminance()

Returns

Type Description
System.Double