Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

Wi-Fi Combo Forum Discussions

srpec_3628341
Level 2
Level 2
First like received

Hi ,

    The wl commands passed to wl43909B0.exe,is going directly to board cw43438 over UART,OR the command is passed to some driver ,which passes it further to the board.

#################################################

import sys, string , os ,argparse

parser = argparse.ArgumentParser()

parser.add_argument("-l","--location",help="C:/Users/99000230/Documents/WICED-Studio-6.1/43xxx_Wi-Fi/libraries/test/wl_tool")

parser.add_argument("-c","--commands",help="C:/Users/99000230/Desktop/example_commands.txt")

parser.add_argument("-p","--COM4",help="com port Number")

args = parser.parse_args()

if args.location and args.port and args.commands:

   print("Running wl utility at " + args.location)

   type(args.location)

  clist = []

  file = open(args.commands, 'r')

   for line in file:

  clist.append(line.strip('\n'))

  os.chdir(args.location)

   #add your list of commands here inside

   for i in range(0,len(clist)):

  os.system(args.location + "wl43909B0.exe --serial " + args.port + " " + clist)

else:

   print("incorrect usage, type -h for help")

################################################################

I tried above script but its not communicating .

0 Likes
1 Solution
VinayakS_26
Moderator
Moderator
Moderator
100 likes received 50 likes received 25 likes received

Hi,


As rroy has rightly said, the wl utility communicates with the board over the UART interface. The python script make use of the wl utility to send the sequence of wl commands over.

Also the following line was present in the code that is pasted in the query.

"

parser.add_argument("-p","--COM4",help="com port Number")

"

the "-COM4" for the parser would throw an unknown attribute error. Do change it to 'port' as the later line use that tag for parsing the input argument.

Use the following code script to avoid any misunderstanding of the wl tool, that needs to be used for cyw.43438.

also give the full path along with the name of the wl tool as well while giving the location(-l flag).

import sys, string , os ,argparse

parser = argparse.ArgumentParser()

parser.add_argument("-l","--location",help="absolute path to your wl utility,(note the slash) eg:<location>/43xxx_Wi-Fi/libraries/test/wl_tool/wl43438A1.exe")

parser.add_argument("-c","--commands",help="location of the commands file, note the slash eg: C:/home/test/test_command.txt")

parser.add_argument("-p","--COM4",help="com port Number")

args = parser.parse_args()

if args.location and args.port and args.commands:

    print("Running wl utility at " + args.location)

    type(args.location)

    clist = []

    file = open(args.commands, 'r')

    for line in file:

        clist.append(line.strip('\n'))

    #os.chdir(args.location)

    #add your list of commands here inside

  

    for i in range(0,len(clist)):

        os.system(args.location + " --serial " + args.port + " " + clist)

else:

    print("incorrect usage, type -h for help")

Regards,

-Vinayak

View solution in original post

4 Replies
AxLi_1746341
Level 7
Level 7
10 comments on KBA 5 comments on KBA First comment on KBA

Are you sure wl43909B0.exe is for cyw43438?

Check if wl43438A1.exe works.

Hi,

The wl commands passed to wl tool using the python script(captured in the query) is communicating directly to board cyw43438 over UART or the command is passed to some intermediate driver ,which passes it further to the board over UART?

Regards

Srikrishna

0 Likes

axel.lin_1746341​, you are correct. For 4343x based platforms, the wl tool exe running in windows host PC should be updated to wl43438A1.exe.

os.system(args.location + "wl43438A1.exe --serial " + args.port + " " + clist)

srikrishna.pelluru_ext_3628341​, The manufacturing test application running on the DUT interacts via a serial communication interface with the Cypress wireless LAN manufacturing test utility running on a Windows PC. The wl utility is provided with the WICED Manufacturing Test SDK and is in the <WICED-SDK>\libraries\test\wl_tool\wl_<chip_name>.exe subdirectory. If you check the mfg_test_init.c as located in  43xxx_Wi-Fi/apps/test/mfg_test/, you can find that a wlu serial server is started over the UART interface. Hope that helps you out with your query!

VinayakS_26
Moderator
Moderator
Moderator
100 likes received 50 likes received 25 likes received

Hi,


As rroy has rightly said, the wl utility communicates with the board over the UART interface. The python script make use of the wl utility to send the sequence of wl commands over.

Also the following line was present in the code that is pasted in the query.

"

parser.add_argument("-p","--COM4",help="com port Number")

"

the "-COM4" for the parser would throw an unknown attribute error. Do change it to 'port' as the later line use that tag for parsing the input argument.

Use the following code script to avoid any misunderstanding of the wl tool, that needs to be used for cyw.43438.

also give the full path along with the name of the wl tool as well while giving the location(-l flag).

import sys, string , os ,argparse

parser = argparse.ArgumentParser()

parser.add_argument("-l","--location",help="absolute path to your wl utility,(note the slash) eg:<location>/43xxx_Wi-Fi/libraries/test/wl_tool/wl43438A1.exe")

parser.add_argument("-c","--commands",help="location of the commands file, note the slash eg: C:/home/test/test_command.txt")

parser.add_argument("-p","--COM4",help="com port Number")

args = parser.parse_args()

if args.location and args.port and args.commands:

    print("Running wl utility at " + args.location)

    type(args.location)

    clist = []

    file = open(args.commands, 'r')

    for line in file:

        clist.append(line.strip('\n'))

    #os.chdir(args.location)

    #add your list of commands here inside

  

    for i in range(0,len(clist)):

        os.system(args.location + " --serial " + args.port + " " + clist)

else:

    print("incorrect usage, type -h for help")

Regards,

-Vinayak