Trying to iperf host and a client (station) with the following code, while the iperf does not work. Anyone?
import sys
from mininet.log import setLogLevel, info from mn_wifi.net import Mininet_wifi
def topology(args):
net = Mininet_wifi()
info("*** Creating nodes\n")
ap1 = net.addAccessPoint('ap1', ssid='new-ssid', mode='g', channel='1', failMode="standalone", mac='00:00:00:00:00:01', position='50,50,0')
net.addStation('sta1', mac='00:00:00:00:00:02', ip='10.0.0.1/8', position='30,60,0')
h1 = net.addHost('h1', ip='10.0.0.3/8')
info("*** Configuring propagation model\n")
net.setPropagationModel(model="logDistance", exp=4.5)
info("*** Configuring wifi nodes\n")
net.configureWifiNodes()
info("*** Creating links\n")
net.addLink(ap1, h1)
info("*** Starting network\n")
net.build()
ap1.start([])
net.iperf(hosts = [ ap1, h1 ], l4Type='TCP', udpBw='10M', fmt=None, seconds=2, port=800)
info("*** Stopping network\n")
net.stop()
topology(sys.argv)
The result is as follows: sudo python examples/_position.py *** Creating nodes *** Configuring propagation model *** Configuring wifi nodes *** Creating links *** Starting network *** Iperf: testing TCP bandwidth between ap1 and h1 => which never goes off