GPS speedometer and clock
A bike or car speedometer that needs no wheel sensor: satellites do the measuring.
Shop by category
Shop all componentsThe DS18B20 probe is sealed in stainless steel, so it can sit in water, a fridge or soil. The ESP32 reads it and serves a small web page that refreshes every few seconds. The probe needs one 4.7 k pull-up resistor between its data wire and 3.3 V. The probe is sealed but the cable joint at the top is not, so keep that part out of the water.
Tick anything you already have and the total updates.
Waterproof DS18B20 probe
Follow the colours: red is power, dark grey is ground, blue is a signal.
USB phone charger.
web_thermometer.inoVerify & upload in Electrolark#include <WiFi.h>
#include <WebServer.h>
#include <OneWire.h>
#include <DallasTemperature.h>
const char* SSID = "YOUR_WIFI";
const char* PASS = "YOUR_PASSWORD";
OneWire ow(4);
DallasTemperature probe(&ow);
WebServer server(80);
void handleRoot() {
probe.requestTemperatures();
float t = probe.getTempCByIndex(0);
String html = "<meta name='viewport' content='width=device-width'><meta http-equiv='refresh' content='5'>";
html += "<h1>Temperature</h1><h2>";
html += (t == DEVICE_DISCONNECTED_C) ? String("probe not found") : String(t, 1) + " °C";
html += "</h2>";
server.send(200, "text/html", html);
}
void setup() {
Serial.begin(115200);
probe.begin();
WiFi.begin(SSID, PASS);
while (WiFi.status() != WL_CONNECTED) delay(300);
Serial.println(WiFi.localIP());
server.on("/", handleRoot);
server.begin();
}
void loop() { server.handleClient(); }
Check the pull-up resistor and that DATA goes to GPIO 4.
That is the power-up value. Check the wiring and try again.
The phone must be on the same Wi-Fi as the ESP32.
Yes, on the same wire. Use getTempCByIndex(1) for the second.
About half a degree from 0 to 85 C.
Yes. See the fridge logger project.
5 parts: ESP32-WROOM-32 38-Pin Development Board, DS18B20 Waterproof Temperature Probe – 1m Cable, Stainless Steel, Resistor Assortment Kit (30 Values), Solderless Breadboard and Dupont Jumper Wires (40 pcs). On this page you can tick the parts you already have and add only the rest to your cart.
It is a beginner project and takes about 1 hour. The build on this page has 6 steps.
No. This page has the complete, tested code (web_thermometer.ino).
About ₹539 for the parts at the prices on this page. Quantity price breaks lower the cost when you build several.
Reading a DS18B20 with OneWire; Serving an auto-refreshing page; Why the data line needs a pull-up.
Ideas that reuse this build: ESP32 multi-probe fridge logger. They are listed under Take it further on this page.
A bike or car speedometer that needs no wheel sensor: satellites do the measuring.
Records where you went every five seconds, ready to open on a map.
Two boards, two radios: press the button at the gate and it rings indoors.
Check temperature, humidity and pressure from any phone on your Wi-Fi.
Learning project. Check every circuit and the datasheet of each part before you power it up.