1DS18B20(3)                   One-Wire File System                   DS18B20(3)
2
3
4

NAME

6       DS18B20
7              - Programmable Resolution 1-Wire Digital Thermometer
8
9       MAX31820
10              - Ambient Temperature Sensor
11

SYNOPSIS

13       Thermometer.
14
15       28  [.]XXXXXXXXXXXX[XX][/[ fasttemp | temperature | temperature9 | tem‐
16       perature10 | temperature11 | temperature12 | latesttemp | die | power |
17       temphigh  | templow | tempres | errata/die | errata/trim | errata/trim‐
18       blanket | errata/trimvalid | address | crc8 | id | locator |  r_address
19       | r_id | r_locator | type ]]
20

FAMILY CODE

22       28
23

SPECIAL PROPERTIES

25   power
26       read-only,yes-no
27       Is  the chip powered externally (=1) or from the parasitically from the
28       data bus (=0)?
29
30   temperature
31       read-only, floating point
32       Measured temperature with 12 bit resolution.
33
34   temperature9 temperature10 temperature11 temperature12
35       read-only, floating point
36       Measured temperature at 9 to 12 bit resolution. There is a tradeoff  of
37       time versus accuracy in the temperature measurement.
38
39   latesttemp
40       read-only, floating point
41       Measured  temperature at 9 to 12 bit resolution, depending on the reso‐
42       lution of the latest conversion on this chip. Reading  this  node  will
43       never trigger a temperature conversion. Intended for use in conjunction
44       with /simultaneous/temperature.
45
46   fasttemp
47       read-only, floating point
48       Equivalent to temperature9
49

TEMPERATURE ALARM LIMITS

51       When the device exceeds either temphigh or templow temperature  thresh‐
52       old  the device is in the alarm state, and will appear in the alarm di‐
53       rectory. This provides an easy way to poll for  temperatures  that  are
54       unsafe, especially if simultaneous temperature conversion is done.
55
56       Units for the temperature alarms are in the same temperature scale that
57       was set for temperature measurements.
58
59       Temperature thresholds are stored in non-volatile  memory  and  persist
60       until changed, even if power is lost.
61
62   temphigh
63       read-write, integer
64       Shows or sets the lower limit for the high temperature alarm state.
65
66   templow
67       read-write, integer
68       Shows or sets the upper limit for the low temperature alarm state.
69

TEMPERATURE RESOLUTION DEFAULT VALUE

71   tempres
72       read-write, integer
73       The  device employs a non-volatile memory to store the default tempera‐
74       ture resolution (9, 10, 11 or 12 bits) to be  applied  after  power-up.
75       This is useful if you use simultaneous temperature conversions. Reading
76       this node gives you the value stored in the non-volatile memory.  Writ‐
77       ing sets a new power-on resolution value.
78
79       As  a  side effect, reading this node resets the temperature resolution
80       used by simultaneous temperature conversions to its power-on value.  It
81       also affects the resolution value used by latesttemp, to scale the lat‐
82       est conversion value, so make sure to re-sample the temperature  before
83       accessing latesttemp after writing or reading the tempres value.
84

TEMPERATURE ERRATA

86       There  are  a  group  of obscure internal properties exposed to protect
87       against an hardware defect in certain batches of the  B7  die  of  some
88       DS18x20  chips.  See  http://www.1wire.org/en-us/pg_18.html  or request
89       AN247.pdf from Dallas directly.
90
91   errata/die
92       read-only,ascii
93       Two character manufacturing die lot. "B6" "B7" or "C2"
94
95   errata/trim
96       read-write,unsigned integer
97       32 bit trim value in the EEPROM of the chip. When written, it does  not
98       seem to read back. Used for a production problem in the B7 die.
99
100       Read allowed for all chips. Only the B7 chips can be written.
101
102   errata/trimblanket
103       read-write,yes-no
104       Writing  non-zero  (=1) puts a default trim value in the chip. Only ap‐
105       plied to the B7 die.  Reading will be true (non-zero) if trim value  is
106       the  blanket  value. Again, only B7 chips will register true, and since
107       the written trim values cannot be read,  this  value  may  have  little
108       utility.
109
110   errata/trimvalid
111       read-only,yes-no
112       Is  the trim value in the valid range? Non-zero if true, which includes
113       all non-B7 chips.
114

