wiki:802.11/wlan_exp

Version 12 (modified by welsh, 10 years ago) (diff)

--

802.11 Reference Design: Experiments Framework

The 802.11 Reference Design implements a framework for running experiments with multiple nodes. This framework enables low-level visibility and control of MAC and PHY behaviors in real-time. The experiment framework is called wlan_exp.

Migrating from WLAN_EXP from v0.9.3 to v0.9.5

As part of the updates from v0.9.3 to v0.9.5 of the experiments framework, we replaced the host configuration with a network configuration. The network configuration describes the network that wlan_exp will use to communicate with a subset of nodes. This allows for greater flexibility in dividing nodes between separate IP subnets while being attached to the same physical ethernet switch. To update scripts to use v0.9.5 network configuration, the following changes are required:

  1. HOST_INTERFACES = ['10.0.0.250'] becomes NETWORK = '10.0.0.0' (ie instead of describing the host IP address, you specify the network (ie X.Y.Z.0) the nodes are on.
  2. Change the initialization of the configuration objects:
    # Create an object that describes the configuration of the host PC
    host_config  = wlan_exp_config.WlanExpHostConfiguration(host_interfaces=HOST_INTERFACES)
    
    # Create an object that describes the WARP v3 nodes that will be used in this experiment
    nodes_config = wlan_exp_config.WlanExpNodesConfiguration(host_config=host_config,
                                                             serial_numbers=NODE_SERIAL_LIST)
    
    
    Changes to:
    
    
    # Create an object that describes the configuration of the host PC
    network_config = wlan_exp_config.WlanExpNetworkConfiguration(network=NETWORK)
    
    # Create an object that describes the WARP v3 nodes that will be used in this experiment
    nodes_config   = wlan_exp_config.WlanExpNodesConfiguration(network_config=network_config,
                                                               serial_numbers=NODE_SERIAL_LIST)
    
  3. Change any uses of the host configuration to the network configuration:
    # Initialize the Nodes
    #  This command will fail if either WARP v3 node does not respond
    nodes = wlan_exp_util.init_nodes(nodes_config, host_config)
    
    # Set the time of all the nodes to zero
    wlan_exp_util.broadcast_cmd_set_time(0.0, host_config)
    
    
    Changes to:
    
    
    # Initialize the Nodes
    #  This command will fail if either WARP v3 node does not respond
    nodes = wlan_exp_util.init_nodes(nodes_config, network_config)
    
    # Set the time of all the nodes to zero
    wlan_exp_util.broadcast_cmd_set_time(0.0, network_config)
    

One other change that requires updates to existing scripts involves the LTG framework. In v0.9.5, we added additional information to the payload of LTG packets that allows for tracking of LTG flows across nodes. This necessitated the creation of *_LTG log entry types for RX and TX packets. Since *_LTG log entry types contain all the fields of the non-*_LTG log entry types, we can merge the two log entry types to create a single set of log entries. This is equivalent to the behavior in v0.9.3. To do this, you need to update your filter commands:

# Filter log index to include all Rx entries, merged into RX_ALL, and all Tx entries
log_index = log_util.filter_log_index(raw_log_index, 
                                      include_only=['NODE_INFO', 'RX_OFDM', 'TX', 'TX_LOW'])


Changes to:


# Filter log index to include all Rx entries and all Tx entries
log_index = log_util.filter_log_index(raw_log_index, 
                                      include_only=['NODE_INFO', 'RX_OFDM', 'TX', 'TX_LOW'],
                                      merge={'RX_OFDM': ['RX_OFDM', 'RX_OFDM_LTG'], 
                                             'TX'     : ['TX', 'TX_LTG'],
                                             'TX_LOW' : ['TX_LOW', 'TX_LOW_LTG']})

Basically, you are merging the original entry type and the new _LTG entry type and then overwriting the original entry type list. For example, for 'TX' we take the 'TX' and 'TX_LTG' entry types and merge them in to the 'TX' entry type. The include_only parameter, then means we only the 'TX' log entry type. This is equivalent to the 'TX' log entry type in v0.9.3. One thing to remember is that if you want to use the new functionality of the _LTG entries, then you need to use that entry type.

Resources

Please refer to the pages below for wlan_exp documentation.