All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Matt Ranostay <mranostay@gmail.com>
Cc: Jonathan Cameron <jic23@kernel.org>,
	"linux-iio@vger.kernel.org" <linux-iio@vger.kernel.org>
Subject: Re: [RFC] iio: ppm: Add IIO_PPM channel type
Date: Fri, 28 Aug 2015 08:34:26 +0200	[thread overview]
Message-ID: <55E000F2.9000403@metafoo.de> (raw)
In-Reply-To: <CAKzfze_ySetkta6cAHo7yg4mJ49UC+ymdcj6u04xs0rYe8PA_A@mail.gmail.com>

On 08/27/2015 11:40 PM, Matt Ranostay wrote:
> On Thu, Aug 27, 2015 at 8:58 AM, Lars-Peter Clausen <lars@metafoo.de> wrote:
>> On 08/27/2015 05:40 PM, Lars-Peter Clausen wrote:
>>> On 08/27/2015 08:45 AM, Matt Ranostay wrote:
>>>> There are air quality sensors that report data back in parts per million
>>>> of VOC (Volatile Organic Compounds) which are usually indexed from CO2
>>>> or another common pollutant.
>>>>
>>>> This patchset adds an IIO_PPM type because no other channels types fit
>>>> this use case.
>>>
>>> Hm, I'm not sure if parts-per-million is a good channel type. It's more of a
>>> scale. The type would be concentration.[...]
>>
>> Reading a bit more[1], concentration doesn't actually seem to be the right
>> term in this case, the correct term is mole fraction. Maybe we can use that
>> as the type. That also makes it clear that the unit is molecules per molecule.
>>
> Actually we can't use mole fraction for this because we aren't in a
> chemistry lab, and know the other compounds that make up the local
> atmosphere. Besides you'd have to include some insane lookup table for
> molar mass of carbon or whatever VOC being measured :)

I don't think you'd need that. Mole fraction tells you the number of
molecules of something per total number of molecules. You don't need the
mass for this.

But what exactly is the sensor measuring? CO2 (or VOC) molecules per total
number of molecules or number of CO2 molecules in a particular volume?

> 
> IIO_CONCENTRATION could be useful since you could just change the
> scale to make it ppm or ppb or whatever.
> 
>> - Lars
>>
>> [1] https://en.wikipedia.org/wiki/Concentration
> --
> To unsubscribe from this list: send the line "unsubscribe linux-iio" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


  reply	other threads:[~2015-08-28  6:34 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-27  6:45 [RFC] iio: ppm: Add IIO_PPM channel type Matt Ranostay
2015-08-27 15:40 ` Lars-Peter Clausen
2015-08-27 15:58   ` Lars-Peter Clausen
2015-08-27 16:19     ` Jonathan Cameron
2015-08-27 21:40     ` Matt Ranostay
2015-08-28  6:34       ` Lars-Peter Clausen [this message]
2015-08-28  9:05         ` Matt Ranostay
2015-08-28  9:16           ` Lars-Peter Clausen
2015-08-28 16:27             ` Matt Ranostay
2015-08-31  8:06               ` Lars-Peter Clausen
2015-09-04  7:30                 ` Matt Ranostay

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=55E000F2.9000403@metafoo.de \
    --to=lars@metafoo.de \
    --cc=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=mranostay@gmail.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 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.