tabsoft thanks for the detailed explanation of how the section works, and for the modified code to include the temperature readings as well.

The project that I'm developing uses DT's interrupts and DS18B20 include files to control the PID routines for the thermostats. Using the temperature element in the AM2302 would be better as it saves having multiple sensor probes going to the snakes enclosures. I'll try out your suggested code so that it works with the existing variables to see how it works. My main concern is that as the code uses DT's interrupts it continues to drive the heaters whilst the pic is doing other things such as entering the menu options.

Thanks once again fo your help, and for explaining what you did in such detail. It makes the learning process a lot simpler :-)