From 29ed25cd5186b78156921bfe7e266f6fc8575afd Mon Sep 17 00:00:00 2001 From: Nicu Hodos Date: Sat, 9 May 2020 12:21:02 +0200 Subject: [PATCH] esp_clock: set brightness --- esp_clock.ino | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/esp_clock.ino b/esp_clock.ino index ab9330e..a00eee0 100644 --- a/esp_clock.ino +++ b/esp_clock.ino @@ -29,14 +29,16 @@ #include // Support for the Backpack FeatherWing #include // Adafruit's graphics library -#define VBATPIN 9 // Pin to read battery voltage - //########################################################################## // Globals //########################################################################## +#define STASSID "vulturul" +#define STAPSK "***REMOVED***" + #define TIME_24_HOUR true #define DISPLAY_ADDRESS 0x70 +#define BRIGHTNESS 7 // Create display object Adafruit_7segment clockDisplay = Adafruit_7segment(); @@ -49,9 +51,6 @@ int tzOffset = +2; // Time zone offset (-4 = US Eastern time) bool blinkColon = false; // Track colon status to blink once/sec int status = WL_IDLE_STATUS; -#define STASSID "vulturul" -#define STAPSK "***REMOVED***" - unsigned int localPort = 2390; // Local port to listen for UDP packets IPAddress timeServer(129,6,15,28); // time.nist.gov NTP server const int NTP_PACKET_SIZE = 48; // NTP time stamp is in the first 48 bytes @@ -137,6 +136,7 @@ void setup() { // Set up the display. clockDisplay.begin(DISPLAY_ADDRESS); + clockDisplay.setBrightness(BRIGHTNESS); // Attempt to conect to the WiFi network. Serial.println("Connecting to WiFi netowrk.");