linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Dylan Howey <Dylan.Howey@tennantco.com>
Cc: Hartmut Knaack <knaack.h@gmx.de>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	linux-iio@vger.kernel.org
Subject: Re: [PATCH] iio: accel: mma8452: Expose temperature channel
Date: Sat, 7 Mar 2020 11:20:46 +0000	[thread overview]
Message-ID: <20200307112046.073843ef@archlinux> (raw)
In-Reply-To: <20200224210018.GA937@tennantco.com>

On Mon, 24 Feb 2020 15:00:20 -0600
Dylan Howey <Dylan.Howey@tennantco.com> wrote:

> On 02/14/2020 13:24, Jonathan Cameron wrote:
> > So ideally we'd get someone at Freescale to confirm there is a hardware
> > rather than a documentation issue (i.e. maybe we need some other magic).  
>   
> NXP says there's a documentation issue. CTRL_REG6 can only be written
> when the device is in standby, similar to the other CTRL_REG* registers.
> 
> So I'll need to use mma8452_change_config to set this register. I will
> try this out and send a patch.
> 
> One other detail - the temperature cannot be buffered by the hwfifo.
> If I add hwfifo support, I think the right thing to do would be to
> disable hwfifo implicitly if the temperature channel is enabled and
> fall back to one interrupt per sample.
> 

It's actually fairly uncommon or people to want to sample the temperature
anywhere near as often as acceleration values, so you might be better
off only supporting sysfs polled reads to the temperature channel.

That way there won't be an unusual result of enabling the temperature
channel.

Anyone who wants the temperature (slow changing) can just grab a few
readings alongside using the buffer for the much faster changing
inertial readings.

Jonathan




      reply	other threads:[~2020-03-07 11:20 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-05 20:32 [PATCH] iio: accel: mma8452: Expose temperature channel Dylan Howey
2020-02-08 16:32 ` Jonathan Cameron
2020-02-10 14:26   ` Dylan Howey
2020-02-13 22:04   ` Dylan Howey
2020-02-14 13:24     ` Jonathan Cameron
2020-02-17 14:19       ` Dylan Howey
2020-02-17 18:16         ` Jonathan Cameron
2020-02-24 21:00       ` Dylan Howey
2020-03-07 11:20         ` Jonathan Cameron [this message]

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=20200307112046.073843ef@archlinux \
    --to=jic23@kernel.org \
    --cc=Dylan.Howey@tennantco.com \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=pmeerw@pmeerw.net \
    /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).