Scale-N

Scale-N

Arduino

Componenten

Rollend Materieel

Naslag

Onderdelen

Wissels

Basis Electronica

Symbols Electronica

Programming Arduino

DCC++

DR5000

Products

Link














































21. DS18B20


The DS18B20 is a popular digital temperature sensor widely used in various applications due to its accuracy, simplicity, and ease of integration.

Features of DS18B20:
  • Accuracy: ±0.5°C accuracy from -10°C to +85°C.
  • Temperature Range: -55°C to +125°C.
  • Resolution: Programmable from 9 to 12 bits (default is 12 bits, providing 0.0625°C resolution).
  • Interface: Communicates using the 1-Wire protocol, requiring only one data line (plus ground and optional power) for communication.
  • Power Modes: Can operate in parasitic power mode (two wires) or normal mode (three wires).
  • Multiple Devices: Each sensor has a unique 64-bit ROM code, allowing multiple DS18B20s to be connected on the same data line.
Connections:
Pins:
  • VDD: Power supply (3.0V to 5.5V).
  • GND: Ground.
  • DQ: Data line, connected to a microcontroller I/O pin with a pull-up resistor (typically 4.7kΩ).
Libraries
  • OneWire
  • DallasTemperature

Breadboard
Arduino nano
DS18B20
Stitchable Plug Pin Naald Pitch Header Socket
Breadboard Jumpers
Pull-up resistor 4.7kΩ


Arduino nano ground to power rail ground Arduino nano 5V to power rail 5V Arduino nano digital pin 2 to DS18B20 dataline (yellow) DS18B20 Ground to power rail ground DS18B20 5V to power rail 5v DS18B20 dataline to power rail 5V with pull-up resistor


Monitor output