PIC Digital Thermometer and Clock
Here you will find complete construction details including circuit diagrams, PCB layouts and PIC firmware (and the source code). The code was written in Proton PIC BASIC but the good news is that there is now a free version of this compiler available for download; AMICUS18.
** UPDATED 30th June 2016 **
There is an update to this project available that replaces the inferior DS1302 RTC with a much more accurate DS3231 module.
Details of the update are available here.
** ERRATA 24th April 2016 **
An eagle eyed constructor pointed out that the parts list states X1 is 20MHz.
It should be 16MHz. It’s correct in the schematic.
** UPDATED 31st Jan 2016 **
New v8 firmware supports displaying date (month and day) as well as time.
Also removes the need for the PIC crystal so frees up two additional I/O pins.
Display interrupt routine is tiny and much faster than before resulting a brighter display with much less flicker.
** UPDATED 17th Aug 2013 **
There was a bug in the firmware that prevented the backup battery from being recharged correctly.
** UPDATED 18th April 2013 **
The PIC firmware has been updated to reduce display flicker whilst giving brighter digits, and the code is now a lot simpler to change including changing the length of time the time and temperatures are shown if required. I’ve also updated some of the program comments to help people who want to make changes.
** UPDATE 6th Jan 2012**
I’ve been asked how far from the main unit the temperature sensors can be located.
The unit I built had one sensor fixed within the unit (5cm of cable), and the other sensor located outside, but the cable run was actually probably only around 50cm.
When I tried a longer 5M cable, I couldn’t get the sensor to work, but everything I read indicated that several hundred meters should be possible without any hardware changes.
In desperation, I tried another sensor IC and hey-presto, it worked with the 5M cable I was using.
I purchased ten of the DS18B20 ICs off Ebay for less than £2 each and they all worked perfectly with the 5M cable; the original sensor would still only work over a short distance. I can only assume that I was unlucky to have obtained a semi-faulty sensor IC.
So, you should be able to use a sensor on at least a 5M cable run and if you have problems, I’d initially start with another sensor IC. In theory, you should be able to run over a much longer cable, but I’ve not tried that.
FOr More Details: PIC Digital Thermometer and Clock
JLCPCB – Prototype 10 PCBs for $2 + 2 days Lead Time
China’s Largest PCB Prototype Enterprise, 300,000+ Customers & 10,000+ Online Orders Per Day
Inside a huge PCB factory: https://www.youtube.com/watch?v=_XCznQFV-Mw