ESPHome
2026.6.0-dev
Loading...
Searching...
No Matches
esphome
components
sps30
automation.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
esphome/core/automation.h
"
4
#include "
esphome/core/helpers.h
"
5
#include "
sps30.h
"
6
7
namespace
esphome::sps30
{
8
9
template
<
typename
... Ts>
class
StartFanAction
:
public
Action
<Ts...>,
public
Parented
<SPS30Component> {
10
public
:
11
void
play
(
const
Ts &...
x
)
override
{ this->
parent_
->start_fan_cleaning(); }
12
};
13
14
template
<
typename
... Ts>
class
StartMeasurementAction
:
public
Action
<Ts...>,
public
Parented
<SPS30Component> {
15
public
:
16
void
play
(
const
Ts &...
x
)
override
{ this->
parent_
->start_measurement(); }
17
};
18
19
template
<
typename
... Ts>
class
StopMeasurementAction
:
public
Action
<Ts...>,
public
Parented
<SPS30Component> {
20
public
:
21
void
play
(
const
Ts &...
x
)
override
{ this->
parent_
->stop_measurement(); }
22
};
23
24
}
// namespace esphome::sps30
esphome::Action
Definition
automation.h:487
esphome::Parented
Helper class to easily give an object a parent of type T.
Definition
helpers.h:1861
esphome::Parented< SPS30Component >::parent_
SPS30Component * parent_
Definition
helpers.h:1872
esphome::sps30::StartFanAction
Definition
automation.h:9
esphome::sps30::StartFanAction::play
void play(const Ts &...x) override
Definition
automation.h:11
esphome::sps30::StartMeasurementAction
Definition
automation.h:14
esphome::sps30::StartMeasurementAction::play
void play(const Ts &...x) override
Definition
automation.h:16
esphome::sps30::StopMeasurementAction
Definition
automation.h:19
esphome::sps30::StopMeasurementAction::play
void play(const Ts &...x) override
Definition
automation.h:21
automation.h
helpers.h
esphome::sps30
Definition
automation.h:7
sps30.h
x
uint16_t x
Definition
tt21100.cpp:5
Generated by
1.12.0