Meadow.Foundation.Displays.Ssd1327
Ssd1327 | |
---|---|
Status | |
Source code | GitHub |
Datasheet(s) | GitHub |
NuGet package |
Code Example
MicroGraphics graphics;
public override Task Initialize()
{
Resolver.Log.Info("Initialize display...");
var spiBus = Device.CreateSpiBus();
var display = new Ssd1327(spiBus, Device.Pins.D02, Device.Pins.D01, Device.Pins.D00);
display.SetContrast(60);
graphics = new MicroGraphics(display);
graphics.CurrentFont = new Font8x12();
return base.Initialize();
}
public override Task Run()
{
graphics.Clear();
for (int i = 10; i > 0; i--)
{ //iterate across different brightnesses
graphics.DrawText(0, i * 11, "SSD1327", Color.FromRgb(i * 0.1, i * 0.1, i * 0.1));
}
graphics.Show();
return base.Run();
}
Sample project(s) available on GitHub
Wiring Example
To wire a Ssd1327 to your Meadow board, connect the following:
Ssd1327 | Meadow Pin |
---|---|
GND | GND |
VCC | 3V3 |
SCL | SCK |
SDA | COPI |
RESET | D00 |
DC | D01 |
CS | D02 |
It should look like the following diagram: