2#if defined(USE_RP2040) && defined(USE_MDNS)
12#pragma push_macro("IRAM_ATTR")
14#include <ESP8266mDNS.h>
15#pragma pop_macro("IRAM_ATTR")
19static void register_rp2040(MDNSComponent *, StaticVector<MDNSService, MDNS_SERVICE_COUNT> &services) {
22 for (
const auto &service : services) {
27 auto *proto = MDNS_STR_ARG(service.proto);
28 while (*proto ==
'_') {
31 auto *service_type = MDNS_STR_ARG(service.service_type);
32 while (*service_type ==
'_') {
35 uint16_t port =
const_cast<TemplatableValue<uint16_t> &
>(service.port).value();
36 MDNS.addService(service_type, proto, port);
37 for (
const auto &record : service.txt_records) {
38 MDNS.addServiceTxt(service_type, proto, MDNS_STR_ARG(record.key), MDNS_STR_ARG(record.value));
62 MDNS.notifyAPChange();
const StringRef & get_name() const
Get the name of this Application set by pre_setup().
ESPDEPRECATED("Use const char* or uint32_t overload instead. Removed in 2026.7.0", "2026.1.0") void set_interval(const std voi set_interval)(const char *name, uint32_t interval, std::function< void()> &&f)
Set an interval function with a unique name.
constexpr const char * c_str() const
void on_shutdown() override
void setup_buffers_and_register_(PlatformRegisterFn platform_register)
static constexpr uint32_t MDNS_UPDATE_INTERVAL_MS
ESPHOME_ALWAYS_INLINE bool is_connected()
Return whether the node is connected to the network (through wifi, eth, ...)
void HOT delay(uint32_t ms)
Application App
Global storage of Application pointer - only one Application can exist.