Code that is used to get and save the humidity and temperature