adding temperature and humidity function