Stufin
Home Quick Cart Profile

MQ-137 NH3 Gas Sensor Module for Ammonia, Carbon monoxide Detector Module

Buy Now

Component Name

MQ-137 NH3 Gas Sensor Module for Ammonia, Carbon monoxide Detector Module

Overview

The MQ-137 NH3 Gas Sensor Module is a sensitive and reliable detector module designed to detect ammonia (NH3) and carbon monoxide (CO) gases. This module is ideal for various IoT applications, such as air quality monitoring, industrial process control, and safety systems.

Functionality

The MQ-137 NH3 Gas Sensor Module is based on a metal oxide semiconductor (MOS) type sensor, which detects the presence of ammonia and carbon monoxide gases in the air. When the sensor detects the target gas, it changes its electrical resistance, which is then measured by an onboard circuit. The module provides an analog output signal that corresponds to the gas concentration, allowing for easy integration with microcontrollers, Arduino, or Raspberry Pi boards.

Key Features

  • Detection Range: The module can detect ammonia (NH3) concentrations between 10-500 ppm and carbon monoxide (CO) concentrations between 10-1000 ppm.
  • High Sensitivity: The MQ-137 sensor has a high sensitivity to NH3 and CO gases, making it suitable for applications where precise detection is required.
  • Fast Response Time: The module responds quickly to changes in gas concentrations, allowing for real-time monitoring and control.
  • Analog Output: The module provides an analog output signal, which can be easily read by microcontrollers or other devices.
  • Simple Interface: The module has a simple, 5-pin interface (VCC, GND, OUT, HEATER, and NC) that makes it easy to integrate into various systems.
  • Low Power Consumption: The module operates at a low voltage (5V) and has a low power consumption (<20mA), making it suitable for battery-powered devices.
  • Compact Design: The module is compact and lightweight, making it ideal for use in remote sensing applications or embedded systems.
  • Operating Temperature: The module can operate in a wide temperature range (-20C to 50C), making it suitable for use in various environments.

Sensor Type

Metal Oxide Semiconductor (MOS)

Detection Principle

Resistance change due to gas presence

Output Signal

Analog voltage (0-5V)

Supply Voltage

5V

Power Consumption

<20mA

Operating Temperature

-20C to 50C

Humidity

5-90% RH (non-condensing)

Dimensions

24mm x 20mm x 10mm (L x W x H)

Applications

Air quality monitoring systems

Industrial process control and safety systems

Environmental monitoring

IoT applications for smart homes and buildings

Medical and healthcare applications

Precautions

When using the MQ-137 NH3 Gas Sensor Module, it is essential to follow proper safety precautions, such as

Handling the module with care to avoid damage or contamination

Using the module in well-ventilated areas to prevent gas accumulation

Avoiding exposure to high temperatures, humidity, or corrosive substances

Following proper calibration and maintenance procedures to ensure accurate readings

Pin Configuration

  • MQ-137 NH3 Gas Sensor Module Documentation
  • Overview
  • The MQ-137 NH3 Gas Sensor Module is a high-sensitivity gas detection module designed to detect Ammonia (NH3) and Carbon monoxide (CO) gases. This module is widely used in various applications, including industrial leak detection, air quality monitoring, and environmental monitoring systems.
  • Pinout Description
  • The MQ-137 NH3 Gas Sensor Module has a total of 6 pins, each with a specific function. Below is a detailed description of each pin:
  • 1. VCC (Power Supply Pin)
  • Function: Provides power to the module
  • Voltage Range: 5V 0.2V
  • Typical Current Consumption: 150mA
  • Connect the VCC pin to a 5V power supply. Ensure the power supply is stable and regulated to prevent damage to the module.
  • 2. GND (Ground Pin)
  • Function: Provides a reference ground for the module
  • Connect to the ground of the power supply and the microcontroller
  • Connect the GND pin to the ground of the power supply and the microcontroller. This ensures a common ground reference for the entire system.
  • 3. DO (Digital Output Pin)
  • Function: Provides a digital output signal indicating the presence of NH3 or CO gases
  • Output Logic: Low (0V) when gas is detected, High (VCC) when no gas is detected
  • Output Type: Open Drain
  • Connect the DO pin to a digital input pin of a microcontroller. The microcontroller can then read the output state to determine if gas is present or not. Note that the DO pin is an open-drain output, which means it can sink current but cannot source current. Therefore, an external pull-up resistor is required to pull the output high when no gas is detected.
  • 4. AO (Analog Output Pin)
  • Function: Provides an analog output signal proportional to the gas concentration
  • Output Range: 0V to VCC (approximately 0-5V)
  • Output Impedance: 1k
  • Connect the AO pin to an analog-to-digital converter (ADC) input pin of a microcontroller. The microcontroller can then read the analog output voltage to determine the gas concentration.
  • 5. HEATER (Heater Pin)
  • Function: Provides power to the heating element of the gas sensor
  • Voltage Range: 5V 0.2V
  • Typical Current Consumption: 150mA
  • Connect the HEATER pin to a 5V power supply. This pin is used to power the heating element of the gas sensor, which is required for the sensor to operate correctly.
  • 6. NC (No Connection Pin)
  • Function: No internal connection
  • Purpose: Reserved for future use or factory testing
  • Leave the NC pin unconnected.
  • Connection Structure
  • Here is a suggested connection structure for the MQ-137 NH3 Gas Sensor Module:
  • Connect VCC to 5V power supply
  • Connect GND to power supply ground and microcontroller ground
  • Connect DO to microcontroller digital input pin with an external pull-up resistor (e.g., 1k)
  • Connect AO to microcontroller ADC input pin
  • Connect HEATER to 5V power supply
  • Leave NC pin unconnected
  • Important Notes
  • Ensure the power supply is stable and regulated to prevent damage to the module.
  • Use a suitable heat sink or thermal management system to prevent overheating of the module.
  • Follow proper safety guidelines when working with gas sensors, as they can be sensitive to environmental factors and may require calibration.
  • Consult the datasheet and technical documentation for the specific gas sensor module you are using, as pinout and functionality may vary slightly.

