Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions FLASHING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Flashing RAK13800 Ethernet Companion Targets

Use the canonical PlatformIO target names:

- `RAK_RAK13800_companion_radio_eth`
- `RAK_RAK13800_companion_radio_eth_static_diag`

These are RAK13800 Ethernet Companion board-support targets built on the RAK4631 MCU platform. The MCU, bootloader, SoftDevice, and board package remain RAK4631 / nRF52840, but the hardware stack being supported is `RAK 4631 / RAK13800 + W5100S`.

## Production Target

- Target: `RAK_RAK13800_companion_radio_eth`
- Networking: DHCP first, or DHCP with static fallback
- TCP port: `4403`
- `ETH_DEBUG_LOGGING=0`
- `FORCE_CLIENT_REPEAT=0`
- `MAX_CONTACTS=128` unless RAM testing proves a higher value is safe

## Static Diagnostic Target

- Target: `RAK_RAK13800_companion_radio_eth_static_diag`
- IP: `10.245.94.47`
- Gateway: `10.245.94.33`
- DNS: `10.245.94.33`
- Subnet: `255.255.255.224`
- TCP port: `4403`
- `ETH_STATIC_ONLY=1`
- `ETH_DEBUG_LOGGING=1`

## Compatibility Aliases

The following names may remain temporarily for compatibility:

- `RAK_4631_companion_radio_eth_clean` -> `RAK_RAK13800_companion_radio_eth`
- `RAK_4631_companion_radio_eth_static_diag` -> `RAK_RAK13800_companion_radio_eth_static_diag`
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,32 @@ MeshCore provides the ability to create wireless mesh networks, similar to Mesht
- Flash the MeshCore firmware on a supported device.
- Connect with a supported client.

### RAK13800 Ethernet Companion Targets

- `RAK_RAK13800_companion_radio_eth` is the production board-support target.
- `RAK_RAK13800_companion_radio_eth_static_diag` is the static diagnostic target.
- The old `RAK_4631_companion_radio_eth_clean` and `RAK_4631_companion_radio_eth_static_diag` names remain compatibility aliases only.
- Static diagnostic settings:
- IP `10.245.94.47`
- Gateway `10.245.94.33`
- DNS `10.245.94.33`
- Subnet `255.255.255.224`
- TCP port `4403`
- `ETH_STATIC_ONLY=1`
- `ETH_DEBUG_LOGGING=1`
- Production settings:
- DHCP first or DHCP with static fallback
- TCP port `4403`
- `ETH_DEBUG_LOGGING=0`
- `FORCE_CLIENT_REPEAT=0`
- `MAX_CONTACTS=128` unless RAM testing proves a higher value is safe

For developers:

- Install [PlatformIO](https://docs.platformio.org) in [Visual Studio Code](https://code.visualstudio.com).
- Clone and open the MeshCore repository in Visual Studio Code.
- The RAK13800 Ethernet Companion board-support targets use the canonical PlatformIO env names `RAK_RAK13800_companion_radio_eth` and `RAK_RAK13800_companion_radio_eth_static_diag`.
- These targets extend the RAK4631 MCU platform, but the supported hardware stack is `RAK 4631 / RAK13800 + W5100S`.
- See the example applications you can modify and run:
- [Companion Radio](./examples/companion_radio) - For use with an external chat app, over BLE, USB or Wi-Fi.
- [KISS Modem](./examples/kiss_modem) - Serial KISS protocol bridge for host applications. ([protocol docs](./docs/kiss_modem_protocol.md))
Expand Down
30 changes: 30 additions & 0 deletions VALIDATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Validation for RAK13800 Ethernet Companion Targets

Validate the canonical targets:

- `RAK_RAK13800_companion_radio_eth`
- `RAK_RAK13800_companion_radio_eth_static_diag`

## What to Verify

- The target name is the RAK13800 board-support name, not a generic RAK4631 label.
- The build still extends the RAK4631 PlatformIO environment.
- The static diagnostic target keeps:
- IP `10.245.94.47`
- Gateway `10.245.94.33`
- DNS `10.245.94.33`
- Subnet `255.255.255.224`
- TCP port `4403`
- `ETH_STATIC_ONLY=1`
- `ETH_DEBUG_LOGGING=1`
- The production target uses:
- DHCP first or DHCP with static fallback
- TCP port `4403`
- `ETH_DEBUG_LOGGING=0`
- `FORCE_CLIENT_REPEAT=0`
- `MAX_CONTACTS=128` unless RAM testing proves a higher value is safe

## Compatibility Check

- Keep `RAK_4631_companion_radio_eth_clean` as an alias to `RAK_RAK13800_companion_radio_eth` if older scripts still use it.
- Keep `RAK_4631_companion_radio_eth_static_diag` as an alias to `RAK_RAK13800_companion_radio_eth_static_diag` if older scripts still use it.
12 changes: 6 additions & 6 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ Commands:
build-firmware <target>: Build the firmware for the given build target.
build-firmwares: Build all firmwares for all targets.
build-matching-firmwares <build-match-spec>: Build all firmwares for build targets containing the string given for <build-match-spec>.
build-companion-firmwares: Build all companion firmwares for all build targets.
build-companion-firmwares: Build all companion firmwares for all build targets, including RAK_RAK13800 board-support targets.
build-repeater-firmwares: Build all repeater firmwares for all build targets.
build-room-server-firmwares: Build all chat room server firmwares for all build targets.

Examples:
Build firmware for the "RAK_4631_repeater" device target
$ sh build.sh build-firmware RAK_4631_repeater
Build firmware for the "RAK_RAK13800_companion_radio_eth" device target
$ sh build.sh build-firmware RAK_RAK13800_companion_radio_eth

Build all firmwares for device targets containing the string "RAK_4631"
Build all firmwares for device targets containing the string "RAK_RAK13800"
$ sh build.sh build-matching-firmwares <build-match-spec>

Build all companion firmwares
Expand All @@ -42,11 +42,11 @@ Examples:
Build without debug logging:
$ export FIRMWARE_VERSION=v1.0.0
$ export DISABLE_DEBUG=1
$ sh build.sh build-firmware RAK_4631_repeater
$ sh build.sh build-firmware RAK_RAK13800_companion_radio_eth

Build with debug logging (default, uses flags from variant files):
$ export FIRMWARE_VERSION=v1.0.0
$ sh build.sh build-firmware RAK_4631_repeater
$ sh build.sh build-firmware RAK_RAK13800_companion_radio_eth_static_diag
EOF
}

