-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Decimal part of the temperature / humidity value for the DHT11 #9
Comments
Hi @hbgxsm95! Thanks for pointing specific place in code. I don't remember, why I did so. Let me recheck and get back with the answer (or fix). |
Sure. :) |
According to test I made to remind what is wrong with calculation, I found that DHT11 always return zeros in decimal part of values:
In contrast DHT22 returns non-empty values:
Also, pay attention, that calculations for integer parts are different for DHT11 and DHT22. |
Yes, I only use DHT11. After I add the decimal part in line 184, 185, the DHT11 return non-zero in decimal part of values. |
Interesting! Could you send me how your 5 raw bytes looks like from debug output? |
Since, I have DHT11 sensor which always return in second byte of humidity and temperature zero byte, I can't verify how to mix this amount with major byte, so will postpone this bug until the moment I get this equipment on hand. |
Thanks! |
Hi @hbgxsm95!
I still have no such DHT11 sensor, which produce non-zero decimal parts (as you can see in last line). Could you help me with output examples from your sensors? |
I have the DHT11. Here's some output from my sensor. hopefully it helps:
|
@justmiles, could you send me a link to the internet shop where you bought this sensor? |
@d2r2 my DHT11 came from this KOOKYE 16 in 1 Smart Home Sensor Modules bundle. |
@justmiles, thanks for showing the sample! I will allow myself to assume, that this it not DHT11, though it looks like DHT11 :). |
The issue with presence of decimal part for humidity/temperature of some DHT11 sensors is resolved via changing sensor type to DHT12 sensor which was recently committed. So this issue will be closed during month if no new objection emerge. |
in the line 184, 185 of dht.go. why don't add the decimal part to the value? Based on the datasheet of DHT11, it supports the decimal part.
The text was updated successfully, but these errors were encountered: