The whole code, related to temperature measurement is posted above. Regarding the valid data, I had to add division by 28, to get reasonable output. I've used melting ice and boiling water to determine that coefficient.