STANDARD PROPERTIES

116   address
117   r_address
118       read-only, ascii
119       The entire 64-bit unique ID. Given as  upper  case  hexadecimal  digits
120       (0-9A-F).
121       address starts with the family code
122       r address is the address in reverse order, which is often used in other
123       applications and labeling.
124
125   crc8
126       read-only, ascii
127       The 8-bit error correction portion. Uses cyclic redundancy check.  Com‐
128       puted  from the preceding 56 bits of the unique ID number. Given as up‐
129       per case hexadecimal digits (0-9A-F).
130
131   family
132       read-only, ascii
133       The 8-bit family code. Unique to each type of device.  Given  as  upper
134       case hexadecimal digits (0-9A-F).
135
136   id
137   r_id
138       read-only, ascii
139       The 48-bit middle portion of the unique ID number. Does not include the
140       family code or CRC. Given as upper case hexadecimal digits (0-9A-F).
141       r id is the id in reverse order, which is often used in other  applica‐
142       tions and labeling.
143
144   locator
145   r_locator
146       read-only, ascii
147       Uses  an  extension  of the 1-wire design from iButtonLink company that
148       associated 1-wire physical connections with a unique  1-wire  code.  If
149       the  connection is behind a Link Locator the locator will show a unique
150       8-byte number (16 character hexadecimal) starting with family code FE.
151       If no Link Locator is between the device and the  master,  the  locator
152       field will be all FF.
153       r locator is the locator in reverse order.
154
155   present (DEPRECATED)
156       read-only, yes-no
157       Is the device currently present on the 1-wire bus?
158
159   type
160       read-only, ascii
161       Part  name  assigned by Dallas Semi. E.g.  DS2401 Alternative packaging
162       (iButton vs chip) will not be distiguished.
163

DESCRIPTION

165   1-Wire
166       1-wire is a wiring protocol and series of devices designed and manufac‐
167       tured  by  Dallas  Semiconductor, Inc. The bus is a low-power low-speed
168       low-connector scheme where the data line can also provide power.
169
170       Each device is uniquely and unalterably  numbered  during  manufacture.
171       There  are a wide variety of devices, including memory, sensors (humid‐
172       ity, temperature, voltage, contact, current), switches, timers and data
173       loggers.  More complex devices (like thermocouple sensors) can be built
174       with these basic devices. There are also 1-wire devices that  have  en‐
175       cryption included.
176
177       The  1-wire  scheme uses a single bus master and multiple slaves on the
178       same wire. The bus master initiates all communication. The  slaves  can
179       be individually discovered and addressed using their unique ID.
180
181       Bus  masters come in a variety of configurations including serial, par‐
182       allel, i2c, network or USB adapters.
183
184   OWFS design
185       OWFS is a suite of programs that designed to make the  1-wire  bus  and
186       its  devices easily accessible. The underlying principle is to create a
187       virtual filesystem, with the unique ID being the directory, and the in‐
188       dividual  properties of the device are represented as simple files that
189       can be read and written.
190
191       Details of the individual slave or master design are  hidden  behind  a
192       consistent interface. The goal is to provide an easy set of tools for a
193       software designer to create monitoring or control  applications.  There
194       are some performance enhancements in the implementation, including data
195       caching, parallel access to bus masters, and aggregation of device com‐
196       munication.  Still the fundamental goal has been ease of use, flexibil‐
197       ity and correctness rather than speed.
198
199   DS18B20
200       The DS18B20 (3) is one of several available 1-wire temperature sensors.
201       It  is  the replacement for the DS18S20 (3) Alternatives are DS1822 (3)
202       as well as temperature/voltage  measurements  in  the  DS2436  (3)  and
203       DS2438 (3).  For truly versatile temperature measurements, see the pro‐
204       tean DS1921 (3) Thermachron (3).
205
206       The MAX31820 is functionally identical to the DS18B20 except  for  it's
207       voltage requirements.
208       The DS18B20 (3) can select between 4 resolutions. In general, high res‐
209       olution is the best choice unless your application is  truly  time-con‐
210       strained.
211

