[Issue #12] - Adding config options for configuring the pins used for SDA/SCL for the display
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/tag/woodpecker Pipeline was successful

This commit is contained in:
2026-09-09 14:15:35 -04:00
parent 8b4167f7cc
commit 52530ab2ff
2 changed files with 5 additions and 1 deletions
+4
View File
@@ -2,6 +2,10 @@
WIFI_SSID = "YourSSID" # Set this to your Wi-Fi network name WIFI_SSID = "YourSSID" # Set this to your Wi-Fi network name
WIFI_PASSWORD = "YourPassword" # Set this to your Wi-Fi network password WIFI_PASSWORD = "YourPassword" # Set this to your Wi-Fi network password
# Display Settings
DISPLAY_SDA_PIN = 4 # Default SDA pin is GP4
DISPLAY_SCL_PIN = 5 # Default SCL pin is GP5
# Time settings # Time settings
USE_24_HOUR = False # Set this to True for 24-hour time (no AM/PM) USE_24_HOUR = False # Set this to True for 24-hour time (no AM/PM)
UTC_OFFSET = -5 # Set this to your desired NTP server UTC_OFFSET = -5 # Set this to your desired NTP server
+1 -1
View File
@@ -15,7 +15,7 @@ except ImportError:
time.sleep(2) time.sleep(2)
# --- Hardware Setup --- # --- Hardware Setup ---
i2c = I2C(0, sda=Pin(16), scl=Pin(17), freq=400000) i2c = I2C(0, sda=Pin(Config.DISPLAY_SDA_PIN), scl=Pin(Config.DISPLAY_SCL_PIN), freq=400000)
oled = ssd1306.SSD1306_I2C(128, 64, i2c) oled = ssd1306.SSD1306_I2C(128, 64, i2c)