Skip to datasheet
The Engineering ProjectsAI Interactive Datasheet

DS18B201-Wire digital thermometer

A temperature reading. A unique digital identity.

Manufacturer-referenced

Analog Devices / Maxim Integrated · DS18B20+

TO-9219-7487 · Rev 6 · July 2019

DS18B20 measures temperature digitally over a 1-Wire connection. Its programmable 9–12-bit conversion covers −55 to +125°C, with a stated ±0.5°C error band from −10 to +85°C. Resolution determines the smallest reported step; it does not replace the accuracy specification. Each sensor has a factory-programmed 64-bit ROM identity, allowing individually addressed sensors to share one bus. Temperature, alarm thresholds and configuration are read from a nine-byte scratchpad that includes a CRC. The views compare the three-lead DS18B20+ and the eight-lead DS18B20Z+ SOIC. Their physical pin numbers differ. The basic circuit uses external 3.3 V power, a shared ground and a pullup on DQ; parasite power has additional bus-power requirements.

Real View

DS18B20+ black package with silver leads and readable markings.
DS18B20+ · TO-92Package illustration

Pinout

DS18B20+TO-92Front view · flat face toward you
Select a pin to see its functionTO-92 · 3 pins

PCB Footprint

Loading footprint…
Powered by
Finding TO-92 packageTop view · mm

3D View

Preparing 3D preview…
3D packageDrag to rotate · Scroll to zoom
Supply & return1-Wire dataUnused leads
DS18B20+TO-92Front view · flat face toward you

Click a lead or use the arrow keys. Front view · flat face toward you

1
PIN 1 · Supply & return

GND

Ground

Function

Supply and bus return.

How to connect

Connect to the controller ground.

At a glance

1-Wire digital thermometer

The temperature converter writes a signed digital word. ROM addressing selects a sensor; the scratchpad provides the result, configuration and CRC.

−55–125 °CMeasured temperature
9–12 bitsSelectable resolution
3.0–5.5 VExternal supply
±0.5 °C · −10 to +85°CError band

Operating profile

DS18B20+

Selected package
TO-92DS18B20+ · 3 physical leads
Digital interface
1-WireOpen drain · external pullup
12-bit conversion
750 msMaximum specified time

Supply and temperature

Key parameters and their test conditions

External supply
3.0–5.5 VConditions / notes: VDD relative to GND
Measurement range
−55 to +125°CConditions / notes: Externally powered operation
Error band, central range
±0.5°CConditions / notes: −10 to +85°C
Error band, wider range
±1°CConditions / notes: −30 to +100°C
Error band, full range
±2°CConditions / notes: −55 to +125°C
DQ pullup, external power
3.0 V to VDDConditions / notes: Example: 4.7 kΩ to 3.3 V

Package details

Follows the selected physical package

Manufacturer
Analog Devices / Maxim Integrated
Part number
DS18B20+
Package
TO-92
Connections
3 pins
Mounting
Through-hole
Lead pitch
2.54 mm formed-lead footprint
Package code
TO-92
Thermal reference
−55 to +125°C operating range

Connections by function

Select a pin to open its function, electrical notes and wiring guidance.

Supply & return2 pins

1-Wire data1 pins

Select the sensor

Reset the bus, detect presence and select the device using its 64-bit ROM identity. Skip ROM is suitable for a single-sensor read; multiple devices need individual addressing.

Convert temperature

Issue Convert T (44h). Resolution changes the maximum time from 93.75 ms at 9 bits to 750 ms at 12 bits. Externally powered sensors can report completion in read slots.

Read and validate

Reset and select again, then Read Scratchpad (BEh). Read all nine bytes, verify CRC and decode the signed temperature word. Mask the undefined low bits at reduced resolution.

Read a completed conversion and verify its scratchpad CRC. A power-up register value of +85°C is not proof of a fresh temperature measurement. The calculator shows ideal register encoding, not sensor error or a timed 1-Wire bus.

Temperature, bits and conversion time.

Explore resolution and the signed 1-Wire temperature word.

Ideal register explorer

These controls calculate a representative register value. A real sensor needs a Convert T command and time to complete a measurement.

DECODED TEMPERATURE—
——
TEMPERATURE BYTES · LSB FIRST—Scratchpad byte 0, then byte 1
MAXIMUM CONVERSION TIME—Resolution changes the time required
CONFIGURATION REGISTER—Byte 4 · R1/R0 select resolution

DQ pin 2 uses an open-drain bus and pullup. Supply pin 3; ground pin 1. Ideal encoding only: temperature is rounded to the selected step. Undefined lower bits are displayed as zero. Alarm comparison discards fractional bits, including for negative temperatures. Verify CRC and conversion completion on real hardware.

Compact functional architecture inside a black DS18B20 package: temperature sensing and conversion feed scratchpad, alarm and configuration storage, CRC generator and the ROM-addressed 1-Wire port.
Functional teaching diagram; not a transistor-level die schematic.
Physical DS18B20 TO-92 front view, pins1GND2DQ3VDD. Pin3 uses3.3V, pin1 ground, pin2 a controller GPIO with4.7k pullup to3.3V. A100nF bypass is placed across supply. Controller displays25.0625C from word0191h.
Externally powered, single-sensor example. Use matched ROM addresses for multidrop reads.

Pin reference

Select a pin to explore its function and connection.

3 pins
PinSignalTypeFunction
GNDGroundSupply and bus return.
DQBidirectional, open-drain1-Wire commands and temperature data share this pin.
VDDSupplyExternal supply for normal powered operation.
TO-92 · Front view · flat face toward you · Select a pin number to inspect its connection.

Supply and temperature

DS18B20 · all selected packages

