Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use MQ-9: Examples, Pinouts, and Specs

Image of MQ-9
Cirkit Designer LogoDesign with MQ-9 in Cirkit Designer

Introduction

  • The MQ-9 Gas Sensor Module, manufactured by Flying Fish, is a versatile electronic component designed to detect carbon monoxide (CO) and combustible gases such as methane (CH4) in the air. It is widely used in gas leakage detection systems, industrial safety applications, and environmental monitoring.
  • Common applications include gas leak alarms, air quality monitoring systems, and smart home safety devices. Its high sensitivity to CO and CH4 makes it a reliable choice for detecting harmful gases in various environments.

Explore Projects Built with MQ-9

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Arduino UNO and A9G GSM/GPRS GPS-Based Air Quality Monitoring System
Image of A9G Smoke Sensor: A project utilizing MQ-9 in a practical application
This circuit features an Arduino UNO microcontroller interfaced with an A9G GSM/GPRS+GPS module and an MQ2 gas sensor. The Arduino communicates with the A9G module via digital pins D11 and D10 for data transmission, and it reads analog gas concentration levels from the MQ2 sensor through analog pin A5. Both the A9G module and the MQ2 sensor are powered by the Arduino's 5V output, and all components share a common ground.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino UNO Based Air Quality Monitoring and GSM Notification System
Image of Arduino wild: A project utilizing MQ-9 in a practical application
This circuit features an Arduino UNO microcontroller interfaced with an MQ135 air quality sensor, an MPU-6050 accelerometer/gyroscope, a SIM900A GSM communication module, and a buzzer. The Arduino reads analog data from the MQ135 sensor and communicates with the MPU-6050 via I2C, while also controlling the buzzer and handling serial communication with the SIM900A module. The purpose of this circuit is likely to monitor air quality and motion, provide alerts through the buzzer, and enable remote communication via GSM.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino UNO Based Fire Detection and Alert System with SIM900A GSM Module
Image of project 1: A project utilizing MQ-9 in a practical application
This circuit is designed for fire detection and alerting. It uses an Arduino UNO to interface with a heat flame sensor for fire detection and an MQ135 sensor for air quality monitoring. Upon detecting a fire, the Arduino activates a buzzer and uses a SIM900A GSM module to send SMS alerts and make calls to predefined phone numbers.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino-Based Air Quality Monitoring System with Multiple Gas Sensors and GSM Module
Image of AIRMS: A project utilizing MQ-9 in a practical application
This circuit is an air quality monitoring system that uses an Arduino UNO to read data from various sensors, including the MQ-7 for CO detection, MQ131 for ozone detection, MQ-135 for general air quality, and a DHT11 for temperature and humidity. The Arduino processes the sensor data and can communicate the results via a SIM800L module for remote monitoring.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with MQ-9

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of A9G Smoke Sensor: A project utilizing MQ-9 in a practical application
Arduino UNO and A9G GSM/GPRS GPS-Based Air Quality Monitoring System
This circuit features an Arduino UNO microcontroller interfaced with an A9G GSM/GPRS+GPS module and an MQ2 gas sensor. The Arduino communicates with the A9G module via digital pins D11 and D10 for data transmission, and it reads analog gas concentration levels from the MQ2 sensor through analog pin A5. Both the A9G module and the MQ2 sensor are powered by the Arduino's 5V output, and all components share a common ground.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Arduino wild: A project utilizing MQ-9 in a practical application
Arduino UNO Based Air Quality Monitoring and GSM Notification System
This circuit features an Arduino UNO microcontroller interfaced with an MQ135 air quality sensor, an MPU-6050 accelerometer/gyroscope, a SIM900A GSM communication module, and a buzzer. The Arduino reads analog data from the MQ135 sensor and communicates with the MPU-6050 via I2C, while also controlling the buzzer and handling serial communication with the SIM900A module. The purpose of this circuit is likely to monitor air quality and motion, provide alerts through the buzzer, and enable remote communication via GSM.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of project 1: A project utilizing MQ-9 in a practical application
Arduino UNO Based Fire Detection and Alert System with SIM900A GSM Module
This circuit is designed for fire detection and alerting. It uses an Arduino UNO to interface with a heat flame sensor for fire detection and an MQ135 sensor for air quality monitoring. Upon detecting a fire, the Arduino activates a buzzer and uses a SIM900A GSM module to send SMS alerts and make calls to predefined phone numbers.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of AIRMS: A project utilizing MQ-9 in a practical application
Arduino-Based Air Quality Monitoring System with Multiple Gas Sensors and GSM Module
This circuit is an air quality monitoring system that uses an Arduino UNO to read data from various sensors, including the MQ-7 for CO detection, MQ131 for ozone detection, MQ-135 for general air quality, and a DHT11 for temperature and humidity. The Arduino processes the sensor data and can communicate the results via a SIM800L module for remote monitoring.
Cirkit Designer LogoOpen Project in Cirkit Designer

