All of lore.kernel.org
 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: Fri, 14 Feb 2020 13:24:00 +0000	[thread overview]
Message-ID: <20200214132400.7133bcf5@archlinux> (raw)
In-Reply-To: <20200213220407.GA11762@tennantco.com>

On Thu, 13 Feb 2020 16:04:08 -0600
Dylan Howey <Dylan.Howey@tennantco.com> wrote:

> I tried disabling the temperature channel after every raw read, but I'm
> running into some issues. When the channel is disabled the data ready
> bits in ctrl_reg1 won't go high anymore, and I'm doing the dummy read of
> 33h as the datasheet says. Data ready interrupts also stop working. So
> something is not right with this particular hardware. If you leave the
> channel enabled everything works good.
> 
> What are my options? I could implicitly enable the channel the first
> time it is used and leave it on, but it seems bad to leave the channel
> enabled. In that case there would be no other way to disable the channel
> other than to reload the module.
> 
> Maybe an argument passed to the module to enable temperature output or a
> compile time flag to do this?

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).

Assuming we can't confirm that, then compile time is not a good idea.
Could do a module parameter.   The reason we might not want to always
have it on is that it limits the maximum sampling frequency. 
The question is whether anyone actually cares about 800Hz?

If they do we probably need to avoid breaking them so would need a module
parameter to be 'enable temp' rather than the more natural option
of 'disable temp' to be set only by people who need the highest
frequency.

Jonathan
> 


  reply	other threads:[~2020-02-14 13:24 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 [this message]
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

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=20200214132400.7133bcf5@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.