From 581a561aed8b2b245df263eb659e27491b31c0fd Mon Sep 17 00:00:00 2001 From: Paco Hope Date: Wed, 29 Dec 2021 13:56:44 -0500 Subject: [PATCH] Added public and private declarations for weather-related functions and members. --- src/Watchy.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/Watchy.h b/src/Watchy.h index 709cfd3..adf4db9 100644 --- a/src/Watchy.h +++ b/src/Watchy.h @@ -15,8 +15,9 @@ #include "config.h" typedef struct weatherData{ - int8_t temperature; + int8_t temperature; int16_t weatherConditionCode; + String weatherDescription; }weatherData; class Watchy { @@ -47,12 +48,20 @@ class Watchy { void showWatchFace(bool partialRefresh); virtual void drawWatchFace(); //override this method for different watch faces - + void setupWeather( uint32_t city, bool celsius, uint16_t updateInterval, String lang, String apikey ); + uint8_t getAmbientTemp(); + bool weatherCelsius = true; private: void _bmaConfig(); static void _configModeCallback(WiFiManager *myWiFiManager); static uint16_t _readRegister(uint8_t address, uint8_t reg, uint8_t *data, uint16_t len); static uint16_t _writeRegister(uint8_t address, uint8_t reg, uint8_t *data, uint16_t len); + uint16_t weatherInterval; + uint32_t weatherCity; + String weatherAPIKey; + String weatherLang; + bool weatherInit = false; + uint16_t weatherIntervalCounter = 0; }; extern RTC_DATA_ATTR int guiState;