Changes between Version 16 and Version 17 of 802.11/wlan_exp/Extending


Ignore:
Timestamp:
Dec 17, 2015, 10:04:35 AM (8 years ago)
Author:
chunter
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • 802.11/wlan_exp/Extending

    v16 v17  
    4949The 802.11 MAC code running on the WARP node handles user commands at two levels.
    5050
    51  * '''Framework''': If the command behavior is common to all MAC applications, the command is handled in the {{{process_user_cmd()}}} function in {{{wlan_exp_user.c}}}. You should modify {{{process_user_cmd()}}} to handle any new framework-level commands required for your application. Any command IDs not handled in {{{process_user_cmd()}}} will be passed through to the MAC application.
    52 
    53  * '''MAC Application''': If a command behavior depends on the upper-level MAC application, the command is handled in the {{{wlan_exp_process_user_cmd()}}} callback function in the top-level MAC. You should modify the {{{wlan_exp_process_user_cmd()}}} function in the {{{wlan_mac_ap.c}}}, {{{wlan_mac_sta.c}}} and {{{wlan_mac_ibss.c}}} files to implement any MAC-specific command behaviors.
     51 * '''Framework''': If the command behavior is common to all high-level MAC applications, the command is handled in the {{{process_user_cmd()}}} function in {{{wlan_exp_user.c}}}. You should modify {{{process_user_cmd()}}} to handle any new framework-level commands required for your application. Any command IDs not handled in {{{process_user_cmd()}}} will be passed through to the high-level MAC application.
     52
     53 * '''High-level MAC Application''': If a command behavior depends on the high-level MAC application, the command is handled in the {{{wlan_exp_process_user_cmd()}}} callback function in the high-level MAC. You should modify the {{{wlan_exp_process_user_cmd()}}} function in the {{{wlan_mac_ap.c}}}, {{{wlan_mac_sta.c}}} and {{{wlan_mac_ibss.c}}} files to implement any MAC-specific command behaviors.
    5454
    5555Command handlers in these functions share a common structure:
     
    143143'''C Code'''[[BR]]
    144144
    145 Each upper-level MAC application implements its own callback function for handling application-specific user commands. By default these functions are empty. You must modify the C code to implement the behaviors required for your custom command.  The code below is for the AP.  It is left to the user to implement similar functionality the other MAC applications so that the command works on all types of nodes.
     145Each high-level MAC application implements its own callback function for handling application-specific user commands. By default these functions are empty. You must modify the C code to implement the behaviors required for your custom command.  The code below is for the AP.  It is left to the user to implement similar functionality the other MAC applications so that the command works on all types of nodes.
    146146
    147147Modify the {{{wlan_exp_user_ap_process_cmd()}}} function in {{{wlan_mac_ap.c}}}. Start by defining the command ID before the function: