Skip to content

Commit

Permalink
Merge pull request #3 from soylentOrange/mDNS
Browse files Browse the repository at this point in the history
enable mDNS
  • Loading branch information
soylentOrange authored Oct 6, 2024
2 parents ec6e4df + 32f13f2 commit f0bc9bf
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <WiFi.h>
#include <AsyncTCP.h>
#include <WiFiManager.h>
#include <ESPmDNS.h>
#include <ESPAsyncWebServer.h>
#include <Preferences.h>
#include <Logging.h>
Expand Down Expand Up @@ -67,8 +68,12 @@ void setup() {
}
MBbridge.start(config.getTcpPort(), 10, config.getTcpTimeout());
dbgln("[modbus] finished");
dbgln("[server] start");
setupPages(&webServer, MBclient, &MBbridge, &config, &wm);
webServer.begin();
MDNS.begin(WiFi.getHostname());
MDNS.addService("http", "tcp", 80);
dbgln("[server] finished");
dbgln("[setup] finished");
}

Expand Down

0 comments on commit f0bc9bf

Please sign in to comment.