Skip to content

Commit d4febe7

Browse files
committed
Add flood retry controls
1 parent 674beb0 commit d4febe7

12 files changed

Lines changed: 1204 additions & 20 deletions

File tree

docs/cli_commands.md

Lines changed: 87 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -585,7 +585,7 @@ This document provides an overview of CLI commands that can be sent to MeshCore
585585
- `rooftop` (`1`): `175 ms` base wait, `15` retries, `100 ms` added per retry, SNR gate is SF floor + `5 dB`
586586
- `mobile` (`2`): `175 ms` base wait, `15` retries, `50 ms` added per retry, SNR gate is the SF floor
587587

588-
**Note:** Selecting a preset copies those values into the retry settings. You can refine `direct.retry.margin`, `direct.retry.count`, `direct.retry.base`, or `direct.retry.step` afterward. Retry delay is `direct.txdelay` jitter + base wait + packet-length airtime wait + per-attempt step.
588+
**Note:** Selecting a preset copies those values into the direct retry settings and also resets flood retry defaults. You can refine `direct.retry.margin`, `direct.retry.count`, `direct.retry.base`, `direct.retry.step`, `flood.retry.count`, or `flood.retry.path` afterward. Retry delay is `direct.txdelay` jitter + base wait + packet-length airtime wait + per-attempt step.
589589

590590
---
591591

@@ -754,6 +754,92 @@ This document provides an overview of CLI commands that can be sent to MeshCore
754754

755755
---
756756

757+
#### View or change the flood retry preset
758+
**Usage:**
759+
- `get flood.retry.preset`
760+
- `set flood.retry.preset <value>`
761+
762+
**Parameters:**
763+
- `value`: `infra`|`rooftop`|`mobile` or `0`|`1`|`2`
764+
765+
**Presets:**
766+
- `infra` (`0`): `1` retry, path gate `1`
767+
- `rooftop` (`1`): `3` retries, path gate `2`
768+
- `mobile` (`2`): `3` retries, path gate `1`
769+
770+
**Note:** This applies only the flood retry defaults. `set direct.retry.preset` also resets these flood retry defaults.
771+
772+
---
773+
774+
#### View or change the number of flood retry attempts
775+
**Usage:**
776+
- `get flood.retry.count`
777+
- `set flood.retry.count <value>`
778+
779+
**Parameters:**
780+
- `value`: Maximum retry attempts after initial flood TX (`0`-`3`)
781+
782+
**Default:** `3` for `rooftop` and `mobile`, `1` for `infra`
783+
784+
**Note:** `0` disables flood retry.
785+
786+
---
787+
788+
#### View or change the flood retry path gate
789+
**Usage:**
790+
- `get flood.retry.path`
791+
- `set flood.retry.path <value>`
792+
793+
**Parameters:**
794+
- `value`: Maximum flood path length eligible for retry (`0`-`63`), or `off` to disable the gate
795+
796+
**Default:** `2` for `rooftop`, `1` for `infra` and `mobile`
797+
798+
---
799+
800+
#### View or change flood retry target prefixes
801+
**Usage:**
802+
- `get flood.retry.prefixes`
803+
- `set flood.retry.prefixes <prefixes>`
804+
805+
**Parameters:**
806+
- `prefixes`: Comma-separated 3-byte hex prefixes, such as `A1B2C3,D4E5F6`; use `none` or `off` to clear
807+
808+
**Default:** `none`
809+
810+
**Note:** Prefixes are stored as 3 bytes. Flood retry skips packets whose path already contains a matching target prefix. When prefixes are configured, only a downstream echo from one of those target prefixes cancels a queued retry; when no prefixes are configured, any downstream echo cancels it. Matching works with 3-byte, 2-byte, or 1-byte flood paths by comparing the matching leading bytes.
811+
812+
---
813+
814+
#### View or change flood retry bridge mode
815+
**Usage:**
816+
- `get flood.retry.bridge`
817+
- `set flood.retry.bridge <state>`
818+
819+
**Parameters:**
820+
- `state`: `on` or `off`
821+
822+
**Default:** `off`
823+
824+
**Note:** Bridge mode uses bucket definitions instead of the single `flood.retry.prefixes` target list. If a flood comes from one fresh bucket, retry continues until every other fresh configured bucket has been heard or `flood.retry.count` is exhausted.
825+
826+
---
827+
828+
#### View or change flood retry bridge buckets
829+
**Usage:**
830+
- `get flood.retry.bucket.<bucket>`
831+
- `set flood.retry.bucket <bucket> <prefixes>`
832+
833+
**Parameters:**
834+
- `bucket`: Bucket number (`1`-`6`)
835+
- `prefixes`: Up to 8 comma-separated 3-byte hex prefixes, such as `AABBCC,223344`; use `none` or `off` to clear
836+
837+
**Default:** all buckets empty
838+
839+
**Note:** Prefixes are stored as 3 bytes but match 3-byte, 2-byte, and 1-byte flood paths by comparing leading bytes. Bucket prefixes are included in bridge retry logic only if they were heard in the recent repeater table within the last hour.
840+
841+
---
842+
757843
### ACL
758844

759845
#### Add, update or remove permissions for a companion

0 commit comments

Comments
 (0)