ADDRESSING

213       All  1-wire  devices are factory assigned a unique 64-bit address. This
214       address is of the form:
215
216       Family Code
217              8 bits
218
219       Address
220              48 bits
221
222       CRC    8 bits
223
224       Addressing under OWFS is in hexadecimal, of form:
225
226              01.123456789ABC
227
228       where 01 is an example 8-bit family code, and 12345678ABC is an example
229       48 bit address.
230
231       The  dot  is  optional,  and the CRC code can included. If included, it
232       must be correct.
233

DATASHEET

235       http://pdfserv.maxim-ic.com/en/ds/DS18B20.pdf
236

SEE ALSO

238   Programs
239       owfs (1) owhttpd (1) owftpd (1)  owserver  (1)  owdir  (1)  owread  (1)
240       owwrite (1) owpresent (1) owtap (1)
241
242   Configuration and testing
243       owfs (5) owtap (1) owmon (1)
244
245   Language bindings
246       owtcl (3) owperl (3) owcapi (3)
247
248   Clocks
249       DS1427  (3)  DS1904  (3)  DS1994  (3) DS2404 (3) DS2404S (3) DS2415 (3)
250       DS2417 (3)
251
252   ID
253       DS2401 (3) DS2411 (3) DS1990A (3)
254
255   Memory
256       DS1982 (3) DS1985 (3) DS1986 (3)  DS1991  (3)  DS1992  (3)  DS1993  (3)
257       DS1995  (3)  DS1996  (3)  DS2430A  (3) DS2431 (3) DS2433 (3) DS2502 (3)
258       DS2506 (3) DS28E04 (3) DS28EC20 (3)
259
260   Switches
261       DS2405 (3) DS2406 (3) DS2408 (3) DS2409 (3) DS2413 (3) DS28EA00 (3) In‐
262       fernoEmbedded (3)
263
264   Temperature
265       DS1822  (3)  DS1825  (3)  DS1820 (3) DS18B20 (3) DS18S20 (3) DS1920 (3)
266       DS1921 (3) DS1821 (3) DS28EA00 (3) DS28E04 (3) EDS0064 (3) EDS0065  (3)
267       EDS0066  (3)  EDS0067  (3) EDS0068 (3) EDS0071 (3) EDS0072 (3) MAX31826
268       (3)
269
270   Humidity
271       DS1922 (3) DS2438 (3) EDS0065 (3) EDS0068 (3)
272
273   Voltage
274       DS2450 (3)
275
276   Resistance
277       DS2890 (3)
278
279   Multifunction (current, voltage, temperature)
280       DS2436 (3) DS2437 (3) DS2438 (3)  DS2751  (3)  DS2755  (3)  DS2756  (3)
281       DS2760 (3) DS2770 (3) DS2780 (3) DS2781 (3) DS2788 (3) DS2784 (3)
282
283   Counter
284       DS2423 (3)
285
286   LCD Screen
287       LCD (3) DS2408 (3)
288
289   Crypto
290       DS1977 (3)
291
292   Pressure
293       DS2406 (3) TAI8570 (3) EDS0066 (3) EDS0068 (3)
294
295   Moisture
296       EEEF (3) DS2438 (3)
297

AVAILABILITY

299       http://www.owfs.org
300

AUTHOR

302       Paul Alfille (paul.alfille@gmail.com)
303
304
305
306OWFS Manpage                         2003                           DS18B20(3)
Impressum