tests: Make hostapd test setup more similar to the P2P tests

Signed-hostap: Jouni Malinen <j@w1.fi>
This commit is contained in:
Jouni Malinen 2013-03-31 16:19:12 +03:00
parent ae3ad3284a
commit 0b20f514de
2 changed files with 5 additions and 3 deletions

View file

@ -41,10 +41,11 @@ def main():
dev0 = WpaSupplicant('wlan0')
dev1 = WpaSupplicant('wlan1')
dev = [ dev0, dev1 ]
dev2 = WpaSupplicant('wlan2')
dev = [ dev0, dev1, dev2 ]
apdev = [ ]
apdev.append({"ifname": 'wlan2', "bssid": "02:00:00:00:02:00"})
apdev.append({"ifname": 'wlan3', "bssid": "02:00:00:00:03:00"})
apdev.append({"ifname": 'wlan4', "bssid": "02:00:00:00:04:00"})
for d in dev:
if not d.ping():

View file

@ -6,12 +6,13 @@ HAPD=$DIR/../../hostapd/hostapd
WLANTEST=$DIR/../../wlantest/wlantest
$DIR/stop-wifi.sh
sudo modprobe mac80211_hwsim radios=4
sudo modprobe mac80211_hwsim radios=5
mkdir -p $DIR/logs
DATE=`date +%s`
sudo ifconfig hwsim0 up
sudo $WLANTEST -i hwsim0 -c -d > $DIR/logs/$DATE-hwsim0 &
sudo $WPAS -Dnl80211 -iwlan0 -c $DIR/p2p0.conf -ddKt > $DIR/logs/$DATE-log0 &
sudo $WPAS -Dnl80211 -iwlan1 -c $DIR/p2p1.conf -ddKt > $DIR/logs/$DATE-log1 &
sudo $WPAS -Dnl80211 -iwlan2 -c $DIR/p2p2.conf -ddKt > $DIR/logs/$DATE-log2 &
sudo $HAPD -ddKt -g $DIR/hostapd-global -G admin -ddKt > $DIR/logs/$DATE-hostapd &
sleep 1