How to use DS18B20 Temperature sensor with arduino

Поділитися
Вставка
  • Опубліковано 12 лют 2021
  • DS18B20 is one of the popular temperature sensors because it is cheap, easy to use, and also waterproof. It is a very cheap waterproof temperature sensor we can get from the market.
    In this video, we will learn how to use it with Arduino.
    You can support us and unlock premium projects code by joining our membership by clicking the link below:
    / @miliohm
    Download sketch and wiring diagram :
    miliohm.com/how-to-simply-use...
  • Наука та технологія

КОМЕНТАРІ • 79

  • @maxwellvinimax68
    @maxwellvinimax68 2 роки тому +2

    what all u said worked out perfect.first i thought my display had prob then changed contast and wroked perfect. never thought i will be able to something llike this for my school project. thanks man

  • @Alshafi
    @Alshafi Рік тому

    Thanks for the vid. i would only recommend installing the OneWire library since it is actually required in the example.

  • @bb4853
    @bb4853 2 роки тому +7

    I've check the code you gave that is so detailed, to be a primer I learned a lot from it, I'll be guilty if I dont hit a like on this video.

    • @miliohm
      @miliohm  2 роки тому +2

      Thanks!

    • @shogunvanrepi3555
      @shogunvanrepi3555 Рік тому

      ​@@miliohm what happens if no resistor is added to the circuit?

  • @ajith6840
    @ajith6840 Рік тому +2

    Thank you so much for this video👍
    Is it possible to add an battery voltage sensor along with the temperature sensor in the same Arduino , How can we combine the both programs

  • @josielsoaresfarias1760
    @josielsoaresfarias1760 11 місяців тому

    Valeu amigo. Ótimo vídeo
    Único vídeo que encontrei na internet que realmente explica como faz. Parabéns e Obrigado. Ganhou meu like 👏

  • @BerndJTHIEL
    @BerndJTHIEL 2 роки тому

    how much of this sensors you can use parallel on a androinu? i need a system with 8-16

  • @arthurmarcolan9722
    @arthurmarcolan9722 2 роки тому

    thank you so much for the help, you saved me

  • @gernandoregobionejunior3794
    @gernandoregobionejunior3794 2 роки тому

    Hi, i'm having some problems with this sensor when i try to heat the water until it evaporates, my sensor can't read a temperature above 100°C or equal. My programation sketch is similar

  • @chandra7734
    @chandra7734 3 роки тому

    is it accurate to measure a room temperature below -10 to -25 degrees Celcius?

  • @gasko2762
    @gasko2762 2 роки тому +2

    Thank you for the wonderful programs for Arduino for beginners.

  • @Bianchi77
    @Bianchi77 2 роки тому

    Nice video, thanks :)

  • @raajnivas2550
    @raajnivas2550 Рік тому

    Thank you.

  • @Earthstoriesbydev
    @Earthstoriesbydev 10 місяців тому

    have u done this with a battery? What battery it might need do u know?

  • @rafaellouish.odrada4183
    @rafaellouish.odrada4183 2 роки тому +1

    good day would like to ask why my serial monitor shows the device cannot be found that show error results

  • @tosc4goro711
    @tosc4goro711 6 місяців тому

    thanks a lot for the tutorial sir, could u also make the one wire version tutorial of this sensor? thanks!

  • @GaneshPawar-gs6ee
    @GaneshPawar-gs6ee 2 роки тому

    can we add more than one DS18B20 sensor wire on same bus/pin

  • @sheenamarietongol4367
    @sheenamarietongol4367 Рік тому

    what type of jumoer wire sis you use?

  • @hondat7435
    @hondat7435 3 роки тому

    Hello, can you do one with the VISA LabVIEW?

  • @FraLin
    @FraLin 10 місяців тому

    I was looking for polarity and colours, can it die if I confuse yellow and red?

  • @jyaniharshil5585
    @jyaniharshil5585 2 роки тому

    Hey brother can you tell me the code for my project . ds18b20 temperature sensor , LCD 16×2 , arduino UNO & fan , all connected .
    As the temperature rises , fan goes fast or Start rotating and if temperature goes low , fan slows or stops down...

  • @syukorburger9699
    @syukorburger9699 2 роки тому

    hey, why my (tempC != DEVICE_DISCONNECTED_C) at line 56 is error, it said "'DEVICE_DISCONNECTED_C' was not declared in this scope" i hope u can help me with that

  • @raphaelnazareth486
    @raphaelnazareth486 Рік тому

    nice video

  • @shijumax1
    @shijumax1 10 місяців тому

    Hi , I am your new subscriber, can u make a video or explain to build a SMD reflow with Nextion display?

  • @mikevez6639
    @mikevez6639 Рік тому

    If people are getting strange results disconnect the power line to the sensor if using parasitic power from the arduino. just run 5v thro the resistor to the signal wire in yellow. This is what the datasheet says

  • @shogunvanrepi3555
    @shogunvanrepi3555 Рік тому

    what happens if no resistor is added to the circuit?

  • @KonselorSekolah1407
    @KonselorSekolah1407 3 роки тому

    Looks like better than lm35

  • @TheWareek
    @TheWareek 2 роки тому

    The first sketch worked on my set up but in the serial monitor I got the temperature about every 1/10 of a second. any ideas.

  • @spakxd9834
    @spakxd9834 2 роки тому

    why on my PC not showing the COM2 window?

  • @mend17
    @mend17 2 роки тому

    i have an adruino mega were do i place the SDA & de SCL of ic2? couze the A4 & a5 dont work

    • @miliohm
      @miliohm  2 роки тому

      SDA - 20
      SCL - 21

  • @battlecampkhimmay2981
    @battlecampkhimmay2981 2 роки тому

    Do you guys have same method on raspberry pi pls

  • @christophercabanbanalvarad2241
    @christophercabanbanalvarad2241 2 роки тому

    i followed your diagram and download the code you have posted but still my lcd 168b20 doesn't display anything except for block bars. pls help.....

    • @chrisheaps9893
      @chrisheaps9893 2 роки тому +2

      You may need to adjust the contrast on the back of the display.

  • @TopOneTime
    @TopOneTime 3 роки тому

    Can you type the name of the display screen please?

  • @gouthamas7265
    @gouthamas7265 2 роки тому

    Hey. I tried the code ,it is working on serial monitor, but when I copy pasted your other coder for LCD ,lcd Is on but not showing anything, need help !!!!

  • @chickenz4604
    @chickenz4604 2 роки тому

    is the temperature sensor robust for 1 year usage?

  • @chris9yearsago698
    @chris9yearsago698 2 роки тому

    Can you use it for water temperature? Like dip the sensor in it?

    • @miliohm
      @miliohm  2 роки тому +2

      You should watch at 5:29

    • @chris9yearsago698
      @chris9yearsago698 2 роки тому

      @@miliohm thanks man I didn''t actually watch it all

  • @chojix6394
    @chojix6394 11 місяців тому

    What to do if temperature data cannot be read?

  • @Myb.pranoto
    @Myb.pranoto 2 роки тому

    What is the type of the lcd?

  • @pew1472
    @pew1472 2 роки тому

    im new to to arduino project. why dos it have an error LiquidCrystal_I2C.h: No such file or directory
    . pls help :)

    • @miliohm
      @miliohm  2 роки тому

      You need to download the library first, watch again carefully

  • @wisnuindrawan6496
    @wisnuindrawan6496 3 роки тому

    how about accuracy is better than themocouple ?

    • @miliohm
      @miliohm  3 роки тому

      Make thermocouple accurate is sometimes complex since it has so small signal. So I think this sensor can be more accurate but, thermocouple has wider range. It can measure up to thousands degrees of celcius.

    • @wisnuindrawan6496
      @wisnuindrawan6496 3 роки тому

      @@miliohm thank you for the answer

  • @AneeshPradeep
    @AneeshPradeep 2 роки тому

    What is the purpose of the register
    Can the sensor be connected directly to the board ?

    • @miliohm
      @miliohm  2 роки тому

      What register?
      The breadboard just help us to put the resistor

    • @AneeshPradeep
      @AneeshPradeep 2 роки тому

      @@miliohm Sorry . i meant resistor

    • @miliohm
      @miliohm  2 роки тому

      @@AneeshPradeep it's pull up resistor. It's from datasheet.

  • @pearlydanahambayen3939
    @pearlydanahambayen3939 Рік тому

    My ds18b20 is not giving me results it only shows -127.00c and -196.6f it is not changing even if I put it on hot water can you please help me?

  • @Imaangrycat
    @Imaangrycat 2 роки тому

    can i use a 4.7k resistor also i am getting -127° reading what can be my solution

    • @miliohm
      @miliohm  2 роки тому

      It should works, check your wiring again.

    • @axel_72
      @axel_72 2 роки тому

      i have same -127°... but ho to resolved it ?

    • @Imaangrycat
      @Imaangrycat 2 роки тому

      @@axel_72 Check your wiring and make sure that it’s getting proper power supply
      When I connect this to my esp32 it was not working properly for me but Aurdino uno board gave me proper output

  • @noraimanazmi1190
    @noraimanazmi1190 3 роки тому

    im sorry,can i get code for lcd1602 :(

    • @miliohm
      @miliohm  3 роки тому

      You should read the description

  • @xarek24g
    @xarek24g 2 роки тому

    Why u use this resistor with the temp. Sensor i need this one?

  • @musicalmusician8019
    @musicalmusician8019 Рік тому

    Is it possible to do this without a breadboard?

    • @miliohm
      @miliohm  Рік тому

      Sure

    • @musicalmusician8019
      @musicalmusician8019 Рік тому

      @@miliohm Does it require calibration?

    • @miliohm
      @miliohm  Рік тому

      @@musicalmusician8019 it is factory calibrared. But if you still need adjusment you can also calibrate it.

  • @williampowell7518
    @williampowell7518 2 роки тому

    the temperature values that I am getting is not accurate. my room is abou5 celcius but I am seeing 85 degrees Celsius

    • @miliohm
      @miliohm  2 роки тому

      Did it change?

  • @bradley9856
    @bradley9856 Рік тому

    good video, but all i get is this in the serial monitor:
    Locating devices...Found 0 devices.
    Parasite power is: OFF
    Unable to find address for Device 0
    Device 0 Address: 0000000000000000
    Device 0 Resolution: 0
    Requesting temperatures...DONE
    Error: Could not read temperature data

  • @tanjimulislamdip2338
    @tanjimulislamdip2338 3 роки тому

    Can you give me the code of it??plz I need urgent.

    • @miliohm
      @miliohm  3 роки тому

      You should read the description

    • @tanjimulislamdip2338
      @tanjimulislamdip2338 3 роки тому

      The link is not working there,please give me the code of it,i need it very urgently,i must submit my portable refrigerator project 🙏

    • @miliohm
      @miliohm  3 роки тому +2

      @@tanjimulislamdip2338 maybe you click the wrong link. The second one. Still work here miliohm.com/how-to-simply-use-ds18b20-temperature-sensor-with-arduino/

  • @jyaniharshil5585
    @jyaniharshil5585 2 роки тому

    Hey brother can you tell me the code for my project . ds18b20 temperature sensor , LCD 16×2 , arduino UNO & fan , all connected .
    As the temperature rises , fan goes fast or Start rotating and if temperature goes low , fan slows or stops down...