Introduction: Arduino Digital Thermometer (with DS18B20)

Hello,

today I will show you how to make your own digital thermometer with arduino uno and DS18B20 temperature sensor.

This thermometer can measure temperatures from -55°C to +125°C (-67°F to +257°F). It has to buttons, one to turn on/off screen light and one to change between celsius/fahrenheit.

Official project page: http://www.ardumotive.com/lcd-thermometer.html

I prefer to build my own arduino based circuit by using the ATmega328p uno possessor, but this is optional for you. You can also use breadboard to build it easier ;)

Let's get started!

Step 1: What You Will Need

Basic

For this project you will need:

  • Arduino uno
  • DS18B20 temp sensor
  • LCD 16x2
  • 4.7K resistor
  • potensiometer (to control display contrast)
  • 2x buttons


Optional

If you prefer to build this without arduino uno board you will also need:

  • 16MHz Crystal oscillator
  • 2x 22pF and 1x 100nF capacitors
  • 10K resistor
  • 28 pin DIP IC Socket
  • on/off sw

About power supply

If you make this with Arduino uno board you will need at least 6V battery pack or AC to DC adapter. You can also use USB cable to power on thermometer from your computer.

If you prefer the "hard way" and build this without Arduino board you will just need a 3.7V rechargeable battery. (max 5V)

Step 2: The Circuit

As I said before, I will give you two ways for build this thermometer.

The easy way is to build it on breadboard and the difficult way is to build it on a custom Arduino based circuit board.

Step 3: The Box

Building the box is an optional step. See images above. You can make it as big (or small) you want.

Step 4: The Code

Here's the code, embedded using codebender!

Try downloading the codebender plugin and clicking on the "Run on Arduino" button to program your Arduino with this sketch.

If you choose to make your own arduino based circuit, put atmega328p on Arduino uno board, click "Run on Arduino" to program it and then put it back to your circuit.

Step 5: Well Done!

That's it! Now you have your own Arduino Digital Thermometer in your desk ;)

I hope you liked this, let me know in the comments.


There will be more of them, so make sure to click Follow button :)

Comments

author
JanB19 made it! (author)2015-08-06

Is good to let unlimited current go from D7 to led+ on display? Is there some internal resistor in LCD board?

author
Ardumotive_com made it! (author)Ardumotive_com2015-08-06

I am not sure about this... but I think that lcd board has already resistor for leds.

You can try to connect one 220 Ohm resistor between them ;)

author
dreyes15 made it! (author)dreyes152017-05-05

Do yo have the breadboard from the circuit opcional you describe on the top.?

author
ikka made it! (author)2017-02-04

Very nice project Sir
I want to ask you if we will
Not use thermometers and other things and only use LCD and arduino and sensors of sonic sonar
Then also code will work

author
muralir4 made it! (author)2016-09-13

i want this code and circuit diagram

author
Blessie RoseB made it! (author)2016-03-26

is it okay if the sensor is inside the box? or should we put it outside the box?

author
alexkat made it! (author)2016-02-05

cool project!!! but where exactly do you connect the battery pack??

author
dmwatkins made it! (author)2015-06-16

Nicely done!