Code Examples

MQ-137 NH3 Gas Sensor Module for Ammonia, Carbon Monoxide Detector Module Documentation
Overview
The MQ-137 NH3 Gas Sensor Module is a highly sensitive detector module designed to detect ammonia (NH3) and carbon monoxide (CO) gases. It is based on the MQ-137 gas sensor, which is a metal oxide semiconductor (MOS) type sensor. This module is widely used in various applications, including industrial automation, environmental monitoring, and safety systems.
Technical Specifications
Sensor Type: Metal Oxide Semiconductor (MOS)
 Detectable Gases: Ammonia (NH3), Carbon Monoxide (CO)
 Detection Range:
	+ Ammonia (NH3): 1-500 ppm
	+ Carbon Monoxide (CO): 1-1000 ppm
 Operating Voltage: 5V
 Operating Current: 150mA
 Output Signal: Analog Voltage (0-5V)
 Response Time: <10 seconds
 Dimensions: 32 x 22 x 18 mm
Pinout
VCC: 5V Power Supply
 GND: Ground
 OUT: Analog Output Signal
Code Examples
### Example 1: Basic Analog Readout using Arduino
This example demonstrates how to use the MQ-137 NH3 Gas Sensor Module with an Arduino board to read the analog output signal and detect the presence of ammonia or carbon monoxide gases.
```c
const int sensorPin = A0;  // Analog input pin for sensor output
void setup() {
  Serial.begin(9600);
}
void loop() {
  int sensorValue = analogRead(sensorPin);
  float voltage = sensorValue  (5.0 / 1023.0);
  Serial.print("Gas Concentration: ");
  Serial.print(voltage);
  Serial.println(" V");
// Example threshold values for gas detection
  if (voltage > 2.5) {
    Serial.println("Ammonia or Carbon Monoxide detected!");
  } else {
    Serial.println("No gas detected.");
  }
  delay(1000);
}
```
### Example 2: Digital Output using Raspberry Pi and Python
This example demonstrates how to use the MQ-137 NH3 Gas Sensor Module with a Raspberry Pi to read the analog output signal and detect the presence of ammonia or carbon monoxide gases. The example uses the RPi.GPIO library to read the analog signal and convert it to a digital output.
```python
import RPi.GPIO as GPIO
import time
# Set up GPIO mode
GPIO.setmode(GPIO.BCM)
# Define the sensor pin
sensor_pin = 17
# Set up the sensor pin as an input
GPIO.setup(sensor_pin, GPIO.IN)
while True:
    # Read the analog signal
    sensor_value = GPIO.input(sensor_pin)
# Example threshold values for gas detection
    if sensor_value > 0.5:
        print("Ammonia or Carbon Monoxide detected!")
    else:
        print("No gas detected.")
time.sleep(1)
```
### Example 3: IC Interface using ESP32 and MicroPython
This example demonstrates how to use the MQ-137 NH3 Gas Sensor Module with an ESP32 board and MicroPython to read the analog output signal and detect the presence of ammonia or carbon monoxide gases. The example uses the machine library to read the analog signal and convert it to a digital output.
```python
import machine
import time
# Set up the IC interface
i2c = machine.I2C(scl=machine.Pin(22), sda=machine.Pin(21))
# Define the sensor address
sensor_addr = 0x04
while True:
    # Read the analog signal
    sensor_value = i2c.readfrom(sensor_addr, 1)[0]
# Example threshold values for gas detection
    if sensor_value > 128:
        print("Ammonia or Carbon Monoxide detected!")
    else:
        print("No gas detected.")
time.sleep(1)
```
Note: The above code examples assume a basic understanding of the programming languages and platforms used. You may need to modify the code to suit your specific requirements and hardware configurations.