Technical Specifications

  • Operating Voltage: 5V DC
  • Power Consumption: ≤ 800mW
  • Detection Range:
    • Carbon Monoxide (CO): 10–1000 ppm
    • Methane (CH4): 100–10000 ppm
  • Preheat Time: ≥ 24 hours for optimal performance
  • Output: Analog voltage signal
  • Operating Temperature: -20°C to 50°C
  • Humidity Range: 5% to 95% RH (non-condensing)
  • Dimensions: 32mm x 20mm x 22mm (approx.)

Pin Configuration and Descriptions

Pin Name Pin Number Description
VCC 1 Power supply input (5V DC)
GND 2 Ground connection
AOUT 3 Analog output signal proportional to gas concentration
DOUT 4 Digital output signal (high/low) based on a user-defined threshold

Usage Instructions

How to Use the MQ-9 in a Circuit

  1. Power Supply: Connect the VCC pin to a 5V DC power source and the GND pin to the ground.
  2. Signal Output:
    • Use the AOUT pin to read the analog signal for precise gas concentration measurements.
    • Use the DOUT pin for a simple high/low signal based on a preset threshold (adjustable via the onboard potentiometer).
  3. Preheating: Allow the sensor to preheat for at least 24 hours before taking accurate measurements.
  4. Connection to Microcontroller:
    • Connect the AOUT pin to an analog input pin of a microcontroller (e.g., Arduino UNO).
    • Optionally, connect the DOUT pin to a digital input pin for threshold-based detection.

Important Considerations and Best Practices

  • Preheat Time: Ensure the sensor is preheated for at least 24 hours before initial use to stabilize its readings.
  • Calibration: Calibrate the sensor in a clean air environment to set a baseline for accurate measurements.
  • Ventilation: Use the sensor in a well-ventilated area to avoid saturation and ensure accurate readings.
  • Avoid Contaminants: Keep the sensor away from water, oil, and other contaminants that may damage its sensing element.

Example Code for Arduino UNO

// MQ-9 Gas Sensor Example Code for Arduino UNO
// This code reads analog data from the MQ-9 sensor and prints the gas concentration
// to the Serial Monitor. Ensure the sensor is connected to the correct pins.

const int analogPin = A0; // Connect AOUT pin of MQ-9 to Arduino analog pin A0
const int digitalPin = 2; // Connect DOUT pin of MQ-9 to Arduino digital pin 2

void setup() {
  Serial.begin(9600); // Initialize serial communication at 9600 baud
  pinMode(digitalPin, INPUT); // Set DOUT pin as input
}

void loop() {
  int analogValue = analogRead(analogPin); // Read analog value from AOUT
  int digitalValue = digitalRead(digitalPin); // Read digital value from DOUT

  // Convert analog value to voltage (assuming 5V reference)
  float voltage = analogValue * (5.0 / 1023.0);

  // Print the readings to the Serial Monitor
  Serial.print("Analog Value: ");
  Serial.print(analogValue);
  Serial.print(" | Voltage: ");
  Serial.print(voltage);
  Serial.print("V | Digital Value: ");
  Serial.println(digitalValue);

  delay(1000); // Wait for 1 second before the next reading
}

Troubleshooting and FAQs

Common Issues

  1. No Output Signal:
    • Ensure the sensor is properly connected to the power supply and ground.
    • Verify that the preheat time has been completed (≥ 24 hours).
  2. Inaccurate Readings:
    • Check for proper calibration in a clean air environment.
    • Ensure the sensor is not exposed to extreme temperatures or humidity.
  3. Digital Output Always High/Low:
    • Adjust the onboard potentiometer to set an appropriate threshold for the DOUT signal.

Solutions and Tips for Troubleshooting

  • Check Connections: Double-check all wiring and ensure the sensor is securely connected to the microcontroller.
  • Test with Known Gas Concentrations: Use a controlled environment with known gas concentrations to verify sensor accuracy.
  • Replace Sensor: If the sensor is exposed to contaminants or has been in use for an extended period, consider replacing it.

By following this documentation, users can effectively integrate the MQ-9 Gas Sensor Module into their projects and ensure reliable gas detection performance.