PMSX003 Particulate Matter Sensor

The pmsx003 sensor platform allows you to use your Plantower PMS5003, PMS7003, … laser based particulate matter sensors (datasheet) sensors with ESPHome.

As the communication with the PMSX003 is done using UART, you need to have an UART bus in your configuration with the rx_pin connected to the SEND/TX pin (may also be called the RX pin, depending on the model) of the PMS. Additionally, you need to set the baud rate to 9600.

This platform supports three sensor types, which you need to specify using the type: configuration value:

  • PMSX003 for generic PMS5003, PMS7003, …; these sensors support pm_1_0, pm_2_5 and pm_10_0 output.
  • PMS5003S for PMS5003S. These support pm_1_0, pm_2_5 and pm_10_0 and formaldehyde.
  • PMS5003T for PMS5003T. These support pm_1_0, pm_2_5 and pm_10_0, temperature and humidity.
  • PMS5003ST for PMS5003ST. These support pm_2_5, temperature, humidity and formaldehyde.

Sensor Longevity

The laser diode inside the PMSX003 has a lifetime of about 8000 hours, nearly one year.

If you wish to use the optional update_interval ensure you have a tx_pin set in the UART configuration and connected to the RECEIVE/RX pin (may also be called the TX pin, depending on the model) of the PMS. Setting update_interval to 120 seconds or higher may help extend the life span of the sensor.

# Example configuration entry
sensor:
  - platform: pmsx003
    type: PMSX003
    pm_1_0:
      name: "Particulate Matter <1.0µm Concentration"
    pm_2_5:
      name: "Particulate Matter <2.5µm Concentration"
    pm_10_0:
      name: "Particulate Matter <10.0µm Concentration"
    aqi:
      name: "Air Quality Index"
      calculation_type: "AQI"

Configuration variables

  • pm_1_0_std (Optional): Use the concentration of particulates of size less than 1.0µm in µg per cubic meter at standard particle. All options from Sensor.

  • pm_2_5_std (Optional): Use the concentration of particulates of size less than 2.5µm in µg per cubic meter at standard particle. All options from Sensor.

  • pm_10_0_std (Optional): Use the concentration of particulates of size less than 10.0µm in µg per cubic meter at standard particle. All options from Sensor.

  • pm_1_0 (Optional): Use the concentration of particulates of size less than 1.0µm in µg per cubic meter under atmospheric environment. All options from Sensor.

  • pm_2_5 (Optional): Use the concentration of particulates of size less than 2.5µm in µg per cubic meter under atmospheric environment. All options from Sensor.

  • pm_10_0 (Optional): Use the concentration of particulates of size less than 10.0µm in µg per cubic meter under atmospheric environment. All options from Sensor.

  • pm_0_3um (Optional): Use the number of particles with diameter beyond 0.3um in 0.1L of air. All options from Sensor.

  • pm_0_5um (Optional): Use the number of particles with diameter beyond 0.5um in 0.1L of air. All options from Sensor.

  • pm_1_0um (Optional): Use the number of particles with diameter beyond 1.0um in 0.1L of air. All options from Sensor.

  • pm_2_5um (Optional): Use the number of particles with diameter beyond 2.5um in 0.1L of air. All options from Sensor.

  • pm_5_0um (Optional): Use the number of particles with diameter beyond 5.0um in 0.1L of air. Not supported by the PMS5003T type sensors. All options from Sensor.

  • pm_10_0um (Optional): Use the number of particles with diameter beyond 10.0um in 0.1L of air. Not supported by the PMS5003T type sensors. All options from Sensor.

  • temperature (Optional): Use the temperature value in °C for the PMS5003T and PMS5003ST type sensors. All options from Sensor.

  • humidity (Optional): Use the humidity value in % for the PMS5003T and PMS5003ST type sensors. All options from Sensor.

  • formaldehyde (Optional): Use the formaldehyde (HCHO) concentration in µg per cubic meter for the PMS5003S and PMS5003ST type sensors. All options from Sensor.

  • aqi (Optional): Air Quality Index sensor. Requires both pm_2_5 and pm_10_0 sensors to be configured. See Air Quality Index below.

    • calculation_type (Required): The AQI calculation standard to use. One of: AQI (US EPA) or CAQI (European).
    • All other options from Sensor.
  • update_interval (Optional): Amount of time to wait between generating measurements. If this is longer than 30 seconds, and if tx_pin is set in the UART configuration, the fan will be spun down between measurements. Default to 0s (forward data as it’s coming in from the sensor).

  • uart_id (Optional, ID): Manually specify the ID of the UART Component if you want to use multiple UART buses.

Air Quality Index

The AQI (Air Quality Index) sensor calculates an air quality index value based on the PM2.5 and PM10 particulate matter concentrations. This provides a single number that indicates overall air quality and associated health concerns.

Two calculation standards are supported:

  • AQI (US EPA Air Quality Index): The standard used in the United States, Canada, and parts of Asia. Scale of 0-500+.
  • CAQI (Common Air Quality Index): The European standard. Scale of 0-400.

Both calculation types take the PM2.5 and PM10 values and return the higher (more conservative) of the two calculated index values.

AQI Scale (US EPA)

IndexLevelHealth Implications
0-50GoodAir quality is satisfactory
51-100ModerateAcceptable; some pollutants may be a concern for sensitive individuals
101-150Unhealthy for Sensitive GroupsMembers of sensitive groups may experience health effects
151-200UnhealthyEveryone may begin to experience health effects
201-300Very UnhealthyHealth alert: everyone may experience more serious health effects
301-500HazardousHealth warnings of emergency conditions

CAQI Scale (European)

IndexLevelHealth Implications
0-25Very LowAir quality is excellent
26-50LowAir quality is good
51-75MediumAir quality is fair
76-100HighAir quality is poor
101-400Very HighAir quality is very poor

Configuration Example

sensor:
  - platform: pmsx003
    type: PMSX003
    pm_2_5:
      name: "PM2.5"
    pm_10_0:
      name: "PM10"
    aqi:
      name: "Air Quality Index"
      calculation_type: "AQI"  # or "CAQI" for European standard
      # Optional: Apply filters for smoother values
      filters:
        - sliding_window_moving_average:
            window_size: 15
            send_every: 1

See Also