DS18S20
13 of 23
1-WIRE SIGNALING
The DS18S20 uses a strict 1-Wire communication protocol to ensure data integrity. Several signal types
are defined by this protocol: reset pulse, presence pulse, write 0, write 1, read 0, and read 1. All these
signals, with the exception of the presence pulse, are initiated by the bus master.
INITIALIZATION PROCEDURERESET AND PRESENCE PULSES
All communication with the DS18S20 begins with an initialization sequence that consists of a reset pulse
from the master followed by a presence pulse from the DS18S20. This is illustrated in Figure 10. When
the DS18S20 sends the presence pulse in response to the reset, it is indicating to the master that it is on
the bus and ready to operate.
During the initialization sequence the bus master transmits (T
X
) the reset pulse by pulling the 1-Wire bus
low for a minimum of 480µs. The bus master then releases the bus and goes into receive mode (R
X
).
When the bus is released, the 5k pullup resistor pulls the 1-Wire bus high. When the DS18S20 detects
this rising edge, it waits 15µs to 60µs and then transmits a presence pulse by pulling the 1-Wire bus low
for 60µs to 240µs.
Figure 10. Initialization Timing
READ/WRITE TIME SLOTS
The bus master writes data to the DS18S20 during write time slots and reads data from the DS18S20
during read-time slots. One bit of data is transmitted over the 1-Wire bus per time slot.
WRITE TIME SLOTS
There are two types of write time slots: “Write 1” time slots and “Write 0” time slots. The bus master
uses a Write 1 time slot to write a logic 1 to the DS18S20 and a Write 0 time slot to write a logic 0 to the
DS18S20. All write time slots must be a minimum of 60µs in duration with a minimum of a 1µs recovery
time between individual write slots. Both types of write time slots are initiated by the master pulling the
1-Wire bus low (see Figure 11).
To generate a Write 1 time slot, after pulling the 1-Wire bus low, the bus master must release the 1-Wire
bus within 15µs. When the bus is released, the 5k pullup resistor will pull the bus high. To generate a
Write 0 time slot, after pulling the 1-Wire bus low, the bus master must continue to hold the bus low for
the duration of the time slot (at least 60µs). The DS18S20 samples the 1-Wire bus during a window that
lasts from 15µs to 60µs after the master initiates the write time slot. If the bus is high during the sampling
window, a 1 is written to the DS18S20. If the line is low, a 0 is written to the DS18S20.
LINE TYPE LEGEND
Bus master pulling low
DS18S20 pulling low
Resistor pullup
V
PU
GND
1-WIRE BUS
480µs minimum
480µs minimum
DS18S20 T
X
presence pulse
60-240
µ
s
MASTER T
X
RESET PULSE
MASTER R
X
DS18S20
waits 15-60
µ
s
DS18S20
14 of 23
READ-TIME SLOTS
The DS18S20 can only transmit data to the master when the master issues read-time slots. Therefore, the
master must generate read-time slots immediately after issuing a Read Scratchpad [BEh] or Read Power
Supply [B4h] command, so that the DS18S20 can provide the requested data. In addition, the master can
generate read-time slots after issuing Convert T [44h] or Recall E
2
[B8h] commands to find out the status
of the operation as explained in the DS18S20 Function Commands section.
All read-time slots must be a minimum of 60µs in duration with a minimum of a 1µs recovery time
between slots. A read-time slot is initiated by the master device pulling the 1-Wire bus low for a
minimum of 1µs and then releasing the bus (see Figure 11). After the master initiates the read-time slot,
the DS18S20 will begin transmitting a 1 or 0 on bus. The DS18S20 transmits a 1 by leaving the bus high
and transmits a 0 by pulling the bus low. When transmitting a 0, the DS18S20 will release the bus by the
end of the time slot, and the bus will be pulled back to its high idle state by the pullup resister. Output
data from the DS18S20 is valid for 15µs after the falling edge that initiated the read-time slot. Therefore,
the master must release the bus and then sample the bus state within 15µs from the start of the slot.
Figure 12 illustrates that the sum of T
INIT
, T
RC
, and T
SAMPLE
must be less than 15µs for a read-time slot.
Figure 13 shows that system timing margin is maximized by keeping T
INIT
and T
RC
as short as possible
and by locating the master sample time during read-time slots towards the end of the 15µs period.
Figure 11. Read/Write Time Slot Timing Diagram
45
µ
s
15
µ
s
V
PU
GND
1-WIRE BUS
60µs < T
X
0” < 120µs
1
µ
s < T
REC
<
DS18S20
Samples
MIN TYP MAX
15µs
30µs
> 1
µ
s
MASTER WRITE “0” SLOT
MASTER WRITE “1” SLOT
V
PU
GND
1-WIRE BUS
15µs
MASTER READ “0” SLOT
MASTER READ “1” SLOT
Master samples
Master samples
START
OF SLOT
START
OF SLOT
> 1
µ
s
1
µ
s < T
REC
<
15µs
15µs
30µs
15
µ
s
DS18S20 Samples
MIN TYP MAX
> 1µs
LINE TYPE LEGEND
Bus master pulling low DS18S20 pulling low
Resistor pullup
DS18S20
15 of 23
Figure 12. Detailed Master Read 1 Timing
Figure 13. Recommended Master Read 1 Timing
V
PU
GND
1-WIRE BUS
15µs
VIH of Master
T
RC
T
INT
> 1µs
Master samples
LINE TYPE LEGEND
Bus master pulling low
Resistor pullup
V
PU
GND
1-WIRE BUS
15µs
VIH of Master
T
RC
=
small
T
INT
=
small
Master samples

DS18S20Z

Mfr. #:
Manufacturer:
Maxim Integrated
Description:
Board Mount Temperature Sensors 1-Wire Parasite-Power Digital Thermometer
Lifecycle:
New from this manufacturer.
Delivery:
DHL FedEx Ups TNT EMS
Payment:
T/T Paypal Visa MoneyGram Western Union

Products related to this Datasheet