This is the code for my temperature logging sensor, whose build log can be found at http://joshajohnson.com/index.php/what-is-the-best-time-to-close-your-blinds-temperature-logging-with-arduino-part-1/
joshajohnson/Temperature-Logging-Sensor-
Temperature logging to a SD card using a DS18B20 temperature sensor
C++