Expand Down
59 changes: 58 additions & 1 deletion variants/rak4631/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,63 @@ lib_deps =
${rak4631.lib_deps}
densaugeo/base64 @ ~1.4.0

[env:RAK_RAK13800_companion_radio_eth]
extends = rak4631
board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
board_upload.maximum_size = 712704
build_flags =
${rak4631.build_flags}
-I examples/companion_radio/ui-new
-D PIN_USER_BTN=9
-D PIN_USER_BTN_ANA=31
-D DISPLAY_CLASS=SSD1306Display
-D MAX_CONTACTS=128
-D MAX_GROUP_CHANNELS=40
-D ETH_DEBUG_LOGGING=0
-D FORCE_CLIENT_REPEAT=0
-D ADVERT_NAME='"RAK4631 RAK13800 Eth"'
; -D MESH_PACKET_LOGGING=1
; -D MESH_DEBUG=1
build_src_filter = ${rak4631.build_src_filter}
+<helpers/nrf52/SerialBLEInterface.cpp>
+<../examples/companion_radio/*.cpp>
+<../examples/companion_radio/ui-new/*.cpp>
lib_deps =
${rak4631.lib_deps}
densaugeo/base64 @ ~1.4.0

[env:RAK_RAK13800_companion_radio_eth_static_diag]
extends = rak4631
board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
board_upload.maximum_size = 712704
build_flags =
${rak4631.build_flags}
-I examples/companion_radio/ui-new
-D PIN_USER_BTN=9
-D PIN_USER_BTN_ANA=31
-D DISPLAY_CLASS=SSD1306Display
-D MAX_CONTACTS=128
-D MAX_GROUP_CHANNELS=40
-D ETH_STATIC_ONLY=1
-D ETH_DEBUG_LOGGING=1
-D FORCE_CLIENT_REPEAT=0
-D ADVERT_NAME='"RAK4631 RAK13800 Eth Diag"'
; -D MESH_PACKET_LOGGING=1
; -D MESH_DEBUG=1
build_src_filter = ${rak4631.build_src_filter}
+<helpers/nrf52/SerialBLEInterface.cpp>
+<../examples/companion_radio/*.cpp>
+<../examples/companion_radio/ui-new/*.cpp>
lib_deps =
${rak4631.lib_deps}
densaugeo/base64 @ ~1.4.0

[env:RAK_4631_companion_radio_eth_clean]
extends = RAK_RAK13800_companion_radio_eth

[env:RAK_4631_companion_radio_eth_static_diag]
extends = RAK_RAK13800_companion_radio_eth_static_diag

[env:RAK_4631_terminal_chat]
extends = rak4631
build_flags =
Expand Down Expand Up @@ -199,4 +256,4 @@ build_flags =
build_src_filter = ${rak4631.build_src_filter}
+<../examples/kiss_modem/>
lib_deps =
${rak4631.lib_deps}
${rak4631.lib_deps}