From 4056d34bed8e7eeb754d20f73d22fae10356d1c7 Mon Sep 17 00:00:00 2001 From: Andre K Date: Wed, 17 Jan 2024 21:14:44 -0300 Subject: [PATCH 1/2] fix: `ipv4_config` byte order already little endian (#3073) Co-authored-by: Ben Meadors --- src/mesh/eth/ethClient.cpp | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/src/mesh/eth/ethClient.cpp b/src/mesh/eth/ethClient.cpp index f10c96866..97f5027bd 100644 --- a/src/mesh/eth/ethClient.cpp +++ b/src/mesh/eth/ethClient.cpp @@ -97,11 +97,6 @@ static int32_t reconnectETH() return 5000; // every 5 seconds } -static uint32_t bigToLittleEndian(uint32_t value) -{ - return ((value >> 24) & 0xFF) | ((value >> 8) & 0xFF00) | ((value << 8) & 0xFF0000) | ((value << 24) & 0xFF000000); -} - // Startup Ethernet bool initEthernet() { @@ -130,14 +125,7 @@ bool initEthernet() status = Ethernet.begin(mac); } else if (config.network.address_mode == meshtastic_Config_NetworkConfig_AddressMode_STATIC) { LOG_INFO("starting Ethernet Static\n"); - - IPAddress ip = IPAddress(bigToLittleEndian(config.network.ipv4_config.ip)); - IPAddress dns = IPAddress(bigToLittleEndian(config.network.ipv4_config.dns)); - IPAddress gateway = IPAddress(bigToLittleEndian(config.network.ipv4_config.gateway)); - IPAddress subnet = IPAddress(bigToLittleEndian(config.network.ipv4_config.subnet)); - - Ethernet.begin(mac, ip, dns, gateway, subnet); - + Ethernet.begin(mac, config.network.ipv4_config.ip, config.network.ipv4_config.dns, config.network.ipv4_config.subnet); status = 1; } else { LOG_INFO("Ethernet Disabled\n"); From a8b7490b6e456dd01ad710b6b1209d22a4ec82de Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 17 Jan 2024 18:15:00 -0600 Subject: [PATCH 2/2] [create-pull-request] automated change (#3106) Co-authored-by: thebentern --- protobufs | 2 +- src/mesh/generated/meshtastic/mesh.pb.h | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/protobufs b/protobufs index a5d410d40..092f7c043 160000 --- a/protobufs +++ b/protobufs @@ -1 +1 @@ -Subproject commit a5d410d40782d57efb1143250e8082124d1813f2 +Subproject commit 092f7c04305e6d8b6d4417a127fba695546857d8 diff --git a/src/mesh/generated/meshtastic/mesh.pb.h b/src/mesh/generated/meshtastic/mesh.pb.h index 743cfe737..69550296f 100644 --- a/src/mesh/generated/meshtastic/mesh.pb.h +++ b/src/mesh/generated/meshtastic/mesh.pb.h @@ -121,6 +121,10 @@ typedef enum _meshtastic_HardwareModel { meshtastic_HardwareModel_EBYTE_ESP32_S3 = 54, /* Waveshare ESP32-S3-PICO with PICO LoRa HAT and 2.9inch e-Ink */ meshtastic_HardwareModel_ESP32_S3_PICO = 55, + /* CircuitMess Chatter 2 LLCC68 Lora Module and ESP32 Wroom + Lora module can be swapped out for a Heltec RA-62 which is "almost" pin compatible + with one cut and one jumper Meshtastic works */ + meshtastic_HardwareModel_CHATTER_2 = 56, /* ------------------------------------------------------------------------------------------------------------------------------------------ Reserved ID For developing private Ports. These will show up in live traffic sparsely, so we can use a high number. Keep it within 8 bits. ------------------------------------------------------------------------------------------------------------------------------------------ */