Path Hash Modes (MeshCore)
Path Hash Modes (MeshCore)
Path hash modes control how repeaters identify themselves in routing path headers within MeshCore packets. This feature is available in recent MeshCore firmware versions. Check your firmware release notes for version-specific availability.
Mode Comparison
| Mode | Bytes per Hop | Max Hops | Unique IDs | CLI Setting |
|---|---|---|---|---|
| 1-byte | 1 | 64 | 256 | set path.hash.mode 0 |
| 2-byte | 2 | 32 | 65,536 | set path.hash.mode 1 |
| 3-byte | 3 | 21 | 16,777,216 | set path.hash.mode 2 |
Mode 0 (1-byte) is the default.
Recommendation
Use 2-byte mode (set path.hash.mode 1) for most North American community meshes (a common community recommendation, e.g. NodakMesh).
- 1-byte mode provides 256 possible hash IDs. By the birthday paradox the chance of a collision reaches ~50% at only about 19 repeaters in range (well below 256), so with more than ~30 repeaters in range hash collisions become likely, causing routing errors and ambiguous path attribution.
- 2-byte mode provides 65,536 possible hash IDs, making collisions vanishingly unlikely for any realistic community mesh while keeping per-hop overhead to 2 bytes.
- 3-byte mode is future-proof but reduces maximum hop count to 21, which may be limiting in networks with long routing chains.
Mixing path hash modes within a single mesh requires all in-path repeaters to be running firmware ≥ 1.14. On networks where some repeaters run older firmware, keep every device on the same (default) mode.
Configuration Steps
- Connect to the repeater via USB serial (115200 baud) or Bluetooth
- Set the desired mode:
set path.hash.mode 1 - Broadcast updated hash to the network:
advert
App Access
In recent companion-app versions (around v1.41.0+; check current release notes, as the menu location may change between versions), path hash mode can also be adjusted under:
Settings → Experimental Settings
Note that "Experimental Settings" must be enabled in the app before this option appears.
Network-Wide Consistency
All repeaters and nodes on the same network segment do not need to use the same path hash mode - mode is a per-device setting affecting how that device encodes its own ID in path headers. However, for consistent diagnostics and network analysis, aligning all devices to the same mode simplifies troubleshooting, and mixing modes requires all in-path repeaters to be on firmware ≥ 1.14 (see above).
No comments to display
No comments to display