Things used in this project

Hardware components:
11113 01
SparkFun Arduino Pro Mini 328 - 5V/16MHz
×1
Graphic LCD 84x48 - Nokia 5110
×1
386 00
DHT11 Temperature & Humidity Sensor
×1
Adafruit industries ada161 image 75px
Photo resistor
×1
Adafruit industries ada258 image 75px
Li-Ion Battery 1000mAh
×1
DC-DC boost module 0.9V ~ 5V
×1
TP4056 5 Volt Mini USB Charger Module
×1

Code

TEMPERATURE_STATION.inoArduino
Just download the (LCD5110_Graph.h) and (dht.h) LIBRARY from internet and include the LIBRARY with Arduino ide and upload the code.
//TEMPERATURE STATION
//MADE BY RUMMAN ISLAM BD
//DATE:24.12.16

#include <LCD5110_Graph.h>                                      //LIBRARY
#include<dht.h>
#define TS 7                                                //TEMPERATURE SENSOR PIN NUMBER

dht DHT;
LCD5110 myGLCD(8,9,10,12,11);
//      LCD PIN NUMBER       
//      SCK  - Pin 8
//      MOSI - Pin 9
//      DC   - Pin 10
//      RST  - Pin 12
//      CS   - Pin 11

extern unsigned char SmallFont[];                               //FRONT SIZE
extern unsigned char TinyFont[];

char lightString [4];     
char tempString [5];
char humiString [4];

String Ttr;
String str;                                                //INITILIZE STRING 
String htr;

int lightIntensity ;                                       //INITILIZE VALUE
int Tempsensor;

void setup()                        
{
  myGLCD.InitLCD();
  myGLCD.setFont(SmallFont);
  randomSeed(analogRead(7));
  pinMode(LED_BUILTIN, OUTPUT);
}

void loop()
{
   
  digitalWrite(LED_BUILTIN, HIGH);                          //FOR BLINKING LED
  delay(100);                       
  digitalWrite(LED_BUILTIN, LOW);    
  delay(100); 
  
  Tempsensor=DHT.read11(TS);                                    // 1ST SENSOR
  int t=DHT.temperature;                                        // 2ND SENSOR   
  int h=DHT.humidity;                                           // 3RD SENSOR 
  lightIntensity = analogRead(A0);   
  lightIntensity = map(lightIntensity, 0, 1000, 0, 100);       //CONVERT THE VALUE INTO %
  delay(1000);



  Ttr =String(t)+"*c";                                //FOR CONVERT THE VALUE   
  htr =String(h)+"%"; 
  Ttr.toCharArray(tempString,5);
  htr.toCharArray(humiString,4);
  str = String(lightIntensity)+"%";
  str.toCharArray(lightString,4);                     //FOR CONVERT THE VALUE  
  delay(1000);
  
  myGLCD.clrScr();
  myGLCD.update();
  myGLCD.setFont(TinyFont);
  myGLCD.print("**WEATHER STATION**",CENTER,0);
  myGLCD.print("MADE BY RUMMAN",CENTER,7);
  myGLCD.print("-------------------------",CENTER,12);
  myGLCD.setFont(SmallFont);
  myGLCD.print("CELCIOUS:",LEFT,18);                    // FOR PRINT IN SCREEN  
  myGLCD.print(tempString,RIGHT,18);
  myGLCD.setFont(TinyFont);
  myGLCD.print("------------------------",LEFT,25);
  myGLCD.setFont(SmallFont);
  myGLCD.print("HUMIDITY:",LEFT,29);
  myGLCD.print(humiString,RIGHT,29);
  myGLCD.setFont(TinyFont);
  myGLCD.print("------------------------",LEFT,36);
  myGLCD.setFont(SmallFont); 
  myGLCD.print("SUN:",LEFT,41);
  myGLCD.print(lightString,RIGHT,41);
  
 
  myGLCD.update();  
  delay(1000);
}

Credits

Replications

Did you replicate this project? Share it!

I made one

Love this project? Think it could be improved? Tell us what you think!

Give feedback

Comments

Similar projects you might like

Space Invaders
Intermediate
  • 26
  • 2

A classic arcade game built using two TI microcontrollers.

Self Balancing Robot Using Mpu6050 Accelerometer
Intermediate
  • 304
  • 8

Protip

this is self balancing robot on two wheels using mpu6050 accelerometer based on arduino..

Controlling 16x2 Character Display with Arduino
Intermediate
  • 37
  • 2

Protip

This project shows you how to control 16x2 character display with an Arduino. Enjoy!

Pen Stand: Gaming Enabled
Intermediate
  • 256
  • 5

Full instructions

Do you have a pen stand that just sits there and does nothing? Can we make it play a game/flash LEDs every time you use it? Let's find out!

Node-Red and MQTT for Your IoT Projects
Intermediate
  • 151
  • 3

Work in progress

The idea is to create an environment running an MQTT Server, Mosquitto, and Node-Red, and start developing projects with connected sensors.

Dancing Autobot
Intermediate
  • 232
  • 4

Protip

this is our project..and new thats called autobot with dancing like michael jackson....

Sign up / LoginProjectsCommunitiesTopicsContestsLiveAppsBetaFree StoreBlog