How to turn off parasitic Mode

Hey there

I recently received a DS18B20 that I ordered. Unfortunately it is set to parasitic power mode, which I do not want. How can I turn it off? And where can I find a description of the functions to be used with DallasTemperature and OneWire library.

Thank you for your response!

How do you know it is set to parasitic mode? Parasite mode is a way of powering the device. It is not a mode that is set in an internal register or whatever.

Pete

I ran the "multiple" example scatch:

Serial.print("Parasite power is: ");
if (sensors.isParasitePowerMode()) Serial.println("ON");
else Serial.println("OFF");

after this it prints ON

Which DS18B20 did you get? Did you wire it up or did it come on a board?

Pete

The chip use parasitic power only if you ground the Vdd-line.

If I am not wrong there are some models who has Vdd connected to ground internally. Maybe their code end with a P. Anyway this is written in the datasheet.

Ah, you're right. There is a DS18B20-PAR which is internally configured for parasite power and there's no apparent way to change that. The pin that is Vdd on a DS18B20 has no connection on a DS18B20-PAR.
@aellenni: If you bought a DS18B20-PAR you can't change it to use non-parasite power.

Pete

Thank you all for your replies! It is a DS18B20 (not PAR). When Vdd is connected to 5V parasitic is OFF, when not connected to 5V on (as you guys said).
But I guess the sensor is broken: it shows -127 C when not in parasitic mode and 85 C in when parasitic mode is ON. (In both set-ups the pull-up resistor is in place and the other 4 equivalent DS18B20 sensors work fine)

Is there anywhere a description for the functions that can be called with the DallasTemperature and OneWire libraries?

Thanks!

If I remember well you get 85 if there is a communication error, it is written in the datasheet.

Have you used the resistor?

-127 C when not in parasitic mode

This indicates that the Arduino is not seeing the sensor at all. -127C means that it was reading all ones on the dataline. The pullup resistor holds the data line high (= 1) and the sensor should pull it to ground for a zero. That isn't happening so something's amiss in non-parasite mode - or there's something about the wiring that you haven't told us yet.

85 C in when parasitic mode is ON

That means that the processor is seeing a response from the sensor. When the sensor is first powered up, its temperature register is initialized to 85C. If the sensor returns a value of 85C it means that it hasn't seen a valid request to do a temperature conversion since it was powered on but it is working.

I haven't seen a site which describes all the library functions. I just read the code. On my system I installed it in ...\Documents\Arduino\libraries\dallastemperature

Pete

It is conncected just as shown in the picture in Zoomx's post. When I replace this sensor with any of the other 4 sensors, the temperature is being measured and displayed. Just with that one sensor it is not working

Might as well throw it away.

Pete