In this illustration we will wire the GAS SENSOR MQ2 Module, these device is very useful for GAS leakage detection in home or industry it can detect H2, LPG, CH4, CO, Alcohol or Propane. This device is very sensitive and fast response time and measuring and also can be adjusted onboard by the trimmer potentiometer.

The GAS Sensor is using an Analog output, and should be connected to MCU Analog input. See the illustration below.
The signal output voltage from the GAS SENSOR will increase & decrease when the sensor detects concentration of GAS. Sensitivity can be adjusted by varying the trimmer onboard. The best detection time for the sensor is should be 24 hours. For detailed information for the MQ 2 Sensor, refer to the datasheet.

Required Components

  • Arduino Board
  • MQ-2 Sensor / H2, LPG, CH4, CO, Alcohol or Propane Sensor
  • Jumper Wires / DuPont Wires
  • Solder Less Bread Board

Wiring Diagram


Arduino Sketch

The code below are tested for standard environment. It may vary based on the temperature and humidity. Make it sure that you have a clean air environment then upload the Arduino sketch.

“Sensing the Clean Air”

“Sensing the GAS”

Gas Concentration Graph


Download MQ-2 Data Schematics here | Pdf
Download MQ2 Circuit Diagram | Pdf

Gas Detection MQ-2 Sensor with Arduino
Tagged on:             


Leave a Reply

Your email address will not be published. Required fields are marked *