Temperature sensor on aiko-gateway.

29 views
Skip to first unread message

Luke Weston

unread,
Feb 7, 2010, 8:31:09 AM2/7/10
to Aiko distributed platform
Hi everyone,

The temperature sensor on my aiko-gateway seems a bit inaccurate (it's
over-reading the temperature).

Has this been experienced much by others?

Is it likely to be nothing more than a packaging / sensor placement
problem?

I assume that the sensors themselves are accurate and the firmware
written by Andy couldn't have a problem (especially since it's reading
a digital protocol), so I think the most reasonable assumption is that
it's entirely a packaging issue, with the sensor being warmed up by
the electronics, warmer than the surrounding environment.

Thoughts?

Paul Szymkowiak

unread,
Feb 7, 2010, 8:51:47 AM2/7/10
to aiko-p...@googlegroups.com
I can't confirm for the Router (I still have Touch Screen fail, so can't see the Temp or LDR readings)

But I can confirm my prototype Pebble has this problem.

I've extended the Sensor out on ~ 6 cm cable, and placed it way off to the right side of the PCB: in my case, out the side of a Jiffy Box.

I'm still reading ~2 degrees hotter than actual. This is compared to the Temp reading function on my DMM, which agrees with a couple of different commercial units.



Cheers,


Paul



--
You received this message because you are subscribed to the Google Groups "Aiko distributed platform" group.
To post to this group, send email to aiko-p...@googlegroups.com.
To unsubscribe from this group, send email to aiko-platfor...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/aiko-platform?hl=en.


Jonathan Oxer

unread,
Feb 7, 2010, 4:11:48 PM2/7/10
to aiko-p...@googlegroups.com
On Mon, 2010-02-08 at 00:51 +1100, Paul Szymkowiak wrote:

> But I can confirm my prototype Pebble has this problem.
>
>
> I've extended the Sensor out on ~ 6 cm cable, and placed it way off to
> the right side of the PCB: in my case, out the side of a Jiffy Box.

When running 6 DS18B20s simultaneously from one shield I've seen typical
variations of 0.5C or so between them, except for one in particular that
always reads about 2.5C higher than the others in the exact same
conditions. This is on leads about 2m long with the sensors sitting in
clear air within 10cm of each other.

At the time I put it down to thermal damage I'd caused during assembly
of that particular unit, but there may be other explanations.

Cheers :-)
--
Jonathan Oxer
Ph +61 4 3851 6600
* Internet Vision Technologies (www.ivt.com.au)
* Practical Arduino (www.practicalarduino.com)
* SuperHouse Automation (www.superhouse.tv)
* Geek My Ride! (www.geekmyride.org)

signature.asc

Sam Sabey

unread,
Feb 7, 2010, 5:20:05 PM2/7/10
to aiko-p...@googlegroups.com
I've noticed similar things to Jon, Luke and and Paul,

I get 0.5 differences between DS1820B's and around 2 degrees between the temp probes on my multimeter. I also find the SS18B20's correlate quite well with the commercial temperature egg in my boys room, and the on wall thermostat, perhaps these use the same sensor?

Sam.

andyg (geekscape)

unread,
Feb 7, 2010, 9:45:24 PM2/7/10
to Aiko distributed platform
hi All,

On Feb 8, 12:51 am, Paul Szymkowiak <pauls...@gmail.com> wrote:
> But I can confirm my prototype Pebble has this problem.
>

> I'm still reading ~2 degrees hotter than actual. This is compared to the
> Temp reading function on my DMM, which agrees with a couple of different
> commercial units.

There would appear to be a systematic problem with the temperature
sensors ... in the way in which we are currently using them.

Both in the Pebble and in the Gateway.

On 8 February 2010 00:31, Luke Weston <reindeerfloti...@gmail.com>
wrote:


> the firmware written by Andy couldn't have a problem (especially since it's reading
> a digital protocol)

Not so fast ! The format of the bits coming over the wire still need
to be correctly translated by the software into a "degrees Celsius"
value. There is room for error in the software, in that regards.

I believe that are some "bit formatting" differences between various
Dallas Semiconductor DS1820 components, e.g DS18S20 and DS18B20.

I'll have a look and get back to you ... unless, someone else gets
there first !

cheers andyg (@geekscape)

MatsK

