I have make an outdoor thermometer using the DS18b20. I used the one-wire library device code example for a single device and it has been working good. As the outdoor temperature has gone down this winter I have noticed a problem with the data the device code is sending. The temperature reading is good until it goes down past zero C. I have found some code on a different site
that looks to address this problem, but it is code for the arduino. I am having a hard time rewriting the code so it will work with the existing library code.
You can see in the photo below the output I get when the temperature does down past zero. The MSB jumps to 255 and the LSB jumps to 255 just past zero c. As the temperature goes lower the LSB starts to decrease.
I am a newbie when it comes to coding and math was not a strong subject for me in school. If anyone could help me with the code change to the example I would very much appreciate it.