Remarks

OLED128x32Wing
Status Status badge: working
Source code GitHub
Datasheet(s) GitHub
NuGet package NuGet Gallery for OLED128x32Wing

Code Example

MicroGraphics graphics;

public MeadowApp()
{
    Console.WriteLine("Initializing ...");
    var i2cBus = Device.CreateI2cBus(I2cBusSpeed.FastPlus);

    var oledWing = new OLED128x32Wing(i2cBus, Device, Device.Pins.D11, Device.Pins.D10, Device.Pins.D09);

    graphics = new MicroGraphics(oledWing.Display);
    graphics.CurrentFont = new Font12x16();

    oledWing.ButtonA.Clicked += (sender, e) => UpdateDisplay("A pressed");
    oledWing.ButtonB.Clicked += (sender, e) => UpdateDisplay("B pressed");
    oledWing.ButtonC.Clicked += (sender, e) => UpdateDisplay("C pressed");
}

void UpdateDisplay(string message)
{
    graphics.Clear();
    graphics.DrawText(0, 8, message);
    graphics.Show();
}

Sample project(s) available on GitHub

Characteristic Locus
Inheritance System.Object > OLED128x32Wing
Namespace Meadow.Foundation.FeatherWings
Assembly OLED128x32.dll

Syntax

public class OLED128x32Wing : object

Constructors

OLED128x32Wing(II2cBus, IDigitalInputController, IPin, IPin, IPin)

Declaration
public OLED128x32Wing(II2cBus i2cBus, IDigitalInputController device, IPin pinA, IPin pinB, IPin pinC)

Parameters

Type Name Description
II2cBus i2cBus
IDigitalInputController device
IPin pinA
IPin pinB
IPin pinC

OLED128x32Wing(II2cBus, IDigitalInputPort, IDigitalInputPort, IDigitalInputPort)

Declaration
public OLED128x32Wing(II2cBus i2cBus, IDigitalInputPort portA, IDigitalInputPort portB, IDigitalInputPort portC)

Parameters

Type Name Description
II2cBus i2cBus
IDigitalInputPort portA
IDigitalInputPort portB
IDigitalInputPort portC

Properties

ButtonA

Declaration
public PushButton ButtonA { get; protected set; }

Property Value

Type Description
PushButton

ButtonB

Declaration
public PushButton ButtonB { get; protected set; }

Property Value

Type Description
PushButton

ButtonC

Declaration
public PushButton ButtonC { get; protected set; }

Property Value

Type Description
PushButton

Display

Declaration
public Ssd1306 Display { get; protected set; }

Property Value

Type Description
Ssd1306