mirror of
https://github.com/thooge/esp32-nmea2000-obp60.git
synced 2025-12-15 15:03:07 +01:00
add mdns
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
#include <WebServer.h>
|
||||
#include <Preferences.h>
|
||||
#include <ArduinoJson.h>
|
||||
#include <ESPmDNS.h>
|
||||
|
||||
#include "N2kDataToNMEA0183.h"
|
||||
|
||||
@@ -191,7 +192,7 @@ void setup() {
|
||||
sendTCP=config.getConfigItem(config.sendTCP,true);
|
||||
sendSeasmart=config.getConfigItem(config.sendSeasmart,true);
|
||||
systemName=config.getConfigItem(config.systemName,true);
|
||||
|
||||
MDNS.begin(config.getConfigItem(config.systemName)->asCString());
|
||||
gwWifi.setup();
|
||||
|
||||
// Start TCP server
|
||||
@@ -209,6 +210,8 @@ void setup() {
|
||||
webserver.begin();
|
||||
Serial.println("HTTP server started");
|
||||
|
||||
MDNS.addService("_http","_tcp",80);
|
||||
|
||||
// Reserve enough buffer for sending all messages. This does not work on small memory devices like Uno or Mega
|
||||
|
||||
NMEA2000.SetN2kCANMsgBufSize(8);
|
||||
|
||||
Reference in New Issue
Block a user