Arduino with DS18B20 and LED

Arduino with DS18B20 and LED

Arduino with DS18B20 and LED
Save Image

Temperature monitoring using DS18B20 sensor and LED indicator.

Key Features

  • Accurate 1-wire sensor
  • LED status indicator
  • Easy integration

Instructions

1. Connect DS18B20 (Data to pin 7, 4.7k pull-up resistor).
2. Connect an LED to pin 13.
3. Upload the code.

Schematic

Schematic Download Schematic

Code Snippet

float tempC = sensors.getTempCByIndex(0);
if (tempC > 25) digitalWrite(LED_BUILTIN, HIGH);
Download Full Code
Back to Projects