LPG gas leak alarm
A kitchen gas sniffer that beeps and flashes the moment LPG levels climb.
Shop by category
Shop all componentsThe SS443R is a unipolar Hall-effect switch: its open-collector output goes low when a magnet's south pole comes close. With a pull-up resistor it gives one clean pulse per wheel turn, without the bounce of a reed switch. The Nano times the gap between pulses for speed, counts pulses for distance and shows both on an OLED.
Fix everything firmly so nothing can reach the spokes, and never look at the screen while riding fast.
Tick anything you already have and the total updates.
SS443R unipolar Hall switch (TO-92)
Neodymium magnet for the spoke
Follow the colours: red is power, dark grey is ground, blue is a signal.
USB power bank in a handlebar bag.
bike_speedo.inoVerify & upload in Electrolark#include <Wire.h>
#include <Adafruit_SSD1306.h>
Adafruit_SSD1306 oled(128, 64, &Wire, -1);
void big(const String& top, const String& value, const String& unit) {
oled.clearDisplay(); oled.setTextColor(WHITE);
oled.setTextSize(1); oled.setCursor(0, 0); oled.print(top);
oled.setTextSize(3); oled.setCursor(0, 20); oled.print(value);
oled.setTextSize(1); oled.print(" "); oled.print(unit);
oled.display();
}
const float WHEEL_M = 2.10; // circumference of a 700x28c wheel; measure yours
volatile unsigned long lastPulse = 0, period = 0, turns = 0;
void onPulse() {
unsigned long now = micros();
if (now - lastPulse > 60000) { period = now - lastPulse; lastPulse = now; turns++; } // ignore bounces under 60 ms
}
void setup() {
oled.begin(SSD1306_SWITCHCAPVCC, 0x3C);
pinMode(2, INPUT);
attachInterrupt(digitalPinToInterrupt(2), onPulse, FALLING);
}
void loop() {
noInterrupts(); unsigned long p = period, t = turns, lp = lastPulse; interrupts();
float kmh = (p && micros() - lp < 3000000UL) ? WHEEL_M / (p / 1e6) * 3.6 : 0;
big("Trip " + String(t * WHEEL_M / 1000.0, 2) + " km", String(kmh, 1), "km/h");
delay(1000);
}
The SS443R responds to the south pole only; flip the magnet.
Bring the sensor closer to the magnet path (under 5 mm).
The pull-up is missing; the output is open collector.
No contacts to wear or bounce, so readings stay clean at high speed.
Yes, add a second sensor and magnet on the crank.
Seal the sensor with heat shrink and put the electronics in a sealed box.
7 parts: Generic Nano CH340 Development Board (Soldered), Honeywell SS443R Unipolar Hall Effect Magnetic Sensor – TO-92 Through Hole, 45-205 G Operating Point, Generic K800 Round Super Circular Magnet – Axially Magnetized NdFeB, Resistor Assortment Kit (30 Values), 0.96" OLED Display 128x64, 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 2 hours. The build on this page has 6 steps.
No. This page has the complete, tested code (bike_speedo.ino).
About ₹485 for the parts at the prices on this page. Quantity price breaks lower the cost when you build several.
Unipolar Hall switches and open-collector outputs; Measuring speed from pulse timing; Interrupts on the Nano.
Fix everything firmly so nothing can reach the spokes, and never look at the screen while riding fast.
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.
Lessons are free to read. Maker (₹499/month) and Pro add quizzes, worked problems and certificates, paid with your Geekobot account. See plans
Learning project. Check every circuit and the datasheet of each part before you power it up.