PaulStoffregen / OneWire

Library for Dallas/Maxim 1-Wire Chips
http://www.pjrc.com/teensy/td_libs_OneWire.html
579 stars 382 forks source link

esp8266 parasitic wrong temperatures #17

Closed tablatronix closed 8 years ago

tablatronix commented 8 years ago

Why would my temperatures be wrong in parasitic mode ?

ROM = 28 FF C9 30 C2 15 1 80
  Chip = DS18B20
  Data = 1 A0 1 4B 46 1F FF 1F 10 E6  CRC=E6
  Temperature = 26.00 Celsius, 78.80 Fahrenheit

// parasitic
ROM = 28 FF C9 30 C2 15 1 80
  Chip = DS18B20
  Data = 1 50 5 4B 46 1F FF 1F 10 35  CRC=35
  Temperature = 85.00 Celsius, 185.00 Fahrenheit
Testato commented 8 years ago

It's not wrong, 85 is an error code. Reducing your pull-up resistor will help you.

tablatronix commented 8 years ago

How do you tell ? Didn't see it n the datasheet.

dropped to 2k3

ROM = 28 FF C9 30 C2 15 1 80
  Chip = DS18B20
  Data = 1 18 4 4B 46 1F FF 1F 10 6B  CRC=6B
  Temperature = 65.50 Celsius, 149.90 Fahrenheit

I had to use a 1k to get actual temp.

Thanks.

But I am curious why, is it just something the lib doesn't detect? I figure bit read problems would fail crc check?

tablatronix commented 8 years ago

I think i understand the 85 now, indication of device resets. Interesting.

akupiec commented 7 years ago

In my case it's starting to show correct temperature around ~1.9k - it would be nice to add more specific information about needed rezystor. I spend some time looking into few lib's sources why shown temperature is incorrect.