From 78b8578a0668e8b0b016456f491d9d3e8a92e09e Mon Sep 17 00:00:00 2001 From: Tim Wilkinson Date: Thu, 19 Jan 2023 11:11:30 -0800 Subject: [PATCH] Automatically enable RTS when hidden nodes detected (#659) --- files/etc/uci-defaults/80_aredn_lqm | 2 +- files/usr/local/bin/mgr/lqm.lua | 2 +- files/www/cgi-bin/advancedconfig | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/files/etc/uci-defaults/80_aredn_lqm b/files/etc/uci-defaults/80_aredn_lqm index ce430b24..4904986b 100755 --- a/files/etc/uci-defaults/80_aredn_lqm +++ b/files/etc/uci-defaults/80_aredn_lqm @@ -7,7 +7,7 @@ do option enable '0' option min_snr '15' option margin_snr '1' - option rts_theshold '-1' + option rts_theshold '1' option min_distance '0' option max_distance '80467' option min_quality '50' diff --git a/files/usr/local/bin/mgr/lqm.lua b/files/usr/local/bin/mgr/lqm.lua index 8ac12f9d..cd43c60b 100755 --- a/files/usr/local/bin/mgr/lqm.lua +++ b/files/usr/local/bin/mgr/lqm.lua @@ -59,7 +59,7 @@ function get_config() return { margin = tonumber(c:get("aredn", "@lqm[0]", "margin_snr")), low = tonumber(c:get("aredn", "@lqm[0]", "min_snr")), - rts_theshold = tonumber(c:get("aredn", "@lqm[0]", "rts_theshold") or "-1"), + rts_theshold = tonumber(c:get("aredn", "@lqm[0]", "rts_theshold") or "1"), min_distance = tonumber(c:get("aredn", "@lqm[0]", "min_distance")), max_distance = tonumber(c:get("aredn", "@lqm[0]", "max_distance")), auto_distance = tonumber(c:get("aredn", "@lqm[0]", "auto_distance") or "0"), diff --git a/files/www/cgi-bin/advancedconfig b/files/www/cgi-bin/advancedconfig index bb177b94..6f93435c 100755 --- a/files/www/cgi-bin/advancedconfig +++ b/files/www/cgi-bin/advancedconfig @@ -132,7 +132,7 @@ local settings = { key = "aredn.@lqm[0].rts_theshold", type = "string", desc = "RTS Threshold in bytes before using RTS/CTS when hidden nodes are detected

aredn.@lqm[0].rts_theshold", - default = "-1", + default = "1", condition = "lqm_enabled()" }, {