This is an old revision of the document!


Window opener, based on gas detection

  • Author: Neaga Matei
  • Email: mateineaga@outlook.com, matei.neaga@stud.mec.upb.ro
  • Master: IA

Introduction

This project aims to build a setup based on a servomechanism and a sensor MQ-5, with the purpose of opening a window in case the gas concentration rises above a desired value.

Context

Hardware

  • ESP32 board
  • MQ-5 sensor, detecting SnO2
  • SG90 servomechanism
  • microusb - usb A cable
  • dupont cables

Software

Code snippets

#include <WiFi.h> #include <WebServer.h> #include <ESP32Servo.h>

const char* ssid = ””; const char* password = ””;

#define ANALOG_PIN 34 Pinul conectat la AO al senzorului MQ-4 #define SERVO_PIN 13 Pinul conectat la servomotor

int valoare_analogica = 0; String nivelGaz = ””; String culoareNivel = “green”; bool servoActiv = false; bool modAutomat = true; int pragActivare = 800;

Servo myservo;

Challenges

Figuring out a way to design the webpage to allow me to switch the servomechanism to “automated” or “manual” mode.

References

-

iothings/proiecte/2025sric/windowopener.1745404802.txt.gz · Last modified: 2025/04/23 13:40 by matei.neaga
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0