7static const char *
const TAG =
"gpio.binary_sensor";
15 LOG_BINARY_SENSOR(
"",
"GPIO Binary Sensor",
this);
16 LOG_PIN(
" Pin: ", this->
pin_);
virtual bool digital_read()=0
void publish_initial_state(bool state)
Publish the initial state, this will not make the callback manager send callbacks and is meant only f...
void publish_state(bool state)
Publish a new state to the front-end.
void dump_config() override
void loop() override
Check sensor.
float get_setup_priority() const override
Hardware priority.
void setup() override
Setup pin.
const float HARDWARE
For components that deal with hardware and are very important like GPIO switch.
Providing packet encoding functions for exchanging data with a remote host.