diff --git a/modules/luci-base/htdocs/luci-static/resources/network.js b/modules/luci-base/htdocs/luci-static/resources/network.js index 8acf74c45503..93a9fdd9724f 100644 --- a/modules/luci-base/htdocs/luci-static/resources/network.js +++ b/modules/luci-base/htdocs/luci-static/resources/network.js @@ -3396,6 +3396,11 @@ WifiDevice = baseclass.extend(/** @lends LuCI.network.WifiDevice.prototype */ { * - `HE40` - applicable to IEEE 802.11ax, 40 MHz wide channels * - `HE80` - applicable to IEEE 802.11ax, 80 MHz wide channels * - `HE160` - applicable to IEEE 802.11ax, 160 MHz wide channels + * - `EHT20` - applicable to IEEE 802.11be, 20 MHz wide channels + * - `EHT40` - applicable to IEEE 802.11be, 40 MHz wide channels + * - `EHT80` - applicable to IEEE 802.11be, 80 MHz wide channels + * - `EHT160` - applicable to IEEE 802.11be, 160 MHz wide channels + * - `EHT320` - applicable to IEEE 802.11be, 320 MHz wide channels */ getHTModes: function() { var htmodes = this.ubus('dev', 'iwinfo', 'htmodes'); diff --git a/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm b/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm index eeb1d5c5cbc7..610f79ad20a5 100644 --- a/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm +++ b/modules/luci-compat/luasrc/view/cbi/wireless_modefreq.htm @@ -29,7 +29,9 @@ var modes = [ '', 'Legacy', true, 'n', 'N', hwmodes.n, - 'ac', 'AC', hwmodes.ac + 'ac', 'AC', hwmodes.ac, + 'ax', 'AX', hwmodes.ax, + 'be', 'BE', hwmodes.be ]; var htmodes = { @@ -45,6 +47,19 @@ 'VHT40', '40 MHz', htmodes.VHT40, 'VHT80', '80 MHz', htmodes.VHT80, 'VHT160', '160 MHz', htmodes.VHT160 + ], + 'ax': [ + 'HE20', '20 MHz', htmodes.HE20, + 'HE40', '40 MHz', htmodes.HET40, + 'HE80', '80 MHz', htmodes.HE80, + 'HE160', '160 MHz', htmodes.HE160 + ], + 'be': [ + 'EHT20', '20 MHz', htmodes.EHT20, + 'EHT40', '40 MHz', htmodes.EHT40, + 'EHT80', '80 MHz', htmodes.EHT80, + 'EHT160', '160 MHz', htmodes.EHT160, + 'EHT320', '320 MHz', htmodes.EHT320 ] }; @@ -59,6 +74,12 @@ ], 'ac': [ '11a', '5 GHz', true + ], + 'ax': [ + '11a', '5 GHz', true + ], + 'be': [ + '11a', '6 GHz', true ] }; @@ -128,8 +149,12 @@ var bwdt = document.getElementById(id + '.htmode'); cbi_set_values(mode, modes); - - if (/VHT20|VHT40|VHT80|VHT160/.test(<%= luci.http.write_json(self.map:get(section, "htmode")) %>)) + + if (/EHT20|EHT40|HE80|EHT160|EHT320/.test(<%= luci.http.write_json(self.map:get(section, "htmode")) %>)) + mode.value = 'be'; + else if (/HE20|HE40|HE80|HE160/.test(<%= luci.http.write_json(self.map:get(section, "htmode")) %>)) + mode.value = 'ax'; + else if (/VHT20|VHT40|VHT80|VHT160/.test(<%= luci.http.write_json(self.map:get(section, "htmode")) %>)) mode.value = 'ac'; else if (/HT20|HT40/.test(<%= luci.http.write_json(self.map:get(section, "htmode")) %>)) mode.value = 'n'; diff --git a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js index 66a13331443e..1719945f108d 100644 --- a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js +++ b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/wireless.js @@ -364,6 +364,8 @@ var CBIWifiFrequencyValue = form.Value.extend({ 'HE160', '160 MHz', htmodelist.HE160 ], 'be': [ + 'EHT20', '20 MHz', htmodelist.EHT20, + 'EHT40', '40 MHz', htmodelist.EHT40, 'EHT80', '80 MHz', htmodelist.EHT80, 'EHT160', '160 MHz', htmodelist.EHT160, 'EHT320', '320 MHz', htmodelist.EHT320 @@ -390,7 +392,7 @@ var CBIWifiFrequencyValue = form.Value.extend({ '6g', '6 GHz', this.channels['6g'].length > 3 ], 'be': [ - '6g', '6 GHz', this.channels['6g'].length > 3 + '6g', '6 GHz', this.channels['6g'].length > 3, ], }; }, this)); @@ -455,8 +457,8 @@ var CBIWifiFrequencyValue = form.Value.extend({ this.setValues(mode, this.modes); - if (/EHT80|EHT160|EHT320/.test(htval)) - mode.value = 'be'; + if (/EHT20|EHT40|EHT80|EHT160|EHT320/.test(htval)) + mode.value = 'be'; else if (/HE20|HE40|HE80|HE160/.test(htval)) mode.value = 'ax'; else if (/VHT20|VHT40|VHT80|VHT160/.test(htval)) @@ -472,11 +474,11 @@ var CBIWifiFrequencyValue = form.Value.extend({ this.useBandOption = false; if (mode.value = 'be') - band.value = '6g'; + band.value = '6g'; else if (/a/.test(hwval)) - band.value = '5g'; - else - band.value = '2g'; + band.value = '5g'; + else + band.value = '2g'; } else { this.useBandOption = true; @@ -2360,4 +2362,4 @@ return view.extend({ }, handleReset: null -}); \ No newline at end of file +});