MESHCN Firmware: Extending an Off-Grid LoRa Mesh Network with W5100S Ethernet
LoRa mesh networking platform designed to exchange text messages, location data, and telemetry without relying on Internet or cellular infrastructure
MESHCN Firmware: W5100S Ethernet으로 확장하는 오프그리드 LoRa 메시 네트워크
MESHCN Firmware는 인터넷이나 셀룰러 통신망 없이도 LoRa 노드 간 텍스트 메시지, 위치 정보와 텔레메트리를 전달할 수 있도록 개발된 오픈소스 메시 네트워크 펌웨어입니다. ESP32, nRF52, RP2040·RP2350 및 Linux 장치를 지원하며, 일부 Ethernet 지원 장치에서는 WIZnet W5100S 기반 RAK13800 모듈 또는 W5500 계열 인터페이스를 통해 TCP API, MQTT와 유선 네트워크 기능을 확장할 수 있습니다.
인터넷이 없어도 동작하는 LoRa 메시 네트워크
MESHCN은 인터넷, 이동통신망 또는 중앙 서버에 의존하지 않고 LoRa 장치들이 서로 메시지를 전달할 수 있도록 설계된 오픈소스 메시 네트워크 프로젝트입니다.
각 노드는 LoRa를 통해 인접 노드와 통신하며, 메시지는 필요한 경우 여러 노드를 거쳐 목적지까지 전달됩니다.
주요 기능은 다음과 같습니다.
- 텍스트 메시지 전송
- 노드 간 위치 정보 공유
- 센서 및 장치 텔레메트리
- 분산형 LoRa 메시 네트워크
- 인터넷과 셀룰러망이 없는 환경에서의 통신
- 야외 활동, 비상 통신 및 원격 작업 지원
MESHCN 펌웨어는 ESP32, nRF52, RP2040·RP2350 및 Linux 기반 장치 등 다양한 하드웨어 플랫폼을 지원합니다.
원본 저장소:
https://github.com/chinamesh/meshcn-firmware
공식 사이트:
프로젝트의 기본 구조
MESHCN Firmware는 여러 MCU와 LoRa 무선 칩을 지원하는 대규모 멀티 플랫폼 펌웨어입니다.
리포지토리는 다음과 같은 주요 영역으로 구성됩니다.
| 영역 | 역할 |
|---|---|
boards | 지원 보드 정의 |
variants | 보드별 GPIO와 하드웨어 설정 |
src/mesh | 메시 라우팅과 네트워크 기능 |
src/modules | 위치, 텔레메트리, 알림 등 기능 모듈 |
src/mqtt | MQTT 연동 |
src/platform | ESP32, nRF52, RP2xxx 및 Linux 플랫폼 코드 |
src/mesh/api | TCP 기반 장치 API |
platformio.ini | 지원 보드별 PlatformIO 빌드 환경 |
펌웨어는 C와 C++를 중심으로 개발되며, PlatformIO 기반의 빌드 구성을 제공합니다.
전체 통신 구조
MESHCN의 기본 통신 경로는 LoRa 메시 네트워크입니다.
Mobile or Local Client
→ MESHCN Node
→ LoRa Mesh
→ Relay Nodes
→ Destination Node
Ethernet 지원 노드를 사용하면 LoRa 메시 네트워크와 기존 IP 네트워크 사이에 추가적인 연결 경로를 만들 수 있습니다.
LoRa Mesh
↔ MESHCN Ethernet Node
↔ W5100S or W5500 Ethernet
↔ Local Server, TCP Client or MQTT Broker
따라서 Ethernet은 모든 LoRa 노드를 대체하는 것이 아니라, 고정형 게이트웨이·중계기·관리 노드에 유선 백홀을 제공하는 역할을 합니다.
WIZnet Ethernet 지원
MESHCN 코드에서는 두 가지 Ethernet 경로를 확인할 수 있습니다.
1. RAK13800과 W5100S
nRF52 기반 Ethernet 구현은 RAK13800_W5100S.h 라이브러리를 사용합니다.
RAK13800은 RAK WisBlock 시스템용 Ethernet 모듈이며 WIZnet W5100S를 기반으로 합니다.
코드에서는 다음 기능에 W5100S Ethernet 인터페이스를 사용합니다.
- Ethernet Client
- Ethernet Server
- Ethernet UDP
- TCP 기반 장치 API
- 네트워크 연결 관리
- MQTT 연동 기반
이 구조는 RAK4631과 RAK13800을 조합한 고정형 LoRa 메시 게이트웨이에 적합합니다.
2. ESP32 계열 W5500 경로
ESP32 계열 코드에는 USE_WS5500이라는 빌드 매크로가 존재합니다.
이 이름은 코드에서 실제로 사용되는 표기이며, W5500 Ethernet을 위한 별도 구현 경로로 해석할 수 있습니다.
해당 경로에서는 ETHClass2.h를 불러오고 ETH2 객체를 Ethernet 인터페이스로 사용합니다.
다만 매크로가 일반적인 USE_W5500이 아니라 USE_WS5500으로 작성되어 있으므로, 보드 설정을 분석하거나 새 하드웨어를 추가할 때 철자를 그대로 확인해야 합니다.
TCP API 서버
MESHCN은 Ethernet을 통해 장치와 직접 통신할 수 있는 TCP API 서버 구조를 포함합니다.
코드에서는 API 서버가 TCP 포트 4403에서 연결을 기다리도록 구성되어 있습니다.
동작 흐름은 다음과 같습니다.
Local Application
→ Ethernet TCP
→ MESHCN API Server : 4403
→ MESHCN Device
→ LoRa Mesh
TCP 클라이언트가 연결되면 MESHCN 장치와 직렬 API와 유사한 메시지 교환을 수행할 수 있습니다.
이를 활용하면 다음 구성이 가능합니다.
- Ethernet을 통한 장치 설정
- 로컬 서버에서 메시 노드 관리
- LoRa 메시의 유선 네트워크 연동
- 고정형 게이트웨이 운영
- 원격 로그 및 상태 수집
MQTT 연동
펌웨어에는 MQTT 모듈도 포함되어 있습니다.
MQTT를 활성화한 Ethernet 노드는 LoRa 메시 네트워크의 데이터를 MQTT Broker로 전달하거나, Broker에서 수신한 메시지를 LoRa 네트워크로 전송하는 게이트웨이 역할을 할 수 있습니다.
개념적인 데이터 흐름은 다음과 같습니다.
Remote LoRa Nodes
→ LoRa Mesh
→ Ethernet Gateway
→ W5100S Ethernet
→ MQTT Broker
반대 방향에서는 다음과 같이 동작할 수 있습니다.
MQTT Broker
→ Ethernet Gateway
→ LoRa Mesh
→ Remote Nodes
이 구조는 인터넷 없이 동작하는 로컬 메시 네트워크를 기존 모니터링 시스템이나 사설 서버와 연결할 때 유용합니다.
LoRa 메시 네트워크에 Ethernet을 추가하는 이유
LoRa는 장거리·저전력 통신에 적합하지만 전송 속도가 낮고, 일반적인 IP 네트워크에 직접 연결되지는 않습니다.
Ethernet은 고정형 MESHCN 노드에 다음 장점을 제공합니다.
- 안정적인 상시 네트워크 연결
- Wi-Fi 간섭 없이 동작
- 서버실·관제실 네트워크에 직접 연결
- MQTT Broker와 지속적인 연결
- 고정 IP를 이용한 장치 관리
- TCP API를 통한 로컬 제어
- 메시 네트워크의 유선 백홀 구성
특히 산 정상, 건물 옥상 또는 외부 중계 노드는 LoRa 통신을 담당하고, 실내 게이트웨이는 W5100S Ethernet으로 서버와 연결하는 방식이 적합합니다.
RAK13800 W5100S 구조의 장점
RAK13800은 WisBlock 시스템의 모듈형 구조를 이용해 nRF52840 기반 RAK4631에 Ethernet을 추가합니다.
이 조합의 주요 장점은 다음과 같습니다.
- 저전력 nRF52840 기반 LoRa 노드
- SX1262 장거리 LoRa 통신
- W5100S 하드웨어 TCP/IP
- SPI 기반 Ethernet 연결
- RAK WisBlock 모듈식 확장
- 고정형 LoRa-to-Ethernet 게이트웨이 구성
LoRa 무선 처리와 IP 네트워크 처리를 기능적으로 분리할 수 있어 메시 네트워크 게이트웨이 구성에 적합합니다.
활용 사례
MESHCN Ethernet 노드는 다음 환경에 활용할 수 있습니다.
- 재난 대응용 독립 통신망
- 인터넷 음영 지역의 메시 통신
- 산악 활동과 야외 탐사
- 대규모 행사 임시 통신망
- 산업 현장 원격 텔레메트리
- 농업·산림 센서 네트워크
- 로컬 MQTT 기반 관제 시스템
- 건물 간 LoRa 메시 백본
- 고정형 메시 중계기
- 서버 연결형 LoRa 게이트웨이
WIZnet Maker 유사 콘텐츠 비교
MESHCN과 유사한 Maker 콘텐츠들은 LoRa 메시 네트워크에 WIZnet Ethernet을 추가해 안정적인 게이트웨이나 관리 채널을 구현합니다.
| 유사 콘텐츠 및 링크 | 공통점 | MESHCN의 차이점 |
|---|---|---|
| Meshtastic Firmware | 오프그리드 LoRa 메시 펌웨어에서 W5100S 또는 W5500 Ethernet을 이용해 API, 시간 동기화와 Gateway 기능을 제공합니다. | MESHCN은 Meshtastic 계열 구조를 중국 지역 커뮤니티와 장치 환경에 맞춰 운영하는 별도 펌웨어 프로젝트입니다. 다중 플랫폼 코드와 W5100S·W5500 Ethernet 경로가 하나의 저장소에 포함됩니다. |
| WisMesh Ethernet MQTT Gateway | RAK4631, SX1262와 RAK13800 W5100S를 결합해 LoRa 메시 데이터를 Ethernet MQTT로 전달합니다. | WisMesh는 조립·판매되는 완성형 Gateway 제품입니다. MESHCN은 여러 보드에서 사용할 수 있는 오픈소스 펌웨어이며, 특정 하드웨어 제품 하나에 한정되지 않습니다. |
| MeshCore | 인터넷 없이 동작하는 LoRa 메시 네트워크에 RAK13800 W5100S Ethernet 관리 기능을 추가합니다. | MeshCore는 자체 경량 메시 프로토콜을 사용하는 별도 프로젝트입니다. MESHCN은 텍스트, 위치, 텔레메트리와 다양한 장치 모듈을 포함하는 대규모 멀티 플랫폼 펌웨어입니다. |
| MeshCom | LoRa 메시 노드에 W5500 Ethernet을 추가해 Internet 또는 HAMNET의 UDP 서비스와 연결합니다. | MeshCom은 아마추어 무선과 UDP 게이트웨이 활용에 집중합니다. MESHCN은 TCP API, MQTT, 위치 공유와 일반 사용자용 오프그리드 메시 기능을 폭넓게 지원합니다. |
| How to Build a Meshtastic Ethernet Gateway with W5500 on Raspberry Pi Pico 2? | LoRa 무선과 W5500 Ethernet을 하나의 고정형 게이트웨이에 결합합니다. | 해당 프로젝트는 RP2350, E22 LoRa와 W5500을 결합한 특정 하드웨어 보드입니다. MESHCN은 ESP32, nRF52, RP2040·RP2350와 Linux까지 지원하는 펌웨어 플랫폼입니다. |
유사 콘텐츠와 비교한 MESHCN의 특징
1. 단일 장치가 아닌 멀티 플랫폼 펌웨어
많은 LoRa-to-Ethernet 프로젝트는 하나의 특정 보드나 완제품을 대상으로 합니다.
MESHCN은 ESP32, nRF52, RP2040·RP2350와 Linux 환경을 하나의 코드베이스에서 지원합니다.
2. Ethernet Gateway 이상의 기능
MESHCN은 센서 데이터를 MQTT로 전달하는 단순 Gateway에 한정되지 않습니다.
텍스트 메시지, 위치 공유, 텔레메트리, 원격 관리와 다양한 기능 모듈을 하나의 메시 네트워크에서 운영합니다.
3. W5100S와 W5500 계열 지원 경로
nRF52에서는 RAK13800 W5100S 라이브러리를 사용하며, ESP32 환경에서는 USE_WS5500과 ETHClass2 기반의 W5500 경로를 제공합니다.
따라서 하드웨어 플랫폼에 따라 다른 WIZnet Ethernet 구성을 선택할 수 있습니다.
4. TCP API와 MQTT를 동시에 고려한 구조
Ethernet은 단순히 인터넷 연결만 제공하지 않습니다.
MESHCN 장치에 직접 접속하는 TCP API와 메시 데이터를 서버로 전달하는 MQTT Gateway 기능을 함께 구성할 수 있습니다.
확인이 필요한 사항
MESHCN을 실제 Ethernet 노드로 빌드하기 전에는 다음 항목을 확인해야 합니다.
- 사용할 보드의 정확한 PlatformIO 환경
HAS_ETHERNET빌드 설정- W5100S 또는 W5500 적용 여부
USE_WS5500매크로의 보드별 적용 상태- Ethernet CS, RESET, INT와 SPI 핀
- LoRa와 Ethernet의 SPI 버스 공유 여부
- DHCP 또는 정적 IP 설정
- MQTT Broker 주소와 인증 설정
- TCP 4403 포트의 네트워크 접근 정책
- 장시간 연결과 재연결 동작
- 외부 네트워크 공개 시 보안 설정
FAQ
Q1. MESHCN은 인터넷이 없어도 동작하나요?
네.
기본 메시 통신은 LoRa 노드 간에 이루어지므로 인터넷이나 셀룰러망이 없어도 텍스트, 위치와 텔레메트리를 전달할 수 있습니다.
Q2. Ethernet이 모든 노드에 필요한가요?
아닙니다.
배터리로 동작하는 이동형 노드는 LoRa만 사용하고, 서버나 MQTT Broker에 연결되는 고정형 Gateway에만 Ethernet을 추가하는 구성이 일반적입니다.
Q3. MESHCN은 어떤 WIZnet 제품을 지원하나요?
코드에서 명확하게 확인되는 제품은 RAK13800 모듈에 사용된 W5100S입니다.
ESP32 계열에는 USE_WS5500이라는 매크로와 ETHClass2 기반 별도 경로가 있어 W5500 Ethernet 지원도 포함된 것으로 판단됩니다.
Q4. USE_WS5500은 오타인가요?
일반적인 제품명은 W5500이지만, 프로젝트 코드에서는 USE_WS5500이라는 이름을 사용합니다.
빌드 설정과 조건부 컴파일에서 이 이름을 그대로 사용하므로 임의로 수정하면 빌드가 실패할 수 있습니다.
Q5. Ethernet 노드는 어떤 역할을 하나요?
LoRa 메시 네트워크와 로컬 IP 네트워크 사이의 Gateway 또는 관리 노드로 동작할 수 있습니다.
TCP API, MQTT Broker 연결, 로그 전달과 장치 설정 등에 활용할 수 있습니다.
Q6. MESHCN 장치에 TCP로 직접 연결할 수 있나요?
Ethernet API 서버는 TCP 포트 4403을 사용하도록 구현되어 있습니다.
네트워크 보안 설정과 방화벽을 확인한 뒤 로컬 애플리케이션에서 연결할 수 있습니다.
Q7. W5100S가 LoRa 메시를 대신 처리하나요?
아닙니다.
LoRa 메시 라우팅은 MCU와 LoRa 무선 칩이 처리합니다. W5100S는 Ethernet TCP/IP 연결을 담당합니다.
Q8. MQTT를 사용하려면 인터넷이 필요한가요?
공용 Cloud Broker를 사용하면 인터넷 연결이 필요합니다.
하지만 같은 로컬 네트워크에 MQTT Broker를 설치하면 외부 인터넷 없이도 Ethernet Gateway와 서버를 연동할 수 있습니다.
Q9. LoRa와 Ethernet이 같은 SPI 버스를 사용할 수 있나요?
보드 설계에 따라 가능합니다.
각 장치에 별도의 Chip Select를 지정하고, 비활성 장치의 CS를 HIGH로 유지해야 합니다. 동시에 사용하는 경우 SPI Clock, 인터럽트와 버스 충돌도 확인해야 합니다.
Q10. 이 프로젝트의 가장 큰 특징은 무엇인가요?
다양한 MCU와 LoRa 하드웨어를 지원하는 오프그리드 메시 펌웨어에 W5100S·W5500 Ethernet, TCP API와 MQTT 연동 구조를 함께 포함한다는 점입니다.
WIZnet 관점의 가치
MESHCN은 WIZnet Ethernet이 LoRa 센서 데이터를 Cloud로 전달하는 용도뿐 아니라, 분산형 메시 네트워크의 고정형 백홀과 관리 인터페이스로 활용될 수 있음을 보여줍니다.
특히 W5100S 기반 RAK13800은 저전력 nRF52 LoRa 플랫폼에 안정적인 유선 IP 연결을 추가합니다.
이를 통해 이동형 노드는 LoRa 저전력 통신을 유지하면서, 고정형 Gateway는 Ethernet을 통해 TCP API, MQTT와 서버 연동을 제공할 수 있습니다.
결론
MESHCN Firmware는 인터넷이나 셀룰러망 없이도 텍스트, 위치 정보와 텔레메트리를 전달할 수 있는 오픈소스 LoRa 메시 네트워크 펌웨어입니다.
펌웨어는 다양한 MCU 플랫폼을 지원하며, W5100S 기반 RAK13800과 W5500 계열 Ethernet 경로를 통해 메시 네트워크를 기존 IP 네트워크로 확장합니다.
Ethernet 노드는 TCP API, MQTT와 서버 연결을 제공하면서도 원격 노드 간 LoRa 통신은 그대로 유지합니다.
이 프로젝트는 WIZnet의 하드웨어 TCP/IP가 오프그리드 통신망과 기존 유선 인프라를 연결하는 안정적인 Gateway 인터페이스로 활용될 수 있음을 보여주는 사례입니다.
MESHCN Firmware: Extending an Off-Grid LoRa Mesh Network with W5100S Ethernet
MESHCN Firmware is an open-source LoRa mesh networking platform designed to exchange text messages, location data, and telemetry without relying on Internet or cellular infrastructure. It supports ESP32, nRF52, RP2040/RP2350, and Linux-based devices. Selected Ethernet-enabled builds use the WIZnet W5100S-based RAK13800 module or a separate W5500 implementation to provide TCP API, MQTT, and wired gateway connectivity.
An Off-Grid LoRa Mesh Network
MESHCN is an open-source mesh networking project that allows LoRa devices to communicate without depending on the Internet, cellular service, or a centralized server.
Each node exchanges data with nearby LoRa nodes. When necessary, packets can travel across multiple relay nodes to reach their destination.
The firmware provides:
- Text messaging
- Location sharing
- Device and sensor telemetry
- Decentralized LoRa mesh communication
- Operation without Internet or cellular infrastructure
- Support for outdoor, emergency, and remote operations
- MESHCN Firmware supports several hardware platforms, including ESP32, nRF52, RP2040/RP2350, and Linux-based devices.
Original repository:
https://github.com/chinamesh/meshcn-firmware
Official website:
Project Architecture
MESHCN Firmware is a large multi-platform codebase supporting multiple MCUs, LoRa radios, and device variants.
| Area | Role |
|---|---|
boards | Supported-board definitions |
variants | Board-specific GPIO and hardware configuration |
src/mesh | Mesh routing and network functions |
src/modules | Position, telemetry, notification, and application modules |
src/mqtt | MQTT connectivity |
src/platform | ESP32, nRF52, RP2xxx, and Linux platform code |
src/mesh/api | TCP-based device API |
platformio.ini | PlatformIO build environments |
The project is developed mainly in C and C++ and uses PlatformIO for embedded builds.
Communication Architecture
The primary communication path is the LoRa mesh network.
Mobile or Local Client
→ MESHCN Node
→ LoRa Mesh
→ Relay Nodes
→ Destination Node
An Ethernet-enabled node can add a connection between the LoRa network and an existing IP network.
LoRa Mesh
↔ MESHCN Ethernet Node
↔ W5100S or W5500 Ethernet
↔ Local Server, TCP Client, or MQTT Broker
Ethernet does not replace the LoRa network. It provides a wired backhaul for a fixed gateway, relay, or management node.
WIZnet Ethernet Support
Two Ethernet paths can be identified in the MESHCN codebase.
RAK13800 with W5100S
The nRF52 Ethernet implementation includes the RAK13800_W5100S.h library.
The RAK13800 is a WisBlock Ethernet module based on the WIZnet W5100S.
The firmware uses this Ethernet stack for:
- Ethernet clients
- Ethernet servers
- Ethernet UDP
- TCP-based device APIs
- Network connection management
- MQTT integration
This makes the RAK4631 and RAK13800 combination suitable for a fixed LoRa mesh gateway.
ESP32 W5500 Path
ESP32-related code contains a build macro named:
USE_WS5500
This is the exact identifier used by the project. It appears to represent a separate W5500 Ethernet implementation.
When enabled, the firmware includes ETHClass2.h and uses the ETH2 object as the Ethernet interface.
Because the code uses USE_WS5500 rather than the more expected USE_W5500, developers must check and preserve the exact macro name when configuring a build.
TCP API Server
MESHCN includes a TCP API server for direct network communication with the device.
The Ethernet API server is configured to listen on TCP port 4403.
The data path is:
Local Application
→ Ethernet TCP
→ MESHCN API Server : 4403
→ MESHCN Device
→ LoRa Mesh
A local client can use this connection for device configuration and mesh communication.
Possible applications include:
- Ethernet-based device configuration
- Local server integration
- LoRa message forwarding
- Fixed gateway operation
- Remote logging and monitoring
MQTT Integration
The firmware also contains an MQTT module.
An Ethernet-enabled gateway can forward LoRa mesh messages to an MQTT broker or receive broker messages and inject them into the mesh network.
Remote LoRa Nodes
→ LoRa Mesh
→ Ethernet Gateway
→ W5100S Ethernet
→ MQTT Broker
The reverse direction can also be supported:
MQTT Broker
→ Ethernet Gateway
→ LoRa Mesh
→ Remote Nodes
This architecture is useful for connecting an off-grid local mesh network to an existing monitoring platform or private server.
Why Add Ethernet to a LoRa Mesh?
LoRa provides long-range, low-power communication, but it has a limited data rate and does not directly connect to an IP network.
A wired Ethernet interface provides a fixed MESHCN node with:
- Stable, continuous connectivity
- Operation without Wi-Fi interference
- Direct connection to control-room or server networks
- Persistent MQTT broker connectivity
- Static-IP device management
- Local control through a TCP API
- A wired backhaul for the mesh network
- A typical deployment can use outdoor LoRa repeaters and a fixed indoor W5100S Ethernet gateway connected to a server.
Advantages of the RAK13800 W5100S Architecture
The RAK13800 adds Ethernet to the modular WisBlock platform.
Combined with the RAK4631, the architecture provides:
- A low-power nRF52840 MCU
- SX1262 long-range LoRa communication
- W5100S hardware TCP/IP
- SPI Ethernet connectivity
- Modular WisBlock expansion
- A fixed LoRa-to-Ethernet gateway platform
- The wireless and IP-networking functions are separated, making the system suitable for reliable mesh gateways.
Potential Applications
MESHCN Ethernet nodes can be used for:
- Disaster-response communication
- Mesh networking in areas without Internet coverage
- Hiking and outdoor expeditions
- Temporary communication at large events
- Industrial remote telemetry
- Agriculture and forest sensor networks
- Local MQTT monitoring
- LoRa backbones between buildings
- Fixed mesh repeaters
- Server-connected LoRa gateways
Comparison with Similar WIZnet Maker Projects
| Similar Project and Link | Common Points | How MESHCN Is Different |
|---|---|---|
| Meshtastic Firmware | Adds W5100S or W5500 Ethernet to an off-grid LoRa mesh firmware for API, time synchronization, and gateway functions. | MESHCN is a separate firmware and community project adapted for its regional device ecosystem. It includes multi-platform firmware and both W5100S and W5500 Ethernet paths in one repository. |
| WisMesh Ethernet MQTT Gateway | Combines the RAK4631, SX1262, and RAK13800 W5100S to send LoRa mesh data to MQTT over Ethernet. | WisMesh is an assembled commercial gateway product. MESHCN is open-source firmware that supports multiple boards rather than one finished device. |
| MeshCore | Adds RAK13800 W5100S Ethernet management to an off-grid LoRa messaging network. | MeshCore uses its own lightweight mesh protocol. MESHCN is a larger multi-platform firmware with text, position, telemetry, and multiple device modules. |
| MeshCom | Adds W5500 Ethernet to LoRa mesh nodes for Internet or HAMNET UDP services. | MeshCom focuses on amateur-radio and UDP gateways. MESHCN provides TCP API, MQTT, location sharing, and general off-grid messaging functions. |
| How to Build a Meshtastic Ethernet Gateway with W5500 on Raspberry Pi Pico 2? | Combines LoRa and W5500 Ethernet in a fixed gateway. | That project is a specific RP2350, E22, and W5500 carrier board. MESHCN is firmware supporting ESP32, nRF52, RP2040/RP2350, and Linux devices. |
Key Differences
Multi-Platform Firmware Rather Than One Device
Many LoRa-to-Ethernet projects target one particular board or finished gateway.
MESHCN supports multiple MCU families and device variants in one codebase.
More Than an Ethernet Data Gateway
MESHCN is not limited to forwarding sensor telemetry.
It supports messaging, position sharing, telemetry, remote management, and multiple application modules within the same mesh network.
W5100S and W5500 Implementation Paths
The nRF52 implementation uses the RAK13800 W5100S library.
The ESP32 code includes a separate W5500-related path using USE_WS5500 and ETHClass2.
TCP API and MQTT
Ethernet provides more than Internet access.
A MESHCN Ethernet node can offer a direct TCP API while also operating as an MQTT gateway.
Items to Verify Before Building
Before creating an Ethernet-enabled MESHCN device, verify:
- The correct PlatformIO board environment
- The
HAS_ETHERNETbuild setting - Whether the target uses W5100S or W5500
- The board-specific use of
USE_WS5500 - Ethernet CS, RESET, interrupt, and SPI pins
- SPI sharing between LoRa and Ethernet
- DHCP or static-IP configuration
- MQTT broker address and credentials
- Network access policy for TCP port 4403
- Reconnection and extended-operation behavior
- Security before exposing the node outside a private network
FAQ
Q1. Can MESHCN work without Internet access?
Yes.
Core messaging, position sharing, and telemetry use the LoRa mesh and do not require Internet or cellular connectivity.
Q2. Does every node need Ethernet?
No.
Mobile and battery-powered nodes can use LoRa only. Ethernet is most useful on a fixed gateway connected to a server or MQTT broker.
Q3. Which WIZnet devices are supported?
The clearest confirmed implementation is the W5100S used by the RAK13800 module.
The ESP32 code also contains a USE_WS5500 and ETHClass2 path that appears to provide W5500 Ethernet support.
Q4. Is USE_WS5500 a typo?
W5500 is the standard product name, but the firmware uses USE_WS5500 as its actual build identifier.
Developers should preserve the identifier unless they update every related conditional-compilation reference.
Q5. What does an Ethernet node do?
It can act as a gateway or management node between the LoRa mesh and an IP network.
It may provide a TCP API, MQTT connectivity, logging, and device configuration.
Q6. Can an application connect directly to MESHCN over TCP?
The Ethernet API server is configured to listen on TCP port 4403.
Access should be limited and protected according to the local network’s security policy.
Q7. Does the W5100S process the LoRa mesh?
No.
The MCU and LoRa radio handle mesh communication. The W5100S handles the wired TCP/IP connection.
Q8. Does MQTT require public Internet access?
Not necessarily.
A local MQTT broker can be deployed on the same private network, allowing the system to operate without external Internet access.
Q9. Can LoRa and Ethernet share the same SPI bus?
They can on an appropriately designed board.
Each device requires its own chip-select signal, and inactive devices must remain deselected. SPI timing and interrupt behavior must also be verified.
Q10. What is the main value of this project?
It combines multi-platform off-grid LoRa mesh firmware with W5100S/W5500 Ethernet, a TCP API, and MQTT gateway functions.
Value from a WIZnet Perspective
MESHCN demonstrates that WIZnet Ethernet can serve not only as a cloud uplink for LoRa sensors, but also as the fixed backhaul and management interface of a decentralized mesh network.
The W5100S-based RAK13800 provides a low-power nRF52 LoRa platform with reliable wired IP connectivity.
Mobile nodes can retain low-power LoRa communication, while fixed gateways provide TCP API, MQTT, and server integration over Ethernet.
Conclusion
MESHCN Firmware is an open-source LoRa mesh platform that exchanges text messages, position data, and telemetry without relying on Internet or cellular infrastructure.
The firmware supports multiple MCU platforms and extends the mesh into existing IP networks through the W5100S-based RAK13800 and a W5500-related Ethernet path.
Ethernet-enabled nodes can provide TCP API, MQTT, and server connectivity while preserving LoRa communication between remote nodes.
The project demonstrates how WIZnet hardware TCP/IP can provide a stable gateway interface between an off-grid communication network and existing wired infrastructure.

