wif_ctl_9800_3504.py : add ap_dot11_dot11ax_mcs_tx_index_spatial_stream no_ap_dot11_dot11ax_mcs_tx_index_spatial_stream

lf_tx_power.py : added comments about spatial stream commands

Signed-off-by: Chuck SmileyRekiere <chuck.smileyrekiere@candelatech.com>
This commit is contained in:
Chuck SmileyRekiere
2022-04-15 12:51:51 -06:00
committed by shivam
parent 239afba55e
commit 1fed5f423c
2 changed files with 58 additions and 8 deletions

View File

@@ -251,6 +251,13 @@ Show the tx_power for a specific station:
iw dev <station> station dump
iw dev sta0000 station dump
#####################################################################
5g dual band restrictions
#####################################################################
when both 5g (slot 1) is enabled and dual-band 5g (slot 2) is enabled .
5g slot 1 will used the 5g channels to 64, the 5g dual-band will use channels 100 -> 165.
When 5g (slot 1) and dual-band 6g (slot 2) is enabled then 5g (slot 1) has all ba
'''
if sys.version_info[0] != 3:

View File

@@ -159,6 +159,9 @@ def main():
# parser.add_argument("--tag_policy", type=str, help="--tag_policy default-tag-policy", default="RM204-TB2")
parser.add_argument("--policy_profile", type=str, help="--policy_profile default-policy-profile")
# parser.add_argument("--wlan_name", type=str, help="--wlan_name open-wlan", default="open-wlan")
parser.add_argument("--spatial_stream", help="--spatial_stream 1 , 2, 3, or 4 , configure controller for specific number of spatial streams")
parser.add_argument("--mcs_tx_index", help="--mcs_tx_index 7, 9 or 11 to , configure controller for specific number of spatial streams")
parser.add_argument("--action", type=str, help="perform action",
choices=["config", "dtim", "debug_disable_all", "no_logging_console", "line_console_0", "country", "ap_country",
@@ -1114,6 +1117,46 @@ def main():
if (args.action == "country"):
command = "config country %s" % (args.value)
if (args.action == "ap_dot11_dot11ax_mcs_tx_index_spatial_stream" and (args.spatial_stream is None or args.mcs_tx_index is None)):
raise Exception("action requires spatial_stream and mcs_tx_index to be set: {action}".format(action=action))
if (args.action == "ap_dot11_dot11ax_mcs_tx_index_spatial_stream"):
if args.series == "9800":
if (args.band == '6g' or args.band == 'dual_band_6g'):
command = "ap dot11 6ghz dot11ax mcs tx index {index} spatial-stream {stream}".format(index=args.mcs_tx_index,stream=args.spatial_stream)
elif (args.band == '5g' or args.band == 'dual_band_5g'):
command = "ap dot11 5ghz dot11ax mcs tx index {index} spatial-stream {stream}".format(index=args.mcs_tx_index,stream=args.spatial_stream)
elif (args.band == '24g'):
command = "ap dot11 24ghz dot11ax mcs tx index {index} spatial-stream {stream}".format(index=args.mcs_tx_index,stream=args.spatial_stream)
egg.sendline("config t")
sleep(0.1)
i = egg.expect_exact(["(config)#", pexpect.TIMEOUT], timeout=timeout)
if i == 0:
egg.sendline(command)
sleep(0.1)
if i == 1:
logg.info("timed out on (config)# command: {command}".format(command=command))
if (args.action == "no_ap_dot11_dot11ax_mcs_tx_index_spatial_stream" and (args.spatial_stream is None or args.mcs_tx_index is None)):
raise Exception("action requires spatial_stream and mcs_tx_index to be set: {action}".format(action=action))
if (args.action == "no_ap_dot11_dot11ax_mcs_tx_index_spatial_stream"):
if args.series == "9800":
if (args.band == '6g' or args.band == 'dual_band_6g'):
command = "no ap dot11 6ghz dot11ax mcs tx index {index} spatial-stream {stream}".format(index=args.mcs_tx_index,stream=args.spatial_stream)
elif (args.band == '5g' or args.band == 'dual_band_5g'):
command = "no ap dot11 5ghz dot11ax mcs tx index {index} spatial-stream {stream}".format(index=args.mcs_tx_index,stream=args.spatial_stream)
elif (args.band == '24g'):
command = "no ap dot11 24ghz dot11ax mcs tx index {index} spatial-stream {stream}".format(index=args.mcs_tx_index,stream=args.spatial_stream)
egg.sendline("config t")
sleep(0.1)
i = egg.expect_exact(["(config)#", pexpect.TIMEOUT], timeout=timeout)
if i == 0:
egg.sendline(command)
sleep(0.1)
if i == 1:
logg.info("timed out on (config)# command: {command}".format(command=command))
if (args.action == "manual" and args.ap is None):
raise Exception("action requires AP name")
if (args.action == "manual"):