mirror of
https://github.com/esphome/esphome.git
synced 2025-09-06 05:12:21 +01:00
mDNS updates (#4399)
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
#if defined(USE_ESP8266) && defined(USE_ARDUINO)
|
||||
|
||||
#include "mdns_component.h"
|
||||
#include "esphome/core/log.h"
|
||||
#include <ESP8266mDNS.h>
|
||||
#include "esphome/components/network/ip_address.h"
|
||||
#include "esphome/components/network/util.h"
|
||||
#include <ESP8266mDNS.h>
|
||||
#include "esphome/core/hal.h"
|
||||
#include "esphome/core/log.h"
|
||||
#include "mdns_component.h"
|
||||
|
||||
namespace esphome {
|
||||
namespace mdns {
|
||||
@@ -37,6 +38,11 @@ void MDNSComponent::setup() {
|
||||
|
||||
void MDNSComponent::loop() { MDNS.update(); }
|
||||
|
||||
void MDNSComponent::on_shutdown() {
|
||||
MDNS.close();
|
||||
delay(10);
|
||||
}
|
||||
|
||||
} // namespace mdns
|
||||
} // namespace esphome
|
||||
|
||||
|
Reference in New Issue
Block a user