LPG gas leak alarm
A kitchen gas sniffer that beeps and flashes the moment LPG levels climb.
Shop by category
Shop all componentsA K-type thermocouple measures much higher temperatures than a DHT22 or DS18B20 can. The MAX6675 module reads it and gives the temperature over SPI with 0.25 degree steps. The ESP32 shows the temperature on an OLED, keeps the highest value, and sounds a buzzer when the reading reaches a target you set. It suits a toaster oven, a soldering preheater or a small kiln model. Thermocouple probes get hot: use the wire insulation rating.
Probes and the oven interior are hot. Use oven gloves and never touch the probe tip.
Do not use this as a safety cut-out for a heater.
Tick anything you already have and the total updates.
MAX6675 module with K-type thermocouple probe
Follow the colours: red is power, dark grey is ground, blue is a signal.
USB power bank. Keep the electronics away from the hot area; only the probe goes into the heat.
thermocouple.inoVerify & upload in Electrolark#include <max6675.h>
#include <Wire.h>
#include <Adafruit_SSD1306.h>
const int SCK_PIN = 18, CS_PIN = 5, SO_PIN = 19, BUZZ = 25;
const float TARGET_C = 180.0; // alarm temperature
MAX6675 tc(SCK_PIN, CS_PIN, SO_PIN);
Adafruit_SSD1306 oled(128, 64, &Wire, -1);
float peak = 0;
void setup() {
pinMode(BUZZ, OUTPUT);
Wire.begin(21, 22);
oled.begin(SSD1306_SWITCHCAPVCC, 0x3C);
oled.setTextColor(WHITE);
delay(500);
}
void loop() {
float c = tc.readCelsius(); // the MAX6675 needs at least 220 ms between reads
if (!isnan(c) && c > peak) peak = c;
oled.clearDisplay();
oled.setTextSize(3); oled.setCursor(0, 4); oled.printf("%.0fC", c);
oled.setTextSize(1); oled.setCursor(0, 40); oled.printf("peak %.0f target %.0f", peak, TARGET_C);
oled.display();
digitalWrite(BUZZ, (!isnan(c) && c >= TARGET_C) ? HIGH : LOW);
delay(500);
}
Check the three SPI wires and that the probe is plugged in the right way round; a reversed probe reads wrongly.
Thermocouple modules are about 2 to 3 degrees accurate. Compare with a reference and note the offset.
Keep the probe wire away from mains cables and power wires.
The MAX6675 reads up to about 1024 degrees C, but the probe's insulation limits the real range, often to about 300 to 400 C.
It can with a solid-state relay, but mains control needs an electrician and careful design.
A DS18B20 is limited to about 125 degrees, so it is not suitable for ovens.
6 parts: ESP32-WROOM-32 38-Pin Development Board, Generic MAX6675 Module + K-Type Thermocouple Sensor w/ 50cm Cable, 0.96" OLED Display 128x64, Buzzer Module 3.3–5V, 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 intermediate project and takes about 1.5 hours. The build on this page has 6 steps.
No. This page has the complete, tested code (thermocouple.ino).
About ₹901 for the parts at the prices on this page. Quantity price breaks lower the cost when you build several.
Reading a thermocouple through a MAX6675; Setting a temperature alarm; Showing live and peak values on an OLED.
Probes and the oven interior are hot. Use oven gloves and never touch the probe tip. Do not use this as a safety cut-out for a heater.
Ideas that reuse this build: ESP32 OLED internet clock. They are listed under Take it further on this page.
A kitchen gas sniffer that beeps and flashes the moment LPG levels climb.
See the smoke level live on a crisp screen and get a loud warning when it spikes.
An infrared eye that spots an open flame and raises the alarm.
Walk into the room and it sounds the alarm: the classic first security build.
Learning project. Check every circuit and the datasheet of each part before you power it up.