Testing these sensors is very simple, but you need a battery pack or power supply.
Connect the 2.7-5.5V power supply (2-4 AA batteries work normally), connect the ground to pin 3 (right pin), and the power supply to Pin 1 (Left pin)
Then connect the multimeter to ground in DC voltage mode, and the remaining pin 2 (middle). If you have a TMP36 and its room temperature (25 ° C), the voltage should be about 0.75V. Please note that if you are using LM35, the voltage will be 0.25V
The sensor indicates a temperature of 26.3 ° C, also known as 79.3 ° F
You can change the voltage range by pressing the plastic case of the sensor with your finger. You will see a temperature / voltage rise.
Place my finger on the sensor and heat it a little bit, The temperature reading is now 29.7 ° C / 85.5 ° F
or you can touch the sensor with ice cubes, it is better to touch the sensor with a plastic bag so that it will not Let there be water on your circuit and see the temperature / voltage drop.
I pressed ice on the sensor to lower the temperature To 18.6 ° C / 65.5 ° F
Keywords: How to test DS18B20, DS18B20 detection with multimeter, DS18B20 temperature sensor