From: Guenter Roeck <linux@roeck-us.net>
To: lm-sensors@vger.kernel.org
Subject: Re: [lm-sensors] [PATCH] hwmon: ntc: Improve precision of resistance calculation
Date: Wed, 03 Jun 2015 22:27:57 +0000 [thread overview]
Message-ID: <556F7F6D.8010407@roeck-us.net> (raw)
In-Reply-To: <1433270907-24933-1-git-send-email-chris.lesiak@licor.com>
On 06/02/2015 01:57 PM, Chris Lesiak wrote:
> The function get_ohm_of_thermistor has both the measured voltage and the
> pullup voltage available in microvolts. But it was promptly converting
> both to millivolts before using them to calculate the thermistor
> resistance. That conversion unnecessarily hurt the precision of the
> calculation.
>
> For example, take the ncpXXwb473 connected to 5000 mV and pulled down
> through a 47000 ohm resistor. At 25 C, the resistance of the thermistor
> is 47000 ohms. The measured voltage will be 2500 mV. If we measure
> instead 2501 mV, then the calculated resistance will be 46962 ohms --
> a difference of 38 ohms. So the precision of the resistance estimate
> could be increased by 38X by doing the calculations in microvolts.
>
> Signed-off-by: Chris Lesiak <chris.lesiak@licor.com>
Applied to -next.
Thanks,
Guenter
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
prev parent reply other threads:[~2015-06-03 22:27 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-02 18:48 [lm-sensors] [PATCH] hwmon: ntc: improve precision of resistance calculation Chris Lesiak
2015-06-02 20:19 ` Guenter Roeck
2015-06-02 20:57 ` [lm-sensors] [PATCH] hwmon: ntc: Improve " Chris Lesiak
2015-06-03 22:27 ` Guenter Roeck [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=556F7F6D.8010407@roeck-us.net \
--to=linux@roeck-us.net \
--cc=lm-sensors@vger.kernel.org \
/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.