unread,
Feb 10, 2010, 3:59:41 AM2/10/10
to Aiko distributed platform
DS18S20 and DS18B20 has a ±0.5°C accuracy from -10°C to +85°C. This is
the explanation to the 0.5 - 1 degree differences.
And DS18B20 is quite sensitive about the power, it needs to be quite
stable and that can cause erratic readings.

A general remark on testing. To test a sensor, dip it into water, just
the plastic not the leads! Water has a much lower thermal resistance
than air another way is to stick the sensor to a large mass, iron lump
or eq.

> Not so fast! The format of the bits coming over the wire still need to be correctly translated by the software into a "degrees Celsius" value.
From the datasheet:
"The DS18S20 digital thermometer provides 9-bit Celsius temperature
measurements."
"The DS18B20 digital thermometer provides 9-bit to 12-bit Celsius
temperature measurements."
Why convert a value that is correct, Is it the bit swapping from the
registers you refer to?

> I believe that are some "bit formatting" differences between various
> Dallas Semiconductor DS1820 components, e.g DS18S20 and DS18B20.

DS18B20
BIT 7 BIT 6 BIT 5 BIT 4 BIT 3 BIT 2 BIT 1 BIT 0
LS BYTE 2^3 2^2 2^1 2^0 2^-1 2^-2 2^-3 2^-4

BIT 15 BIT 14 BIT 13 BIT 12 BIT 11 BIT 10 BIT 9 BIT 8
MS BYTE S S S S S 2^6 2^5 2^4


DS18S20
BIT 7 BIT 6 BIT 5 BIT 4 BIT 3 BIT 2 BIT 1 BIT 0
LS BYTE 2^6 2^5 2^4 2^3 2^2 2^1 2^0 2^-1

BIT 15 BIT 14 BIT 13 BIT 12 BIT 11 BIT 10 BIT 9 BIT 8
MS BYTE S S S S S S S S

But its easy to detect if its a S or B type.

Hope this helps.

/Mats

MatsK

unread,
Feb 10, 2010, 11:09:22 AM2/10/10
to Aiko distributed platform
Comments inline.

On Feb 8, 3:45 am, "andyg (geekscape)" <geeksc...@gmail.com> wrote:
> hi All,
>
> On Feb 8, 12:51 am, Paul Szymkowiak <pauls...@gmail.com> wrote:
>
> > But I can confirm my prototype Pebble has this problem.
>
> > I'm still reading ~2 degrees hotter than actual. This is compared to the
> > Temp reading function on my DMM, which agrees with a couple of different
> > commercial units.
>
> There would appear to be a systematic problem with the temperature
> sensors ... in the way in which we are currently using them.
>
> Both in the Pebble and in the Gateway.

DS18B20 is sensitive to unstable power, could that be the case ?
DS18S20 is more resilient to power voltage fluctuations.

> On 8 February 2010 00:31, Luke Weston <reindeerfloti...@gmail.com>
> wrote:
>
> > the firmware written by Andy couldn't have a problem (especially since it's reading
> > a digital protocol)
>
> Not so fast ! The format of the bits coming over the wire still need
> to be correctly translated by the software into a "degrees Celsius"
> value. There is room for error in the software, in that regards.
>
> I believe that are some "bit formatting" differences between various
> Dallas Semiconductor DS1820 components, e.g DS18S20 and DS18B20.
>
> I'll have a look and get back to you ... unless, someone else gets
> there first !
>
> cheers andyg (@geekscape)

The difference is:


DS18B20
BIT 7 BIT 6 BIT 5 BIT 4 BIT 3 BIT 2 BIT 1 BIT 0
LS BYTE 2^3 2^2 2^1 2^0 2^-1 2^-2 2^-3 2^-4

BIT 15 BIT 14 BIT 13 BIT 12 BIT 11 BIT 10 BIT 9 BIT 8
MS BYTE S S S S S 2^6 2^5 2^4


DS18S20
BIT 7 BIT 6 BIT 5 BIT 4 BIT 3 BIT 2 BIT 1 BIT 0
LS BYTE 2^6 2^5 2^4 2^3 2^2 2^1 2^0 2^-1

BIT 15 BIT 14 BIT 13 BIT 12 BIT 11 BIT 10 BIT 9 BIT 8
MS BYTE S S S S S S S S


And to all that reports minor temperature differences, DS18x20 has a
+/- 0.5 deg Celsius tolerance.

And when testing temperature sensors is it important to keep the
thermal resistance low, air has a high resistance, water is much
better!


Just my dime of thoughts.

/Mats

Reply all
Reply to author
Forward
0 new messages