From f341cae329a7f288dad83635007e9a062ba5a1fe Mon Sep 17 00:00:00 2001 From: Seth Date: Thu, 26 Dec 2024 21:42:27 +1300 Subject: [PATCH] updated u8g2 library and set time for NZDST timezone --- sunsetClock.ino | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/sunsetClock.ino b/sunsetClock.ino index ccb1bd3..465642f 100644 --- a/sunsetClock.ino +++ b/sunsetClock.ino @@ -44,7 +44,7 @@ bool doSunsetCalcs = true; bool locationDataSet = false; //sunset setup -int tzOff = 12; //local TZ offset +int tzOff = 13; //local TZ offset bool centuryBit; //needed to get month from RTC double az, elev; //for sun location in the sky double transit, sunrise, sunset; //sun related times @@ -109,9 +109,7 @@ void connectGPS() { //need to do this everytime the GPS turns back on void setup() { //Screen setup - buf = (uint8_t *)malloc(u8g2.getBufferSize()); - u8g2.setBufferPtr(buf); - u8g2.initDisplay(); + u8g2.begin(); u8g2.clearDisplay(); u8g2.setPowerSave(0); u8g2.setFont(u8g2_font_ncenB14_tr);