Removed alerts, since it's buggy
This commit is contained in:
@@ -45,7 +45,6 @@ See more at https://blog.squix.org
|
|||||||
#include <WundergroundConditions.h>
|
#include <WundergroundConditions.h>
|
||||||
#include <WundergroundForecast.h>
|
#include <WundergroundForecast.h>
|
||||||
#include <WundergroundAstronomy.h>
|
#include <WundergroundAstronomy.h>
|
||||||
#include <WundergroundAlerts.h>
|
|
||||||
#include <MiniGrafx.h>
|
#include <MiniGrafx.h>
|
||||||
#include <Carousel.h>
|
#include <Carousel.h>
|
||||||
#include <ILI9341_SPI.h>
|
#include <ILI9341_SPI.h>
|
||||||
@@ -64,7 +63,6 @@ See more at https://blog.squix.org
|
|||||||
#define MINI_BLUE 3
|
#define MINI_BLUE 3
|
||||||
|
|
||||||
#define MAX_FORECASTS 12
|
#define MAX_FORECASTS 12
|
||||||
#define MAX_ALERTS 1
|
|
||||||
|
|
||||||
// defines the colors usable in the paletted 16 color frame buffer
|
// defines the colors usable in the paletted 16 color frame buffer
|
||||||
uint16_t palette[] = {ILI9341_BLACK, // 0
|
uint16_t palette[] = {ILI9341_BLACK, // 0
|
||||||
@@ -98,7 +96,6 @@ Carousel carousel(&gfx, 0, 0, 240, 100);
|
|||||||
WGConditions conditions;
|
WGConditions conditions;
|
||||||
WGForecast forecasts[MAX_FORECASTS];
|
WGForecast forecasts[MAX_FORECASTS];
|
||||||
WGAstronomy astronomy;
|
WGAstronomy astronomy;
|
||||||
WGAlert alerts[MAX_ALERTS];
|
|
||||||
|
|
||||||
// Setup simpleDSTadjust Library rules
|
// Setup simpleDSTadjust Library rules
|
||||||
simpleDSTadjust dstAdjusted(StartRule, EndRule);
|
simpleDSTadjust dstAdjusted(StartRule, EndRule);
|
||||||
@@ -110,7 +107,6 @@ void drawCurrentWeather();
|
|||||||
void drawForecast();
|
void drawForecast();
|
||||||
void drawForecastDetail(uint16_t x, uint16_t y, uint8_t dayIndex);
|
void drawForecastDetail(uint16_t x, uint16_t y, uint8_t dayIndex);
|
||||||
void drawAstronomy();
|
void drawAstronomy();
|
||||||
void drawAlert();
|
|
||||||
void drawCurrentWeatherDetail();
|
void drawCurrentWeatherDetail();
|
||||||
void drawLabelValue(uint8_t line, String label, String value);
|
void drawLabelValue(uint8_t line, String label, String value);
|
||||||
void drawForecastTable(uint8_t start);
|
void drawForecastTable(uint8_t start);
|
||||||
@@ -354,12 +350,6 @@ void updateData() {
|
|||||||
astronomyClient = nullptr;
|
astronomyClient = nullptr;
|
||||||
moonAgeImage = String((char) (65 + 26 * (((15 + astronomy.moonAge.toInt()) % 30) / 30.0)));
|
moonAgeImage = String((char) (65 + 26 * (((15 + astronomy.moonAge.toInt()) % 30) / 30.0)));
|
||||||
|
|
||||||
drawProgress(90, "Updating alerts...");
|
|
||||||
WundergroundAlerts *alertClient = new WundergroundAlerts();
|
|
||||||
alertClient->updateAlerts(alerts, MAX_ALERTS, WUNDERGRROUND_API_KEY, WUNDERGRROUND_LANGUAGE, WUNDERGROUND_COUNTRY, WUNDERGROUND_CITY);
|
|
||||||
delete alertClient;
|
|
||||||
alertClient = nullptr;
|
|
||||||
|
|
||||||
WiFi.mode(WIFI_OFF);
|
WiFi.mode(WIFI_OFF);
|
||||||
delay(1000);
|
delay(1000);
|
||||||
}
|
}
|
||||||
@@ -520,10 +510,6 @@ void drawAstronomy() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void drawAlert() {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void drawCurrentWeatherDetail() {
|
void drawCurrentWeatherDetail() {
|
||||||
gfx.setFont(ArialRoundedMTBold_14);
|
gfx.setFont(ArialRoundedMTBold_14);
|
||||||
gfx.setTextAlignment(TEXT_ALIGN_CENTER);
|
gfx.setTextAlignment(TEXT_ALIGN_CENTER);
|
||||||
|
|||||||
Reference in New Issue
Block a user