mirror of
https://github.com/Laxilef/OTGateway.git
synced 2026-11-25 07:43:04 +05:00
feat: merge master Ethernet support into dev
Adapt W5500 to the native network event queue and select STA or ETH from NetworkSettings. Preserve the existing dev network settings and add a separate C6 Ethernet build without BLE to fit the OTA slot. Validate with S3 and C6 Ethernet firmware builds, the shared LittleFS image, binary layout checks and targeted network transition checks.
This commit is contained in:
commit
4e71915222
21 files changed
+1007
-158
No files matched your search
+26
-8
@@ -7,6 +7,7 @@
|
||||
#include "types.h"
|
||||
#include "Sensors.h"
|
||||
|
||||
// Keep the existing WiFi settings at the start of the persisted structure.
|
||||
struct NetworkSettings {
|
||||
char hostname[25] = DEFAULT_HOSTNAME;
|
||||
bool useDhcp = true;
|
||||
@@ -19,16 +20,33 @@ struct NetworkSettings {
|
||||
} staticConfig;
|
||||
|
||||
struct {
|
||||
char ssid[33] = DEFAULT_AP_SSID;
|
||||
char password[65] = DEFAULT_AP_PASSWORD;
|
||||
uint8_t channel = 6;
|
||||
} ap;
|
||||
struct {
|
||||
char ssid[33] = DEFAULT_AP_SSID;
|
||||
char password[65] = DEFAULT_AP_PASSWORD;
|
||||
uint8_t channel = 6;
|
||||
} ap;
|
||||
|
||||
struct {
|
||||
char ssid[33] = DEFAULT_STA_SSID;
|
||||
char password[65] = DEFAULT_STA_PASSWORD;
|
||||
uint8_t channel = 0;
|
||||
} sta;
|
||||
} wifi;
|
||||
|
||||
struct {
|
||||
char ssid[33] = DEFAULT_STA_SSID;
|
||||
char password[65] = DEFAULT_STA_PASSWORD;
|
||||
uint8_t channel = 0;
|
||||
} sta;
|
||||
EthernetType type = EthernetType::W5500;
|
||||
|
||||
struct {
|
||||
uint8_t clk = DEFAULT_ETH_CLK_GPIO;
|
||||
uint8_t mosi = DEFAULT_ETH_MOSI_GPIO;
|
||||
uint8_t miso = DEFAULT_ETH_MISO_GPIO;
|
||||
uint8_t cs = DEFAULT_ETH_CS_GPIO;
|
||||
uint8_t irq = DEFAULT_ETH_IRQ_GPIO;
|
||||
uint8_t rst = DEFAULT_ETH_RST_GPIO;
|
||||
} w5500;
|
||||
} ethernet;
|
||||
|
||||
NetworkMode type = NetworkMode::STA;
|
||||
};
|
||||
|
||||
struct SystemSettings {
|
||||
|
||||
Reference in new issue
Block a user