
Code: Select all
Humidity sensor temperature: -58.0794029236 C
Code: Select all
0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef
00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 bc ...............?
10: 1b 00 75 32 9b be d6 a1 9e b2 00 00 00 00 80 a2 ?.u2??????....??
20: 87 00 00 00 00 00 00 03 ff 7f 15 ef fc 7f 18 ef ?......?.???????
30: 35 84 a9 21 00 c4 ff ff 39 03 dc d2 fd ff 2e 03 5??!.?..9????..?

I think regardless of where the user is, the temperature is unlikely to be -38C. I'd return the HAT and hope the replacement doesn't have the same issue.DougieLawson wrote:What is the altitude of the airfield (QFE)?
What is your altitude?
Have you corrected both readings to mean sea level (QNH)?
Thx - Both locations are anout 5 metres about sea level - looks like i'll be returning the Pi Hat to the distributor and try again ....DougieLawson wrote:What is the altitude of the airfield (QFE)?
What is your altitude?
Have you corrected both readings to mean sea level (QNH)?
So is there a known issue with the current set of new batched of Pi Hat ? As the Pi Hat was out of stock for some time ...ShiftPlusOne wrote:I think regardless of where the user is, the temperature is unlikely to be -38C. I'd return the HAT and hope the replacement doesn't have the same issue.DougieLawson wrote:What is the altitude of the airfield (QFE)?
What is your altitude?
Have you corrected both readings to mean sea level (QNH)?
Wow, you're living on the beach! So your readings should be entirely consistent with your local airfield.southernseas wrote:Thx - Both locations are anout 5 metres about sea level - looks like i'll be returning the Pi Hat to the distributor and try again ....DougieLawson wrote:What is the altitude of the airfield (QFE)?
What is your altitude?
Have you corrected both readings to mean sea level (QNH)?
yep ... life on the beach ..looking to get some weather data from hre http://www.thecoromandel.com/DougieLawson wrote:Wow, you're living on the beach! So your readings should be entirely consistent with your local airfield.southernseas wrote:Thx - Both locations are anout 5 metres about sea level - looks like i'll be returning the Pi Hat to the distributor and try again ....DougieLawson wrote:What is the altitude of the airfield (QFE)?
What is your altitude?
Have you corrected both readings to mean sea level (QNH)?
Code: Select all
from sense_hat import SenseHat
sense = SenseHat()
t = sense.get_temperature()-102
pt = sense.get_temperature_from_pressure()
p = sense.get_pressure()
h = sense.get_humidity()
t = round(t, 1)
p = round(p, 1)
h = round(h, 1)
pt = round(pt,1)
print("Temperature: %s C" % t)
print("Temperature from Pressure: %s C" % pt)Pftt, I'm living at 3m, quite a few spots on the map around me are at zero .... waterproof case does sound like a good ideasouthernseas wrote:yep ... life on the beach ..looking to get some weather data from hre http://www.thecoromandel.com/DougieLawson wrote:Wow, you're living on the beach! So your readings should be entirely consistent with your local airfield.southernseas wrote: Thx - Both locations are anout 5 metres about sea level - looks like i'll be returning the Pi Hat to the distributor and try again ....
ideally a floating bouy
anyone know of a 3D plans for waterproof pi case with pi3 + baterry pack , e.g. 10000 mha + sense hat ?
humidity may be high
Code: Select all
from time import sleep
from sense_hat import SenseHat
sense = SenseHat()
while True:
t = sense.get_temperature()
if t == 0: t = sense.get_temperature()
else: sleep(0.1)
p = sense.get_pressure()
if p == 0: temp = sense.get_pressure()
else: sleep(0.1)
h = sense.get_humidity()
if h == 0: h = sense.get_humidity()
else: sleep(0.1)
pt = sense.get_temperature_from_pressure()
if pt == 0: pt = sense.get_temperature_from_pressure
else: sleep(0.1)
t = round(t, 1)
p = round(p, 1)
h = round(h, 1)
pt = round(pt,1)
msg = "Temperature=%s, Pressure=%s , Humidity=%s, Temp_from_Pressure=%s" % (t,p,h,pt)
sense.show_message(msg, scroll_speed=0.05)
The zero reading is entirely a software thing. I think the python library just returns 0 when the reading is not ready.BGL wrote:I received my sensor from Germany today and it's reading the temperature as expected, it does occasionally return a '0' so have amended my script to account for this and have an RMA for my first sensor.
Code: Select all
from time import sleep from sense_hat import SenseHat sense = SenseHat() while True: t = sense.get_temperature() if t == 0: t = sense.get_temperature() else: sleep(0.1) p = sense.get_pressure() if p == 0: temp = sense.get_pressure() else: sleep(0.1) h = sense.get_humidity() if h == 0: h = sense.get_humidity() else: sleep(0.1) pt = sense.get_temperature_from_pressure() if pt == 0: pt = sense.get_temperature_from_pressure else: sleep(0.1) t = round(t, 1) p = round(p, 1) h = round(h, 1) pt = round(pt,1) msg = "Temperature=%s, Pressure=%s , Humidity=%s, Temp_from_Pressure=%s" % (t,p,h,pt) sense.show_message(msg, scroll_speed=0.05)
[/quote]ShiftPlusOne wrote: The zero reading is entirely a software thing. I think the python library just returns 0 when the reading is not ready.

It's an HTS221. I've written a small C program to take the register dump and determine the temperature. It is entirely possible that I've made a mistake, so a second pair of eyes would be helpful.DougieLawson wrote:Has anyone considered that this number of failures is more likely to be a software bug than a hardware failure. I'd be looking at the code in the library whether it's handling 16-bit numbers correctly, whether it's converting unsigned values to signed values when it shouldn't be.
I wouldn't be blaming the hardware.
What sensor is it using?
Code: Select all
$ i2cdump -r 0x00-0x3f -y 1 0x5f b
0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef
00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 bc ...............?
10: 1b 00 96 33 98 be 26 a2 9e b2 fb 00 18 00 80 9e ?.?3??&????.?.??
20: 87 00 00 00 00 00 00 03 e9 12 c3 e8 fe ff ab e8 ?......??????.??
30: 36 84 a9 21 00 c4 ed ff 49 03 bc d2 00 00 2d 03 6??!.??.I???..-?