diff options
author | Luiz Sampaio <sampaio.ime@gmail.com> | 2021-05-20 01:30:45 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-05-21 15:51:33 +0300 |
commit | fd6ec5d79507f99639c94f107e8a98550c9e1cf6 (patch) | |
tree | 6f2c945283a8a2c9e67e7b6968566d2099a0fac6 /Documentation | |
parent | 1f5e7518f063728aee0679c5086b92d8ea429e11 (diff) | |
download | linux-fd6ec5d79507f99639c94f107e8a98550c9e1cf6.tar.xz |
w1: ds2438: adding support for reading page1
Added a sysfs entry to support reading the page1 registers. This registers
contain Elapsed Time Meter (ETM) data, which shows for how long the chip is
on, as well as an Offset Register data, which can be used to calibrate the
current measurement of the chip.
Signed-off-by: Luiz Sampaio <sampaio.ime@gmail.com>
Link: https://lore.kernel.org/r/20210519223046.13798-6-sampaio.ime@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/ABI/stable/sysfs-driver-w1_ds2438 | 6 | ||||
-rw-r--r-- | Documentation/w1/slaves/w1_ds2438.rst | 8 |
2 files changed, 14 insertions, 0 deletions
diff --git a/Documentation/ABI/stable/sysfs-driver-w1_ds2438 b/Documentation/ABI/stable/sysfs-driver-w1_ds2438 new file mode 100644 index 000000000000..fa47437c11d9 --- /dev/null +++ b/Documentation/ABI/stable/sysfs-driver-w1_ds2438 @@ -0,0 +1,6 @@ +What: /sys/bus/w1/devices/.../page1 +Date: April 2021 +Contact: Luiz Sampaio <sampaio.ime@gmail.com> +Description: read the contents of the page1 of the DS2438 + see Documentation/w1/slaves/w1_ds2438.rst for detailed information +Users: any user space application which wants to communicate with DS2438 diff --git a/Documentation/w1/slaves/w1_ds2438.rst b/Documentation/w1/slaves/w1_ds2438.rst index a29309a3f8e5..ac8d0d4b0d0e 100644 --- a/Documentation/w1/slaves/w1_ds2438.rst +++ b/Documentation/w1/slaves/w1_ds2438.rst @@ -44,6 +44,14 @@ Internally when this file is read, the additional CRC byte is also obtained from the slave device. If it is correct, the 8 bytes page data are passed to userspace, otherwise an I/O error is returned. +"page1" +------- +This file provides full 8 bytes of the chip Page 1 (01h). +This page contains the ICA, elapsed time meter and current offset data of the DS2438. +Internally when this file is read, the additional CRC byte is also obtained +from the slave device. If it is correct, the 8 bytes page data are passed +to userspace, otherwise an I/O error is returned. + "temperature" ------------- Opening and reading this file initiates the CONVERT_T (temperature conversion) |