diff --git a/components/ratgdo/binary_sensor/ratgdo_binary_sensor.cpp b/components/ratgdo/binary_sensor/ratgdo_binary_sensor.cpp index abd05e0..7556f16 100644 --- a/components/ratgdo/binary_sensor/ratgdo_binary_sensor.cpp +++ b/components/ratgdo/binary_sensor/ratgdo_binary_sensor.cpp @@ -7,6 +7,8 @@ namespace esphome { namespace ratgdo { +using namespace esphome::binary_sensor; + static const char *const TAG = "ratgdo.binary_sensor"; class RATGDOBinarySensor { @@ -14,9 +16,6 @@ void dump_config() { LOG_BINARY_SENSOR("", "RATGDO BinarySensor", this); } -void setup() { - this->publish_internal_state(false); -} void on_door_state(esphome::ratgdo::DoorState state) {} void on_light_state(esphome::ratgdo::LightState state) {} void on_lock_state(esphome::ratgdo::LockState state) {} diff --git a/components/ratgdo/binary_sensor/ratgdo_binary_sensor.h b/components/ratgdo/binary_sensor/ratgdo_binary_sensor.h index c709f1b..6329abd 100644 --- a/components/ratgdo/binary_sensor/ratgdo_binary_sensor.h +++ b/components/ratgdo/binary_sensor/ratgdo_binary_sensor.h @@ -11,7 +11,6 @@ namespace ratgdo { class RATGDOBinarySensor : public binary_sensor::BinarySensor, public RATGDOClient, public Component { public: - void setup() override; void dump_config() override; void on_door_state(esphome::ratgdo::DoorState state) override;