-
Notifications
You must be signed in to change notification settings - Fork 64
/
Copy pathINSTALL
152 lines (118 loc) · 6.73 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
#
# Copyright (c) 2015 Wi-Fi Alliance
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
# SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
# RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE
# USE OR PERFORMANCE OF THIS SOFTWARE.
#
#
# WFA Test Engine Source Code (DUT and Control PC) Revision 2.41 (April 4, 08)
This source code package contains a sample Linux implementation of the DUT code for
the Wi-Fi Test Engine. This DUT code includes the Wi-Fi Traffic Generator.
The DUT code is written to be portable to other platforms.
Also included here is Linux source code for the Control PC component of the Wi-Fi Test Engine.
The sample code uses TCP over USB to provide connectivity between the DUT and the Control PC.
This code will need to be modified to support alternate connectivity methods.
The third component included is called the Test Console. This component is a peer traffic
Generator to the DUT's traffic generator that can run on the Control PC.
The following instructions pertain to the direct use of this sample code in a Linux environment.
************************************************ IMPORTANT****************************************************
Before building the software, if you plan to support WPA2 as default, you can
simply go to the step 1 "Building the software".
If the DUT is preparing for WMM support, the lines in the file "Makefile.inc"
for WMM is needed to be uncommented and the default setting for WPA2 should
be commented out as well.
For WMM-PS, make sure to uncomment the line to build WMM-PS and comment out
original build-line.
To support Voice, the build in the Makefile.inc must include WFA_WMM_EXT and
WFA_WMM_VOICE.
1. Building the software
a. build all
Simply type "make all".
b. build individual modules
cd into the appropriate directory to edit and type "make".
c. build a specific agent
There are three agents in this package: "dut", "ca" and "tc",
standing for "Device Under Test", "Control Agent" and "Test Console"
respectively.
To build one agent only, edit the file "Makefile.inc" to
comment out the other modules.
d. clean modules and object files
Type "make clean" or cd into the module directories and enter
type "make clean"
2. Installing the software
a. Copy dut/wfa_dut to /usr/sbin (or other location) on the
Linux DUT.
b. MUST copy scripts/getipconfig.sh to /usr/local/sbin on the Linux DUT.
3. Running the software
3.1 DUT -- dut/wfa_dut
a. The current implementation is based on the open source wpa_supplicant
(hostap.epitest.fi/wpa_supplicant). The DUT must have this installed.
b. The supplicant may be either auto started during the system boot or
manually started by typing "wpa_supplicant -Dmadwifi -iath0 -c "any
configuration file". Before doing this, you need to have a console
terminal to access/login the DUT.
Please refer the wpa_supplicant Docs/README, URL: https://w1.fi/cgit/hostap/plain/wpa_supplicant/README
and Linux setup document for setting auto-start.
c. The IP address for the control link interface (can be USB, ethernet, or
others with TCP/IP/aLink) needs to be set, e.g. 10.10.1.100 . This should be set for a different
subnet from the traffic agent interface (Wi-Fi interface).
d. Once you have already logged in the DUT, type:
wfa_dut <control link interface, etc usb0> <local tcp port, e.g. 8000>
3.2 Control Agent (LINUX PC) -- ca/wfa_ca
a. Before starting the control agent, first set
the IP address for the control link interface (e.g. 10.10.1.110) to
match the subnet set in the DUT. Second, set the two
environment variables. Type:
a.1: export WFA_ENV_AGENT_IPADDR=<IP address of the DUT's control
interface, e.g. 10.10.1.100>
a.2: export WFA_ENV_AGENT_PORT=<Port number of the DUT control TCP sits
on, e.g. 8000>
b. Start the control agent:
wfa_ca <local ethernet interface to communicate to others such as Test
Manager, CLI commander or Console with Python scripts e.g eth0>
<local port to listen on, e.g. 9000>
3.4 Console using Python Scripts.
Read the instructions in the directory "ucc" for how to setup python if
it is not installed on your PC. It also has instructions for the script
file modification.
3.7 Test Console with Python Script
see 3.4
3.8 Running WMM-Power Save (optional)
Before running WMM-Power Save, some necessary setup commands must be executed,
such as set security, association and configure IP address, etc.
a. sta_set_uapsd,interface,<wlan i/f, e.g. ath0>,ssid,<a test ssid>,acBE,<0 or 1>acBK,<0 or 1>,acVO,<0 or 1>,acVI,<0 or 1>
Note: the AC value need to follow the test plan definition.
b. traffic_agent_config,profile,uapsd,direction,receive,source<ip address of the console>,sourceport 12345,destinationport,12345
c. traffic_agent_receive_start,streamid,<the streamid returned from the step "b"
traffic_agent_receive_stop,streamid,<the streamid used for testing from the step "b"
For details, please refer the WMM-Power Save Techops Manual and Test Plan
as well as the WMM-PS specification.
4. Debug Command
There is a CLI command implemented to enable debug output. The debug levels
include
a. ERROR -- Default and not Changeable (level 1)
b. INFO -- Can be turned on/off (level 2)
c. WARNING -- Can be turned on/off (level 4)
sta_debug_set,level,2,enable,1
will enable to debug INFO
sta_debug_set,level,2,enable,0
will disable it.
5.To enable the CLI handling using shell scripts
1) copy the wfa_cli.txt to /etc/WfaEndpoint folder.
2) modify the wfa_cli.txt to include the CLI's that are handled by shell script.
- The format is <shell script>-<ResultFlag>
- The ResultFlag can be either TRUE or FALSE.
TRUE represents that there is some return string which should be sent to UCC
FALSE represents that there is no retrun string to send UCC
EX: wfa_test_cli-TRUE,
3) keep the named shell script ( should match with CLI defined in wfa_cli.txt) in /usr/bin or /usr/sbin so that the system can call.
For questions, send emails to [email protected]