Remember to maintain security and privacy. Do not share sensitive information. Procedimento.com.br may make mistakes. Verify important information. Termo de Responsabilidade

Introduction to SDS011 Air Quality Sensor

The Importance and Utility of SDS011 Sensor

The SDS011 is an air quality sensor that measures the concentration of fine particles in the air. It is widely used in various applications such as air quality monitoring, environmental research, and smart home automation. The sensor provides accurate and real-time data on PM2.5 and PM10 particle sizes, allowing users to monitor and analyze air pollution levels.

The SDS011 sensor is compact, affordable, and easy to use, making it a popular choice among electronics enthusiasts, engineers, and researchers. With its precise measurements and reliable performance, it has become an essential tool for understanding and addressing air pollution issues.

Projeto: Air Quality Monitor using SDS011 Sensor

In this project, we will create an air quality monitor using the SDS011 sensor. The objective of the project is to measure the concentration of PM2.5 and PM10 particles in the air and display the data on an LCD screen. The monitor will provide real-time information on air quality, allowing users to take necessary actions to improve the environment.

Functionalities:

  1. Measure and display PM2.5 and PM10 particle concentrations.
  2. Display the air quality level (e.g., Good, Moderate, Poor) based on predefined thresholds.
  3. Provide visual and audible alerts when air quality exceeds safe limits.
  4. Log the data for further analysis and historical tracking.

Lista de componentes:

  1. Arduino Uno - 1x
  2. SDS011 Air Quality Sensor - 1x
  3. LCD Display (16x2) - 1x
  4. Breadboard - 1x
  5. Jumper Wires - As required
  6. Potentiometer - 1x (for LCD contrast adjustment)

You can purchase the components from the following links:

  • Arduino Uno: [Link]
  • SDS011 Air Quality Sensor: [Link]
  • LCD Display (16x2): [Link]
  • Breadboard: [Link]
  • Jumper Wires: [Link]
  • Potentiometer: [Link]

Exemplos:

#include <SoftwareSerial.h>
#include <LiquidCrystal_I2C.h>

SoftwareSerial sdsSerial(10, 11); // RX, TX pins for SDS011 sensor
LiquidCrystal_I2C lcd(0x27, 16, 2); // I2C address, columns, rows for LCD

void setup() {
  Serial.begin(9600);
  sdsSerial.begin(9600);
  lcd.begin(16, 2);
  lcd.print("Air Quality");
  lcd.setCursor(0, 1);
  lcd.print("Monitor");
  delay(2000);
  lcd.clear();
}

void loop() {
  if (sdsSerial.available()) {
    if (sdsSerial.find(0xAA) && sdsSerial.find(0xC0)) {
      int pm25LowByte = sdsSerial.read();
      int pm25HighByte = sdsSerial.read();
      int pm10LowByte = sdsSerial.read();
      int pm10HighByte = sdsSerial.read();
      int checksum = sdsSerial.read();

      int pm25 = (pm25HighByte << 8) | pm25LowByte;
      int pm10 = (pm10HighByte << 8) | pm10LowByte;

      lcd.setCursor(0, 0);
      lcd.print("PM2.5: ");
      lcd.print(pm25);
      lcd.setCursor(0, 1);
      lcd.print("PM10: ");
      lcd.print(pm10);

      Serial.print("PM2.5: ");
      Serial.print(pm25);
      Serial.print(" ug/m3\t");
      Serial.print("PM10: ");
      Serial.print(pm10);
      Serial.println(" ug/m3");
    }
  }
  delay(1000);
}

This code initializes the SDS011 sensor and the LCD display. It then continuously reads the data from the sensor and displays the PM2.5 and PM10 values on the LCD screen. The data is also printed on the serial monitor for further analysis.

To share Download PDF

Gostou do artigo? Deixe sua avaliação!
Sua opinião é muito importante para nós. Clique em um dos botões abaixo para nos dizer o que achou deste conteúdo.