Страница 1 из 1

PMS7003 esphome

Добавлено: Сб июн 21, 2025 9:39 pm
TechMike
https://psenyukov.ru/%D0%B4%D0%BE%D0%B1 ... 0%B8-pm10/

https://datasheet.lcsc.com/lcsc/PMS7003_C84815.pdf
https://www.pdf-archive.com/2017/04/12/ ... -sheet.pdf

Код: Выделить всё

uart:
  rx_pin: GPIO3
  baud_rate: 9600

sensor:
  - platform: pmsx003
    type: PMSX003
    pm_1_0:
      name: "Частицы <1.0µm Concentration"
      filters:
        - lambda: if (id(pms_ready_to_read).state) { return(x); } else { return {}; };
    pm_2_5:
      name: "Частицы <2.5µm Concentration"
      filters:
        - lambda: if (id(pms_ready_to_read).state) { return(x); } else { return {}; };
    pm_10_0:
      name: "Частицы <10.0µm Concentration"
      filters:
        - lambda: if (id(pms_ready_to_read).state) { return(x); } else { return {}; };
      
switch:
  - platform: template
    name: "PMSX003 Ready to Read Post Warm-Up"
    id: pms_ready_to_read
    optimistic: true
    
  - platform: gpio
    pin: 
      number: GPIO23
    id: pms_set
 
interval:
  - interval: 5min
    then:
      - switch.turn_on: pms_set
      - delay: 30s
      - switch.turn_on: pms_ready_to_read
      - delay: 5s
      - switch.turn_off: pms_ready_to_read
      - switch.turn_off: pms_set