xref: /linux/Documentation/hwmon/lm90.rst (revision d30c1683aaecb93d2ab95685dc4300a33d3cea7a)
1Kernel driver lm90
2==================
3
4Supported chips:
5
6  * National Semiconductor LM84
7
8    Prefix: 'lm84'
9
10    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
11
12    Datasheet: Publicly available at the TI website
13
14	       https://www.ti.com/lit/ds/symlink/lm84.pdf
15
16  * National Semiconductor LM90
17
18    Prefix: 'lm90'
19
20    Addresses scanned: I2C 0x4c
21
22    Datasheet: Publicly available at the TI website
23
24	       https://www.ti.com/lit/ds/symlink/lm90.pdf
25
26  * National Semiconductor LM89
27
28    Prefix: 'lm89' (no auto-detection)
29
30    Addresses scanned: I2C 0x4c and 0x4d
31
32    Datasheet: Publicly available at the TI website
33
34	       https://www.ti.com/lit/ds/symlink/lm89.pdf
35
36  * National Semiconductor LM99
37
38    Prefix: 'lm99'
39
40    Addresses scanned: I2C 0x4c and 0x4d
41
42    Datasheet: Publicly available at the TI website
43
44	       https://www.ti.com/lit/ds/symlink/lm99.pdf
45
46  * National Semiconductor LM86
47
48    Prefix: 'lm86'
49
50    Addresses scanned: I2C 0x4c
51
52    Datasheet: Publicly available at the TI website
53
54	       https://www.ti.com/lit/ds/symlink/lm86.pdf
55
56  * Analog Devices ADM1020
57
58    Prefix: 'adm1020'
59
60    Addresses scanned: I2C 0x4c - 0x4e
61
62    Datasheet: Publicly available at the DigiKey website
63
64	       https://media.digikey.com/pdf/Data%20Sheets/Analog%20Devices%20PDFs/ADM1020.pdf
65
66  * Analog Devices ADM1021
67
68    Prefix: 'adm1021'
69
70    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
71
72    Datasheet: Publicly available at the DigiKey website
73
74	       https://media.digikey.com/pdf/Data%20Sheets/Analog%20Devices%20PDFs/ADM1021.pdf
75
76  * Analog Devices ADM1021A/ADM1023
77
78    Prefix: 'adm1023'
79
80    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
81
82    Datasheet: Publicly available at the Analog Devices website
83
84	       https://media.digikey.com/pdf/Data%20Sheets/Analog%20Devices%20PDFs/ADM1021A.pdf
85	       https://media.digikey.com/pdf/Data%20Sheets/Analog%20Devices%20PDFs/ADM1023.pdf
86
87  * Analog Devices ADM1032
88
89    Prefix: 'adm1032'
90
91    Addresses scanned: I2C 0x4c and 0x4d
92
93    Datasheet: Publicly available at the DigiKey website
94
95	       https://www.digikey.com/htmldatasheets/production/53140/0/0/1/ADM1032.pdf
96
97  * Analog Devices ADT7461
98
99    Prefix: 'adt7461'
100
101    Addresses scanned: I2C 0x4c and 0x4d
102
103    Datasheet: Publicly available at the ON Semiconductor website
104
105	       https://www.onsemi.com/PowerSolutions/product.do?id=ADT7461
106
107  * Analog Devices ADT7461A
108
109    Prefix: 'adt7461a'
110
111    Addresses scanned: I2C 0x4c and 0x4d
112
113    Datasheet: Publicly available at the ON Semiconductor website
114
115	       https://www.onsemi.com/PowerSolutions/product.do?id=ADT7461A
116
117  * Analog Devices ADT7481
118
119    Prefix: 'adt7481'
120
121    Addresses scanned: I2C 0x4b and 0x4c
122
123    Datasheet: Publicly available at the DigiKey website
124
125	       https://www.digikey.com/htmldatasheets/production/234607/0/0/1/ADT7481.pdf
126
127  * Analog Devices ADT7482
128
129    Prefix: 'adt7482'
130
131    Addresses scanned: I2C 0x4c
132
133    Datasheet: Publicly available at the ON Semiconductor website
134
135	       https://www.onsemi.com/PowerSolutions/product.do?id=ADT7482
136
137  * Analog Devices ADT7483A
138
139    Prefix: 'adt7483a'
140
141    Addresses scanned: I2C 0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b, 0x4c, 0x4d, 0x4e
142
143    Datasheet: Publicly available at the ON Semiconductor website
144
145	       https://www.onsemi.com/PowerSolutions/product.do?id=ADT7483A
146
147  * ON Semiconductor NCT1008
148
149    Prefix: 'nct1008'
150
151    Addresses scanned: I2C 0x4c and 0x4d
152
153    Datasheet: Publicly available at the ON Semiconductor website
154
155	       https://www.onsemi.com/PowerSolutions/product.do?id=NCT1008
156
157  * ON Semiconductor NCT210
158
159    Prefix: 'adm1021'
160
161    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
162
163    Datasheet: Publicly available at the ON Semiconductor website
164
165	       https://www.onsemi.com/PowerSolutions/product.do?id=NCT210
166
167  * ON Semiconductor NCT214
168
169    Prefix: 'nct214'
170
171    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
172
173    Datasheet: Publicly available at the ON Semiconductor website
174
175	       https://www.onsemi.com/PowerSolutions/product.do?id=NCT214
176
177  * ON Semiconductor NCT218
178
179    Prefix: 'nct218'
180
181    Addresses scanned: I2C 0x4c - 0x4d
182
183    Datasheet: Publicly available at the ON Semiconductor website
184
185	       https://www.onsemi.com/PowerSolutions/product.do?id=NCT218
186
187  * ON Semiconductor NCT72
188
189    Prefix: 'nct72'
190
191    Addresses scanned: I2C 0x4c - 0x4d
192
193    Datasheet: Publicly available at the ON Semiconductor website
194
195	       https://www.onsemi.com/PowerSolutions/product.do?id=NCT72
196
197  * Maxim MAX1617
198
199    Prefix: 'max1617'
200
201    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
202
203    Datasheet: Publicly available at the Analog Devices website
204
205	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX1617.pdf
206
207  * Maxim MAX1617A
208
209    Prefix: 'max1617a'
210
211    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
212
213    Datasheet: Publicly available at the Analog Devices website
214
215	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX1617A.pdf
216
217  * Maxim MAX6642
218
219    Prefix: 'max6642'
220
221    Addresses scanned: I2C 0x48-0x4f
222
223    Datasheet: Publicly available at the Analog Devices website
224
225	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6642.pdf
226
227  * Maxim MAX6646
228
229    Prefix: 'max6646'
230
231    Addresses scanned: I2C 0x4d
232
233    Datasheet: Publicly available at the Analog Devices website
234
235	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6646-MAX6649.pdf
236
237  * Maxim MAX6647
238
239    Prefix: 'max6646'
240
241    Addresses scanned: I2C 0x4e
242
243    Datasheet: Publicly available at the Analog Devices website
244
245	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6646-MAX6649.pdf
246
247  * Maxim MAX6648
248
249    Prefix: 'max6648'
250
251    Addresses scanned: I2C 0x4c
252
253    Datasheet: Publicly available at the Analog Devices website
254
255	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6648-MAX6692.pdf
256
257  * Maxim MAX6649
258
259    Prefix: 'max6646'
260
261    Addresses scanned: I2C 0x4c
262
263    Datasheet: Publicly available at the Analog Devices website
264
265	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX1617.pdf
266
267  * Maxim MAX6654
268
269    Prefix: 'max6654'
270
271    Addresses scanned: I2C 0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b,
272
273			   0x4c, 0x4d and 0x4e
274
275    Datasheet: Publicly available at the Analog Devices website
276
277	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6654.pdf
278
279  * Maxim MAX6657
280
281    Prefix: 'max6657'
282
283    Addresses scanned: I2C 0x4c
284
285    Datasheet: Publicly available at the Analog Devices website
286
287	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6657-MAX6659.pdf
288
289  * Maxim MAX6658
290
291    Prefix: 'max6657'
292
293    Addresses scanned: I2C 0x4c
294
295    Datasheet: Publicly available at the Analog Devices website
296
297	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6657-MAX6659.pdf
298
299  * Maxim MAX6659
300
301    Prefix: 'max6659'
302
303    Addresses scanned: I2C 0x4c, 0x4d, 0x4e
304
305    Datasheet: Publicly available at the Analog Devices website
306
307	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6657-MAX6659.pdf
308
309  * Maxim MAX6680
310
311    Prefix: 'max6680'
312
313    Addresses scanned: I2C 0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b,
314
315			   0x4c, 0x4d and 0x4e
316
317    Datasheet: Publicly available at the Analog Devices website
318
319	      https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6680-MAX6681.pdf
320
321  * Maxim MAX6681
322
323    Prefix: 'max6680'
324
325    Addresses scanned: I2C 0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b,
326
327			   0x4c, 0x4d and 0x4e
328
329    Datasheet: Publicly available at the Analog Devices website
330
331	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6680-MAX6681.pdf
332
333  * Maxim MAX6692
334
335    Prefix: 'max6648'
336
337    Addresses scanned: I2C 0x4c
338
339    Datasheet: Publicly available at the Analog Devices website
340
341	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6648-MAX6692.pdf
342
343  * Maxim MAX6695
344
345    Prefix: 'max6695'
346
347    Addresses scanned: I2C 0x18
348
349    Datasheet: Publicly available at the Analog Devices website
350
351	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6695-MAX6696.pdf
352
353  * Maxim MAX6696
354
355    Prefix: 'max6695'
356
357    Addresses scanned: I2C 0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b,
358
359			   0x4c, 0x4d and 0x4e
360
361    Datasheet: Publicly available at the Analog Devices website
362
363	       https://www.analog.com/media/en/technical-documentation/data-sheets/MAX6695-MAX6696.pdf
364
365  * Winbond/Nuvoton W83L771W/G
366
367    Prefix: 'w83l771'
368
369    Addresses scanned: I2C 0x4c
370
371    Datasheet: Publicly available at the DigiKey website
372
373	       https://mm.digikey.com/Volume0/opasdata/d220001/medias/docus/1128/W83L771W%2CW83L771G.pdf
374
375  * Winbond/Nuvoton W83L771AWG/ASG
376
377    Prefix: 'w83l771'
378
379    Addresses scanned: I2C 0x4c
380
381    Datasheet: Not publicly available, can be requested from Nuvoton
382
383  * Nuvoton NCT7716
384
385    Prefix: 'nct7716'
386
387    Addresses scanned: I2C 0x48, 0x49
388
389    Datasheet: Not publicly available, can be requested from Nuvoton
390
391  * Nuvoton NCT7717
392
393    Prefix: 'nct7717'
394
395    Addresses scanned: I2C 0x48
396
397    Datasheet: Publicly available at Nuvoton website
398
399	       https://www.nuvoton.com/resource-files/Nuvoton_NCT7717U_Datasheet_V111.pdf
400
401  * Nuvoton NCT7718
402
403    Prefix: 'nct7718'
404
405    Addresses scanned: I2C 0x4c
406
407    Datasheet: Publicly available at Nuvoton website
408
409	       https://www.nuvoton.com/resource-files/Nuvoton_NCT7718W_Datasheet_V11.pdf
410
411  * Philips/NXP SA56004X
412
413    Prefix: 'sa56004'
414
415    Addresses scanned: I2C 0x48 through 0x4F
416
417    Datasheet: Publicly available at NXP website
418
419	       https://www.nxp.com/docs/en/data-sheet/SA56004X.pdf
420
421  * GMT G781
422
423    Prefix: 'g781'
424
425    Addresses scanned: I2C 0x4c, 0x4d
426
427    Datasheet: Not publicly available from GMT
428
429  * Texas Instruments TMP451
430
431    Prefix: 'tmp451'
432
433    Addresses scanned: I2C 0x4c
434
435    Datasheet: Publicly available at TI website
436
437	       https://www.ti.com/litv/pdf/sbos686
438
439  * Texas Instruments TMP461
440
441    Prefix: 'tmp461'
442
443    Addresses scanned: I2C 0x48 through 0x4F
444
445    Datasheet: Publicly available at TI website
446
447	       https://www.ti.com/lit/gpn/tmp461
448
449  * Philips NE1617, NE1617A
450
451    Prefix: 'max1617' (probably detected as a max1617)
452
453    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
454
455    Datasheets: Publicly available at the DigiKey website
456
457	       https://www.digikey.com/htmldatasheets/production/97606/0/0/1/ne1617.pdf
458
459  * Philips NE1618
460
461    Prefix: 'ne1618'
462
463    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
464
465    Datasheets: Publicly available at the DigiKey website
466
467	       https://media.digikey.com/pdf/Data%20Sheets/NXP%20PDFs/NE1618.pdf
468
469  * Genesys Logic GL523SM
470
471    Prefix: 'gl523sm'
472
473    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
474
475    Datasheet: No longer available at Genesys Logic website
476
477  * TI THMC10
478
479    Prefix: 'thmc10'
480
481    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
482
483    Datasheet: No longer available at the TI website
484
485  * Onsemi MC1066
486
487    Prefix: 'mc1066'
488
489    Addresses scanned: I2C 0x18 - 0x1a, 0x29 - 0x2b, 0x4c - 0x4e
490
491    Datasheet: No longer available at the Onsemi website
492
493Author: Jean Delvare <jdelvare@suse.de>
494
495
496Description
497-----------
498
499The LM90 is a digital temperature sensor. It senses its own temperature as
500well as the temperature of up to one external diode. It is compatible
501with many other devices, many of which are supported by this driver.
502
503The family of chips supported by this driver is derived from MAX1617.
504This chip as well as various compatible chips support a local and a remote
505temperature sensor with 8 bit accuracy. Later chips provide improved accuracy
506and other additional features such as hysteresis and temperature offset
507registers.
508
509Note that there is no easy way to differentiate between the MAX6657,
510MAX6658 and MAX6659 variants. The extra features of the MAX6659 are only
511supported by this driver if the chip is located at address 0x4d or 0x4e,
512or if the chip type is explicitly selected as max6659.
513The MAX6680 and MAX6681 only differ in their pinout, therefore they obviously
514can't (and don't need to) be distinguished.
515
516The different chipsets of the family are not strictly identical, although
517very similar. For reference, here comes a non-exhaustive list of specific
518features:
519
520LM84:
521  * 8 bit sensor resolution
522
523ADM1020, ADM1021, GL523SM, MAX1617, NE1617, NE1617A, THMC10:
524  * 8 bit sensor resolution
525  * Low temperature limits
526
527NCT210, NE1618:
528  * 11 bit sensor resolution for remote temperature sensor
529  * Low temperature limits
530
531ADM1021A, ADM1023:
532  * Temperature offset register for remote temperature sensor
533  * 11 bit resolution for remote temperature sensor
534  * Low temperature limits
535
536LM90:
537  * 11 bit resolution for remote temperature sensor
538  * Temperature offset register for remote temperature sensor
539  * Low and critical temperature limits
540  * Configurable conversion rate
541  * Filter and alert configuration register at 0xBF.
542  * ALERT is triggered by temperatures over critical limits.
543
544LM86 and LM89:
545  * Same as LM90
546  * Better external channel accuracy
547
548LM99:
549  * Same as LM89
550  * External temperature shifted by 16 degrees down
551
552ADM1032:
553  * Consecutive alert register at 0x22.
554  * Conversion averaging.
555  * Up to 64 conversions/s.
556  * ALERT is triggered by open remote sensor.
557  * SMBus PEC support for Write Byte and Receive Byte transactions.
558
559ADT7461, ADT7461A, NCT1008:
560  * Extended temperature range (breaks compatibility)
561  * Lower resolution for remote temperature
562  * SMBus PEC support for Write Byte and Receive Byte transactions.
563  * 10 bit temperature resolution
564
565ADT7481, ADT7482, ADT7483:
566  * Temperature offset register
567  * SMBus PEC support
568  * 10 bit temperature resolution for external sensors
569  * Two remote sensors
570  * Selectable address (ADT7483)
571
572MAX6642:
573  * No critical limit register
574  * Conversion rate not configurable
575  * Better local resolution (10 bit)
576  * 10 bit external sensor resolution
577
578MAX6646, MAX6647, MAX6649:
579  * Better local resolution
580  * Extended range unsigned external temperature
581
582MAX6648, MAX6692:
583  * Better local resolution
584  * Unsigned temperature
585
586MAX6654, MAX6690:
587  * Better local resolution
588  * Selectable address
589  * Remote sensor type selection
590  * Extended temperature range
591  * Extended resolution only available when conversion rate <= 1 Hz
592
593MAX6657 and MAX6658:
594  * Better local resolution
595  * Remote sensor type selection
596
597MAX6659:
598  * Better local resolution
599  * Selectable address
600  * Second critical temperature limit
601  * Remote sensor type selection
602
603MAX6680 and MAX6681:
604  * Selectable address
605  * Remote sensor type selection
606
607MAX6695 and MAX6696:
608  * Better local resolution
609  * Selectable address (max6696)
610  * Second critical temperature limit
611  * Two remote sensors
612
613W83L771W/G
614  * The G variant is lead-free, otherwise similar to the W.
615  * Filter and alert configuration register at 0xBF
616  * Moving average (depending on conversion rate)
617
618W83L771AWG/ASG
619  * Successor of the W83L771W/G, same features.
620  * The AWG and ASG variants only differ in package format.
621  * Diode ideality factor configuration (remote sensor) at 0xE3
622
623NCT7716:
624  * 8 bit sensor resolution
625  * Selectable address
626  * Configurable conversion rate
627
628NCT7717:
629  * 8 bit sensor resolution
630  * Configurable conversion rate
631
632NCT7718:
633  * Temperature offset register for remote temperature sensor
634  * 11 bit resolution for remote temperature sensor
635  * Low temperature limits
636  * Configurable conversion rate
637
638SA56004X:
639  * Better local resolution
640
641All temperature values are given in degrees Celsius. Resolution
642is 1.0 degree for the local temperature, 0.125 degree for the remote
643temperature, except for the MAX6654, MAX6657, MAX6658 and MAX6659 which have
644a resolution of 0.125 degree for both temperatures.
645
646Each sensor has its own high and low limits, plus a critical limit.
647Additionally, there is a relative hysteresis value common to both critical
648values. To make life easier to user-space applications, two absolute values
649are exported, one for each channel, but these values are of course linked.
650Only the local hysteresis can be set from user-space, and the same delta
651applies to the remote hysteresis.
652
653The lm90 driver will not update its values more frequently than configured with
654the update_interval attribute; reading them more often will do no harm, but will
655return 'old' values.
656
657SMBus Alert Support
658-------------------
659
660This driver has basic support for SMBus alert. When an alert is received,
661the status register is read and the faulty temperature channel is logged.
662
663The Analog Devices chips (ADM1032, ADT7461 and ADT7461A) and ON
664Semiconductor chips (NCT1008) do not implement the SMBus alert protocol
665properly so additional care is needed: the ALERT output is disabled when
666an alert is received, and is re-enabled only when the alarm is gone.
667Otherwise the chip would block alerts from other chips in the bus as long
668as the alarm is active.
669
670PEC Support
671-----------
672
673The ADM1032 is the only chip of the family which supports PEC. It does
674not support PEC on all transactions though, so some care must be taken.
675
676When reading a register value, the PEC byte is computed and sent by the
677ADM1032 chip. However, in the case of a combined transaction (SMBus Read
678Byte), the ADM1032 computes the CRC value over only the second half of
679the message rather than its entirety, because it thinks the first half
680of the message belongs to a different transaction. As a result, the CRC
681value differs from what the SMBus master expects, and all reads fail.
682
683For this reason, the lm90 driver will enable PEC for the ADM1032 only if
684the bus supports the SMBus Send Byte and Receive Byte transaction types.
685These transactions will be used to read register values, instead of
686SMBus Read Byte, and PEC will work properly.
687
688Additionally, the ADM1032 doesn't support SMBus Send Byte with PEC.
689Instead, it will try to write the PEC value to the register (because the
690SMBus Send Byte transaction with PEC is similar to a Write Byte transaction
691without PEC), which is not what we want. Thus, PEC is explicitly disabled
692on SMBus Send Byte transactions in the lm90 driver.
693
694PEC on byte data transactions represents a significant increase in bandwidth
695usage (+33% for writes, +25% for reads) in normal conditions. With the need
696to use two SMBus transaction for reads, this overhead jumps to +50%. Worse,
697two transactions will typically mean twice as much delay waiting for
698transaction completion, effectively doubling the register cache refresh time.
699I guess reliability comes at a price, but it's quite expensive this time.
700
701So, as not everyone might enjoy the slowdown, PEC is disabled by default and
702can be enabled through sysfs. Just write 1 to the "pec" file and PEC will be
703enabled. Write 0 to that file to disable PEC again.
704