ParameterValueConditions / notes
External supply3.0–5.5 VVDD relative to GND
Measurement range−55 to +125°CExternally powered operation
Error band, central range±0.5°C−10 to +85°C
Error band, wider range±1°C−30 to +100°C
Error band, full range±2°C−55 to +125°C
DQ pullup, external power3.0 V to VDDExample: 4.7 kΩ to 3.3 V
High-temperature operationUse external power above +100°CParasite power is not recommended there

Manufacturer thermometer-error limits are 3-sigma values. A 0.0625°C step is not ±0.0625°C accuracy.

Resolution and conversion time

Configuration byte 4 · R1/R0

ParameterValueConditions / notes
9 bits · R1/R0 = 000.5°C · 93.75 ms maximumConfiguration 1Fh; mask temperature bits 2:0
10 bits · R1/R0 = 010.25°C · 187.5 ms maximumConfiguration 3Fh; mask bits 1:0
11 bits · R1/R0 = 100.125°C · 375 ms maximumConfiguration 5Fh; mask bit 0
12 bits · R1/R0 = 110.0625°C · 750 ms maximumConfiguration 7Fh; all temperature bits valid
Power-up temperature word0550h = +85°CPerform a conversion before treating it as a fresh reading

The page calculator rounds to a nominal representable value and displays masked low bits as zero. Hardware low bits below the selected resolution are undefined.

Scratchpad and ROM

Bytes travel least-significant bit first

ParameterValueConditions / notes
Scratchpad bytes 0 and 1Temperature LSB, then MSBSigned two’s-complement word; divide by 16 after masking
Byte 2 / byte 3TH / TLSigned 8-bit integer alarm thresholds
Byte 4Resolution configurationR1/R0 at bits 6:5; preserve reserved bit format
Bytes 5, 6 and 7ReservedRead for CRC; do not assume all reserved values are fixed
Byte 8CRC-8 over bytes 0–7Polynomial x⁸ + x⁵ + x⁴ + 1; initial value zero
64-bit ROM28h family + 48-bit serial + 8-bit CRCUnique identity for bus addressing
Alarm comparisonTemperature bits 11:4Alarm when integer reading ≤ TL or ≥ TH

Alarm flags update after a conversion. The bus master must verify CRC; the device does not reject a host operation automatically when the host observes a mismatch.

1-Wire command reference

Initialize → ROM command → function command

ParameterValueConditions / notes
Search ROM / Match ROMF0h / 55hDiscover devices / select one 64-bit identity
Read ROM / Skip ROM33h / CChRead ROM only on a single-device bus; Skip addresses all
Alarm SearchEChOnly sensors with an alarm flag participate
Convert T44hStart one temperature conversion
Read ScratchpadBEhRead nine bytes including CRC
Write Scratchpad4EhWrite TH, TL and configuration; complete all three bytes
Copy Scratchpad48hStore alarm/configuration values in EEPROM
Recall EEPROMB8hRestore stored settings into scratchpad
Read Power SupplyB4hRead slot: LOW = parasite, HIGH = external

Skip ROM followed by Read Scratchpad causes collisions when multiple devices respond. Use Match ROM for each sensor.

Standard-speed bus timing

VDD = 3.0–5.5 V

ParameterValueConditions / notes
Reset LOW / reset HIGH480 µs minimum / 480 µs minimumA parasite-powered reset LOW over 960 µs can cause a power-on reset
Presence wait / presence LOW15–60 µs / 60–240 µsMeasured after master releases reset
Time slot / recovery60–120 µs / at least 1 µsStandard-speed transactions
Write-zero LOW60–120 µsHold the bus LOW for the slot
Write-one LOW1–15 µsRelease the bus for the rest of the slot
Read data validWithin 15 µsSample within the specified read window
Strong pullup enableWithin 10 µsAfter Convert T or Copy Scratchpad in parasite mode
EEPROM copy2 ms typical · 10 ms maximumKeep required parasite pullup active

Conversion time and bus bit timing are separate. Releasing the line means high impedance, with the external resistor raising DQ.

Bus levels and power

Manufacturer test conditions

ParameterValueConditions / notes
Input LOW−0.3 to +0.8 VLow-voltage parasite presence may require ≤ 0.5 V
Input HIGH, external power2.2 V minimumObserve upper input limit in the electrical table
Input HIGH, parasite power3.0 V minimumRequires suitable pullup supply margin
LOW sink capability4 mA at 0.4 VOpen-drain interface
Standby current750 nA typical · 1 µA maximumSpecified to +70°C; typically 3 µA at +125°C
Conversion / EEPROM current1 mA typical · 1.5 mA maximumVDD = 5 V
EEPROM endurance50,000 writes−55 to +55°C
EEPROM retention10 years−55 to +55°C
Any pin absolute stress−0.5 to +6.0 VNot a normal operating range

A weak pullup alone cannot supply the worst-case conversion current in parasite mode. Use a strong pullup for the full operation.

Physical pin correspondence

TO-92 and SOIC are not pin-for-pin equivalents

ParameterValueConditions / notes
GNDTO-92: 1 · SOIC: 5Common return
DQTO-92: 2 · SOIC: 4Bidirectional 1-Wire
VDDTO-92: 3 · SOIC: 3External power or GND in parasite mode
Not connectedSOIC: 1, 2, 6, 7, 8Leave unused
Another family packageµSOP-8 also existsDifferent pin map; not the SOIC view shown here

Check the selected order code and package orientation before wiring.

Take it into ProTech

Find DS18B20 in the Components Library to place its schematic symbol and connect its pins.

Reference page · circuit simulation model not yet availableOpen ProTech

Component view