#include <Wire.h>
#include "SH1106Wire.h"
// Define the OLED display address (default is 0x3C for SH1106)
#define OLED_ADDRESS 0x3C
// Define the OLED display dimensions (128x64 for most SH1106)
#define OLED_WIDTH 128
#define OLED_HEIGHT 64
// Create an instance of the SH1106Wire class
SH1106Wire display(OLED_ADDRESS, SDA, SCL);
void setup() {
// Initialize the OLED display
display.init();
display.flipScreenVertically(); // Flip if needed, depending on your OLED's orientation
// Clear the display
display.clear();
// Set the text size
display.setFont(ArialMT_Plain_10);
// Set the display contrast (optional)
display.setContrast(255); // Adjust as needed
// Display some text
display.drawString(0, 0, "Hello, OLED!");
// Update the display
display.display();
}
void loop() {
// Nothing in loop for this example
}