 StaticJsonBuffer<200> jsonBuffer;
 MqttConnector* mqttConnector = NULL;
 
-JsonObject* sensorsData;
+JsonObject* sensorsData = NULL;
 
 void register_receive_hooks(MqttConnector* mqtt)
 {

  displayTime();

  tmElements_t tm;
  RTC.read(tm);
  Serial.print("RTC:      ");
  displayTime(tm);
  Serial.print("Timer Temp: "); Serial.println(RTC.temperature()/4.0);

  si7021_thc thc = sensor.getTempAndRH();
  double t = thc.celsiusHundredths / 100.0;

  }

  dataFile.seek(dataFile.size());
  char data[100];
  snprintf(data, 100, "%i;%i;%i;%.2f;%i;%i\r\n", currentTime, thc.celsiusHundredths, thc.humidityPercent, bmpTemp, p, ppm);
  dataFile.write(data, 100);
  dataFile.close();
  Serial.println();
}
