{{{#!comment [[Include(wiki:802.11/beta-note)]] }}} [[TracNav(802.11/TOC)]] = 802.11 Reference Design Experiments Framework: AP Log Capture Example = This example of the Experiments Framework provides an interactive script for initializing one WARP v3 node as an AP, waiting, then retrieving the node's log and writing it to an HDF5 log file. This script is ideal for capturing a log file with Tx and Rx events recorded from Wi-Fi clients using the 802.11 Reference Design AP. To use this script: * Setup wlan_exp (see [wiki:../../GettingStarted Getting Started] for details) * Configure one WARP v3 node using the 802.11 Reference Design AP bitstream * Open the file in a text editor and change the {{{NODE_SERIAL_LIST}}} to match your serial numbers * Open a Python shell * CD to the '''Python_Reference/examples/txrx_log''' directory from the expanded 802.11 Reference design archive * Run {{{python log_capture_ap_interactive.py}}} * After running this script you can analyze the log file using the wlan_exp log tools. Refer to the [wiki:../txrx_log_analysis txrx_log analysis examples] to get started processing your log file. The script will run until you type either 'q', 'quit' or press 'Ctrl-C' and then write the log file: {{{ Initializing experiment Reseting the network config for all nodes on subnet 10.0.0. Initializing W3-a-00006 as Node 0 Initializing the time of all nodes on 10.0.0 to: 0.0 Adding current time to log for nodes on 10.0.0 Run Experiment: Use 'q' or Ctrl-C to end the experiment. NOTE: In IPython, press return to see status update. Duration: 270 sec Log Size: Node 0 = 419176 bytes q Ending experiment Writing 420008 bytes of data to log file... log_files/ap_interactive_capture.hdf5 Done. Experiment Finished. }}} NOTE: By default, the script will try to use the file name: {{{log_files/ap_interactive_capture.hdf5}}}. You are free to override this behavior on the command line: {{{python log_capture_ap_interactive.py }}}. Just remember that the script uses relative paths from the '''Python_Reference/examples/txrx_log/''' directory so if you are trying to run the script from a different directory, you may see: {{{ ERROR: Logfile log_files/ap_interactive_capture.hdf5 not able to be created }}} in this case, either change to the correct directory, or supply an appropriate file name. ---- '''Source:''' the script is included in the 802.11 Reference Design archive at '''Python_Reference/examples/txrx_log/log_capture_ap_interactive.py'''.