 See more at http://blog.squix.ch
 */
 
-#include <ESP8266WiFi.h>
+#include <ESPWiFi.h>
+#if defined(ESP8266)
 #include <Ticker.h>
+#endif
 #include <JsonListener.h>
 #include "SSD1306Wire.h"
 #include "OLEDDisplayUi.h"

  Serial.println("");

  updateData(&display);

  ticker.attach(UPDATE_INTERVAL_SECS, setReadyForWeatherUpdate);

}

void loop() {

  if (readyForWeatherUpdate && ui.getUiState()->frameState == FIXED) {
    updateData(&display);


String lastUpdate = "--";

#if defined(ESP8266)
Ticker ticker;
#else
long timeSinceLastWUpdate = 0;
#endif

//declaring prototypes
void drawProgress(OLEDDisplay *display, int percentage, String label);
