From: Bagas Sanjaya <bagasdotme@gmail.com>
To: Lothar Rubusch <l.rubusch@gmail.com>,
jic23@kernel.org, dlechner@baylibre.com, nuno.sa@analog.com,
andy@kernel.org, corbet@lwn.net, lucas.p.stankus@gmail.com,
lars@metafoo.de, Michael.Hennerich@analog.com
Cc: linux-iio@vger.kernel.org, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 12/12] docs: iio: add ADXL313 accelerometer
Date: Mon, 26 May 2025 10:44:09 +0700 [thread overview]
Message-ID: <aDPjiVNuQyn1_zXc@archie.me> (raw)
In-Reply-To: <20250523223523.35218-13-l.rubusch@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1708 bytes --]
On Fri, May 23, 2025 at 10:35:23PM +0000, Lothar Rubusch wrote:
> +A channel value can be read from its _raw attribute. The value returned is the
> +raw value as reported by the devices. To get the processed value of the channel,
> +apply the following formula:
> +
> +.. code-block:: bash
> +
> + processed value = (_raw + _offset) * _scale
No syntax highlighting should be appropriate for this block.
> +Show accelerometer channels value:
> +
> +.. code-block:: bash
> +
> + root:/sys/bus/iio/devices/iio:device0> cat in_accel_x_raw
> + 2
> + root:/sys/bus/iio/devices/iio:device0> cat in_accel_y_raw
> + -57
> + root:/sys/bus/iio/devices/iio:device0> cat in_accel_z_raw
> + 2
> + root:/sys/bus/iio/devices/iio:device0> cat in_accel_scale
> + 0.009576806
> +
The accelerometer values will be:
> +- X-axis acceleration = in_accel_x_raw * in_accel_scale = 0.0191536 m/s^2
> +- Y-axis acceleration = in_accel_y_raw * in_accel_scale = -0.5458779 m/s^2
> +- Z-axis acceleration = in_accel_z_raw * in_accel_scale = 0.0191536 m/s^2
> +
> +Set calibration offset for accelerometer channels. Note, the calibration will be
> +rounded according to the graduation of LSB units:
"Note that the calibration ..."
> +See ``Documentation/iio/iio_devbuf.rst`` for more information about how buffered
> +data is structured.
> +
> +4. IIO Interfacing Tools
> +========================
> +
> +See ``Documentation/iio/iio_tools.rst`` for the description of the available IIO
Do not inline docs cross-references to make them internal links.
Thanks.
--
An old man doll... just what I always wanted! - Clara
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2025-05-26 3:44 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-23 22:35 [PATCH v3 00/12] iio: accel: adxl313: add power-save on activity/inactivity Lothar Rubusch
2025-05-23 22:35 ` [PATCH v3 01/12] iio: accel: adxl313: add debug register Lothar Rubusch
2025-05-23 22:35 ` [PATCH v3 02/12] iio: accel: adxl313: introduce channel scan_index Lothar Rubusch
2025-05-25 11:32 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 03/12] iio: accel: adxl313: configure scan type for buffer Lothar Rubusch
2025-05-25 12:19 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 04/12] iio: accel: adxl313: make use of regmap cache Lothar Rubusch
2025-05-25 12:22 ` Jonathan Cameron
2025-05-26 20:44 ` Lothar Rubusch
2025-05-23 22:35 ` [PATCH v3 05/12] iio: accel: adxl313: add function to enable measurement Lothar Rubusch
2025-05-25 12:26 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 06/12] iio: accel: adxl313: prepare interrupt handling Lothar Rubusch
2025-05-25 12:33 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 07/12] iio: accel: adxl313: add basic " Lothar Rubusch
2025-05-25 12:48 ` Jonathan Cameron
2025-05-25 12:56 ` Jonathan Cameron
2025-05-28 20:52 ` Lothar Rubusch
2025-05-31 16:33 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 08/12] iio: accel: adxl313: add FIFO watermark Lothar Rubusch
2025-05-25 12:54 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 09/12] iio: accel: adxl313: add activity sensing Lothar Rubusch
2025-05-25 13:03 ` Jonathan Cameron
2025-05-29 16:22 ` Lothar Rubusch
2025-05-31 16:34 ` Jonathan Cameron
2025-05-25 13:09 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 10/12] iio: accel: adxl313: add inactivity sensing Lothar Rubusch
2025-05-25 13:11 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 11/12] iio: accel: adxl313: implement power-save on inactivity Lothar Rubusch
2025-05-25 13:14 ` Jonathan Cameron
2025-05-23 22:35 ` [PATCH v3 12/12] docs: iio: add ADXL313 accelerometer Lothar Rubusch
2025-05-25 13:16 ` Jonathan Cameron
2025-05-26 3:44 ` Bagas Sanjaya [this message]
2025-05-25 12:49 ` [PATCH v3 00/12] iio: accel: adxl313: add power-save on activity/inactivity Jonathan Cameron
2025-05-25 14:54 ` Lothar Rubusch
2025-05-25 17:52 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aDPjiVNuQyn1_zXc@archie.me \
--to=bagasdotme@gmail.com \
--cc=Michael.Hennerich@analog.com \
--cc=andy@kernel.org \
--cc=corbet@lwn.net \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=l.rubusch@gmail.com \
--cc=lars@metafoo.de \
--cc=linux-doc@vger.kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lucas.p.stankus@gmail.com \
--cc=nuno.sa@analog.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).