mirror of
https://github.com/esphome/esphome.git
synced 2024-11-26 08:55:22 +01:00
Fixup dev branch again
Closes https://github.com/esphome/esphome/pull/706
This commit is contained in:
parent
2822fa4a40
commit
2b30cde125
2 changed files with 5 additions and 2 deletions
|
@ -2,7 +2,7 @@
|
|||
#include "esphome/core/log.h"
|
||||
|
||||
namespace esphome {
|
||||
namespace wifi_info_text_sensor {
|
||||
namespace wifi_info {
|
||||
|
||||
static const char *TAG = "wifi_info";
|
||||
|
||||
|
@ -10,5 +10,5 @@ void IPAddressWiFiInfo::dump_config() override { LOG_TEXT_SENSOR("", "WifiInfo I
|
|||
void SSIDWiFiInfo::dump_config() override { LOG_TEXT_SENSOR("", "WifiInfo SSID", this); }
|
||||
void BSSIDWiFiInfo::dump_config() override { LOG_TEXT_SENSOR("", "WifiInfo BSSID", this); }
|
||||
|
||||
} // namespace wifi_info_text_sensor
|
||||
} // namespace wifi_info
|
||||
} // namespace esphome
|
||||
|
|
|
@ -18,6 +18,7 @@ class IPAddressWiFiInfo : public Component, public text_sensor::TextSensor {
|
|||
}
|
||||
float get_setup_priority() const override { return setup_priority::AFTER_WIFI; }
|
||||
std::string unique_id() override { return get_mac_address() + "-wifiinfo-ip"; }
|
||||
void dump_config() override;
|
||||
|
||||
protected:
|
||||
IPAddress last_ip_;
|
||||
|
@ -34,6 +35,7 @@ class SSIDWiFiInfo : public Component, public text_sensor::TextSensor {
|
|||
}
|
||||
float get_setup_priority() const override { return setup_priority::AFTER_WIFI; }
|
||||
std::string unique_id() override { return get_mac_address() + "-wifiinfo-ssid"; }
|
||||
void dump_config() override;
|
||||
|
||||
protected:
|
||||
std::string last_ssid_;
|
||||
|
@ -52,6 +54,7 @@ class BSSIDWiFiInfo : public Component, public text_sensor::TextSensor {
|
|||
}
|
||||
float get_setup_priority() const override { return setup_priority::AFTER_WIFI; }
|
||||
std::string unique_id() override { return get_mac_address() + "-wifiinfo-bssid"; }
|
||||
void dump_config() override;
|
||||
|
||||
protected:
|
||||
wifi::bssid_t last_bssid_;
|
||||
|
|
Loading…
Reference in a new issue