1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2024-12-23 21:01:25 +01:00

lib_ignore wifi for F429ZI and F439ZI

and update Ethernet disconnect messages
This commit is contained in:
Ash-4 2024-02-04 23:23:56 -06:00
parent 06fb74c3d7
commit 7679710c23
2 changed files with 19 additions and 4 deletions

View File

@ -182,11 +182,15 @@ bool EthernetInterface::checkLink() {
if (ip[0] == 0)
LCD(4,F("Awaiting DHCP..."));
while (ip[0] == 0) { // wait until we are given an IP address from the DHCP server
// LCD(4,F("."));
ip = Ethernet.localIP(); // look what IP was obtained (dynamic or static)
}
LCD(4,F("IP: %d.%d.%d.%d"), ip[0], ip[1], ip[2], ip[3]);
LCD(5,F("Port:%d"), IP_PORT);
if (MAX_MSG_SIZE < 20) {
LCD(4,F("%d.%d.%d.%d"), ip[0], ip[1], ip[2], ip[3]);
LCD(5,F("Port:%d Eth"), IP_PORT);
} else {
LCD(4,F("Ethernet UP"));
LCD(5,F("%d.%d.%d.%d:%d"), ip[0], ip[1], ip[2], ip[3], IP_PORT);
}
mdns.begin(Ethernet.localIP(), WIFI_HOSTNAME); // hostname
mdns.addServiceRecord(WIFI_HOSTNAME "._withrottle", IP_PORT, MDNSServiceTCP);
// only create a outboundRing it none exists, this may happen if the cable
@ -208,7 +212,8 @@ bool EthernetInterface::checkLink() {
// tear down server
delete server;
server = nullptr;
LCD(4,F("IP: None"));
LCD(4,F("Ethernet DOWN"));
LCD(5,F(" "));
}
}
return false;

View File

@ -252,6 +252,11 @@ lib_deps = ${env.lib_deps}
stm32duino/STM32Ethernet @ ^1.3.0
stm32duino/STM32duino LwIP @ ^2.1.2
MDNS_Generic
lib_ignore = WiFi101
WiFi101_Generic
WiFiEspAT
WiFiMulti_Generic
WiFiNINA_Generic
build_flags = -std=c++17 -Os -g2 -Wunused-variable
monitor_speed = 115200
monitor_echo = yes
@ -268,6 +273,11 @@ lib_deps = ${env.lib_deps}
stm32duino/STM32Ethernet @ ^1.3.0
stm32duino/STM32duino LwIP @ ^2.1.2
MDNS_Generic
lib_ignore = WiFi101
WiFi101_Generic
WiFiEspAT
WiFiMulti_Generic
WiFiNINA_Generic
build_flags = -std=c++17 -Os -g2 -Wunused-variable
monitor_speed = 115200
monitor_echo = yes