mirror of
https://github.com/rstrouse/ESPSomfy-RTS.git
synced 2026-02-17 12:12:11 +01:00
feat: ajout du support Ethernet W5500 SPI
- Intégration du contrôleur Ethernet W5500 via SPI pour les cartes comme Waveshare ESP32-S3 POE - Configuration des pins SPI (MOSI, MISO, SCLK, CS, INT, RST) via l'interface web - Utilisation directe des APIs ESP-IDF pour le W5500 car la classe Arduino ETH ne supporte pas nativement ce contrôleur - Gestion manuelle du DHCP et DNS pour le W5500 - Protection des appels ETH Arduino quand W5500 est utilisé - Désactivation temporaire de la vérification OTA GitHub pour W5500 (problème de compatibilité HTTPClient) - Ajout des presets de cartes dans l'interface (Waveshare, etc.)
This commit is contained in:
parent
eb75868adb
commit
0e0a482afb
8 changed files with 616 additions and 49 deletions
|
|
@ -1,4 +1,5 @@
|
|||
#include <Arduino.h>
|
||||
#include <esp_netif.h>
|
||||
|
||||
#ifndef Network_h
|
||||
#define Network_h
|
||||
|
|
@ -18,6 +19,13 @@ class Network {
|
|||
public:
|
||||
unsigned long lastWifiScan = 0;
|
||||
bool ethStarted = false;
|
||||
// W5500 SPI Ethernet state
|
||||
bool w5500LinkUp = false;
|
||||
bool w5500GotIP = false;
|
||||
IPAddress w5500IP;
|
||||
esp_netif_t *w5500_netif = nullptr;
|
||||
void *w5500_eth_handle = nullptr;
|
||||
void checkW5500Link();
|
||||
bool wifiFallback = false;
|
||||
bool softAPOpened = false;
|
||||
bool openingSoftAP = false;
|
||||
|
|
@ -55,5 +63,6 @@ class Network {
|
|||
void emitHeap(uint8_t num = 255);
|
||||
uint32_t getChipId();
|
||||
static void networkEvent(WiFiEvent_t event);
|
||||
static void w5500EventHandler(void *arg, esp_event_base_t event_base, int32_t event_id, void *event_data);
|
||||
};
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue