@@ -168,7 +168,7 @@ void DisplayWeather() { // 2.9" e-paper display is 296x128 resolutio
168168 String MidTime = " 09:00" + String ((Units == " M" ? " " : " a" ));
169169 String FinishTime = " 10:00" + String ((Units == " M" ? " " : " a" ));
170170 do {
171- String Ftime = ConvertUnixTime (WxForecast[Forecast].Dt ).substring (0 , (Units == " M" ? 5 : 6 ));
171+ String Ftime = ConvertUnixTime (WxForecast[Forecast].Dt + WxForecast[Forecast]. Timezone ).substring (0 , (Units == " M" ? 5 : 6 ));
172172 if (Ftime == StartTime || Ftime == MidTime || Ftime == FinishTime) {
173173 DisplayForecastWeather (18 , 104 , Forecast, Dposition, 57 ); // x,y coordinates, forecast number, position, spacing width
174174 Dposition++;
@@ -216,9 +216,9 @@ void DisplayAstronomySection(int x, int y) {
216216 display.drawRect (x, y + 13 , 126 , 51 , GxEPD_BLACK);
217217 u8g2Fonts.setFont (u8g2_font_helvB08_tf);
218218 SunRise (x + 64 , y + 23 );
219- drawString (x + 80 , y + 20 , ConvertUnixTime (WxConditions[0 ].Sunrise ).substring (0 , (Units == " M" ? 5 : 7 )), LEFT);
219+ drawString (x + 80 , y + 20 , ConvertUnixTime (WxConditions[0 ].Sunrise + WxConditions[ 0 ]. Timezone ).substring (0 , (Units == " M" ? 5 : 7 )), LEFT);
220220 SunSet (x + 64 , y + 38 );
221- drawString (x + 80 , y + 35 , ConvertUnixTime (WxConditions[0 ].Sunset ).substring (0 , (Units == " M" ? 5 : 7 )), LEFT);
221+ drawString (x + 80 , y + 35 , ConvertUnixTime (WxConditions[0 ].Sunset + WxConditions[ 0 ]. Timezone ).substring (0 , (Units == " M" ? 5 : 7 )), LEFT);
222222 time_t now = time (NULL );
223223 struct tm * now_utc = gmtime (&now);
224224 const int day_utc = now_utc->tm_mday ;
@@ -392,8 +392,8 @@ void GetHighsandLows() {
392392 String StartTime = " 08:00" + String ((Units == " M" ? " " : " a" ));
393393 String FinishTime = " 10:00" + String ((Units == " M" ? " " : " a" ));
394394 for (int r = 0 ; r < max_readings; r++) {
395- if (ConvertUnixTime (WxForecast[r].Dt ).substring (0 , (Units == " M" ? 5 : 6 )) >= StartTime && ConvertUnixTime (WxForecast[r].Dt ).substring (0 , (Units == " M" ? 5 : 6 )) <= FinishTime) { // found first period in day
396- HLReadings[Day].Time = ConvertUnixTime (WxForecast[r].Dt ).substring (0 , (Units == " M" ? 5 : 6 ));
395+ if (ConvertUnixTime (WxForecast[r].Dt + WxForecast[r]. Timezone ).substring (0 , (Units == " M" ? 5 : 6 )) >= StartTime && ConvertUnixTime (WxForecast[r].Dt + WxForecast[r]. Timezone ).substring (0 , (Units == " M" ? 5 : 6 )) <= FinishTime) { // found first period in day
396+ HLReadings[Day].Time = ConvertUnixTime (WxForecast[r].Dt + WxForecast[r]. Timezone ).substring (0 , (Units == " M" ? 5 : 6 ));
397397 for (int InDay = 0 ; InDay < 8 ; InDay++) { // 00:00 to 21:00 is 8 readings
398398 if (r + InDay < max_readings) {
399399 if (WxForecast[r + InDay].High > HLReadings[Day].High ) {
0 commit comments