Arduino - Nokia 5110 LCD Temperature Meter With the DS18B20

4,613

19

30

Posted

Introduction: Arduino - Nokia 5110 LCD Temperature Meter With the DS18B20

Hello World! I made a Temperature meter with a Nokia 5110 LCD.

I added the librarys and i made a Image for the LCD background with a rounded border and temperature icon which

is added to the LCD5110_Graph Libary and is named borderRoundedIcon.c

Follow the Next step for The Schematic Code & Parts List.

Step 1: Schematic Code & Parts List.

Just wire everything up like the schematic and upload the code.

Make sure you download and install the libraries first! You need them!

Put the pins on the LCD like following:

PIN1 on LCD ==>> PIN 12 on Arduino

PIN2 on LCD ==>> PIN 11 on Arduino

PIN3 on LCD ==>> PIN 10 on Arduino

PIN4 on LCD ==>> PIN 9 on Arduino

PIN5 on LCD ==>> PIN 8 on Arduino

PIN6 on LCD ==>> PIN 3.3 Volt on Arduino

PIN7 on LCD ==>> PIN 5 volt on Arduino

PIN8 on LCD ==>> PIN Ground on Arduino

Parts List.

  1. Arduino Uno, I used the robotdyn uno.
  2. DS18b20 Temperature Sensor.
  3. Nokia 5110 LCD
  4. Jumper wires MM/FF/MF.

Good luck!

4 People Made This Project!

Recommendations

  • Spotless Contest

    Spotless Contest
  • Space Challenge

    Space Challenge
  • Science of Cooking

    Science of Cooking
user

We have a be nice policy.
Please be positive and constructive.

Tips

Questions

26 Comments

Where is my bug?

C:\Temperature\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd.ino: In function 'void loop()':

C:\Temperature\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd.ino:45:30: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

lcd.print("Temp.Celc.",17,5); //Comment when using Fahrenheit

^

sketch\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd.ino.cpp.o: In function `loop':

C:\Temperature\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd/DS18B20_Temperature_sensor_with_NOKIA5110_Lcd.ino:36: undefined reference to `borderRoundedIcon'

C:\Temperature\DS18B20_Temperature_sensor_with_NOKIA5110_Lcd/DS18B20_Temperature_sensor_with_NOKIA5110_Lcd.ino:36: undefined reference to `borderRoundedIcon'

collect2.exe: error: ld returned 1 exit status

exit status 1

Works well, thanks except that negative temperatures obscure the last digit.

My Nokia display has different pinout, but works when connected correctly.

Hi. I added the line "OneWire ds (2);" and then it worked. More added a line "lcd.setContrast (65);" it adjust the contrast. In the scheme added resistor 4,7kOm, without indications have been not correct.

Hi, i remeber you saying it did not work, but for others and me it did. But im glad you fixed it. What exactly did you change?

/*

Author: Danny van den Brande, ArduinoSensors.nl. BlueCore Tech.

Hello world! this is a example project for the DS18b20 on a old Nokia 5110 LCD Display.

*/

#include <OneWire.h>

#include <DallasTemperature.h>

#include <LCD5110_Graph.h>

#define ONE_WIRE_BUS 2

LCD5110 lcd(8,9,10,12,11);

OneWire ds(2);

extern unsigned char SmallFont[];

extern unsigned char BigNumbers[];

extern uint8_t borderRoundedIcon[];

char TempCelciusFahrenheit[6];

OneWire oneWire(ONE_WIRE_BUS);

DallasTemperature sensors(&oneWire);

float tempC = 0;

float tempF = 0;

void setup(void)

{

lcd.InitLCD();

sensors.begin();

}

void loop(void)

{

lcd.setContrast(65);

lcd.clrScr();

lcd.drawBitmap(0, 0, borderRoundedIcon, 84, 48);

sensors.requestTemperatures();

tempC = sensors.getTempCByIndex(0);

tempF = sensors.toFahrenheit(tempC);

// convertToString(tempF); //these are Fahrenheit, uncomment when using degrees.

convertToString(tempC); //These are degrees, comment when using Fahrenheit.

lcd.setFont(BigNumbers);

lcd.print(TempCelciusFahrenheit,22,14); // You can set position of the text here.

lcd.setFont(SmallFont);

lcd.print("Temp.Celc.",17,5); //Comment when using Fahrenheit

// lcd.print("Temp.Fahr.",17,5); //Uncomment when using Celcius

lcd.update();

delay(1000);

}

void convertToString(float number)

{

dtostrf(number, 3, 1, TempCelciusFahrenheit);

}

Hello i have the same problem that АнатолийД exactly the same.

I try whit different library, érase all library, install it again, to change some pins 11 and 12 etc... But i dont have any image in the lcd. But if i use one Sample of the nokia 5510_graph the lcd works perfect, ( with the 4 examples).

In you tube is placed another tutoríal similar:

http://youtu.be/ga_1dqGjsbo

But i have the same problem, no image.

Anyone know what is wrong or any idea for why dosnt work this two arduino practices?

Thanks for your help.

Show a picture of the pinout of the LCD you use. I noticed there are different nokia screens

this is my lcd. It works well with the examples of the library 5510_graph.

image.jpgimage.jpgimage.jpg

Show a picture of the pinout of the LCD you use. I noticed there are different nokia screens