Changes between Version 11 and Version 12 of 802.11/MAC/Support_HW


Ignore:
Timestamp:
Apr 18, 2016, 10:12:40 AM (8 years ago)
Author:
murphpo
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • 802.11/MAC/Support_HW

    v11 v12  
    5454== MAC Tx Controller A ==
    5555
    56 Tx Controller A is capable of honoring a post-Tx timeout interval in which a reception is expected by the MAC state.
    57 
    58 The DCF implementation uses Tx Controller A for three transmission scenarios:
     56Tx Controller A is capable of honoring a post-Tx timeout interval during which the MAC expects an immediate response to its transmission. The DCF implementation uses Tx Controller A for three transmission scenarios:
    5957
    60581. Transmission of MPDU frames which do not require RTS ("short" frames)
     
    163161 * postTxTimer1_done: postTx_Timer1 has expired
    164162 * postTxTimer2_done: postTx_Timer2 has expired
    165  * backoff_done: The backoff counter has reached zero
     163 * backoff_A_done: The A backoff counter has reached zero
    166164 * idle_for_difs: The medium has been idle for a DIFS interval
    167165 * phy_tx_done: The Tx PHY has finished transmitting
     
    191189== MAC Tx Controller B ==
    192190
    193 The Tx Controller B is simpler than Tx Controller A. After a transmission is complete, the controller is done and does not need to start any kind of post-Tx timeout interval. Optionally, Tx Controller B can condition its transmission on medium idleness. The DCF implementation uses this controller for two purposes:
    194 
    195 1. Transmission of CTS frames
    196 1. Transmission of ACK frames
    197 
    198 Both of the above transmissions have the common trait of being "fire and forget." They are slightly different from one another in that ACK frames must be transmitted regardless of perceived medium busyness. This is not the case for CTS frames, which are only sent when the medium is deemed idle.
     191Tx Controller B is a simpler state machine that can schedule its transmission relative to post Tx/Rx timers. The reference DCF implementation uses Tx Controller B for two transmissions:
     192
     1931. Transmission of CTS frames a SIFS after an RTS Rx
     1941. Transmission of ACK frames a SIFS after a DATA Rx
     195
     196This controller is unique in being able to cancel its transmission based on the node's NAV value. This behavior is required when transmitting a CTS frame. When the DCF receives an RTS it schedules a CTS transmission a SIFS interval later. However if the NAV is non-zero at the end of the SIFS, the CTS frame is not transmitted.
    199197
    200198=== Implementation Details ===
    201 
    202 [[Image(tx_core_b.png, width=1000)]]
    203 
    204 Like Tx Controller A, the green section of the above state machine forces the controller to wait for a deterministic amount of time prior to a transmission. The DCF uses this to schedule CTS and ACK transmissions a SIFS interval after the previous reception. The CTS case additionally instructs the controller to condition transmission on medium idleness.
     199The Tx Controller B state machine is illustrated below. Each box is a state. Each arrow is a state transition, with the arrow's label specifying the input conditions that trigger the transition. The conditions for the color-coded arrows from the {{{IDLE}}} state are described in the table below.
     200
     201[[Image(tx_fsm_b.png)]]
     202
     203{{{#!th colspan=2 align=center
     204'''Tx Controller B FSM - Transitions from {{{IDLE}}}'''
     205}}}
     206|-----------------------------------
     207{{{#!td
     208}}}
     209{{{#!td align=left
     210
     211{{{#!c
     212if(new_tx) {
     213}}}
     214
     215}}}
     216|-----------------------------------
     217{{{#!td
     218[[Image(tx_fsm_transition_1.png)]]
     219}}}
     220{{{#!td
     221{{{#!c
     222        if(pre_wait_for_postRxTimer1 | pre_wait_for_postRxTimer2 | pre_wait_for_postTxTimer1 ) {
     223                //Tx fixed interval after previous Tx/Rx
     224                // Ignore medium and backoff states
     225                st_next = ST_PRE_TX_WAIT;
     226}}}
     227}}}
     228|-----------------------------------
     229{{{#!td
     230[[Image(tx_fsm_transition_2.png)]]
     231}}}
     232{{{#!td
     233
     234{{{#!c
     235        } else {
     236                // Transmit immediately
     237                st_next = ST_DO_TX;
     238}}}
     239}}}
     240|-----------------------------------
     241{{{#!td
     242
     243}}}
     244{{{#!td
     245
     246{{{#!c
     247} else {
     248        //No new Tx this cycle; keep waiting in IDLE
     249        st_next = ST_IDLE;
     250}
     251}}}
     252
     253}}}
     254
     255Notice that the state transitions depend on the postRx_Timer1 (SIFS timer). The state machine can also be conditioned on postRx_Timer2 and postTx_Timer1 for other MAC protocol extensions.
     256
     257Inputs from software:
     258 * reset: Forces FSM back to {{{IDLE}}} state
     259 * new_tx: Triggers new execution of FSM
     260 * req_nav_zero: Require NAV be zero at time of Tx, cancel Tx otherwise
     261 * pre_wait_for_postRxTimer1: Wait before Tx until postRx Timer 1 is done
     262 * pre_wait_for_postRxTimer2: Wait before Tx until postRx Timer 2 is done
     263 * pre_wait_for_postTxTimer1: Wait before Tx until postTx Timer 1 is done
     264
     265Inputs from MAC hardware:
     266 * nav_nonzero: NAV is nonzero
     267 * postRxTimer1_done: postRx Timer 1 is done
     268 * postRxTimer2_done: postRx Timer 2 is done
     269 * postTxTimer1_done: postTx Timer 1 is done
     270 * phy_tx_done: PHY Tx has completed
     271
     272The lower MAC framework provides macros for configuring the software parameters above:
     273{{{#!c
     274// Configure Tx Controller B
     275//  pktBuf: Tx packet buffer index (passed directly to PHY at TX_START)
     276//  antMask: antenna selection mask  (passed directly to PHY at TX_START)
     277//  req_zeroNAV: require NAV=0 at Tx time, must be 0 or 1
     278//  preWait_postRxTimer1: param for FSM, must be 0 or 1
     279//  preWait_postRxTimer2: param for FSM, must be 0 or 1
     280//  preWait_postTxTimer1: param for FSM, must be 0 or 1
     281wlan_mac_tx_ctrl_B_params(pktBuf, antMask, req_zeroNAV, preWait_postRxTimer1, preWait_postRxTimer2, preWait_postTxTimer1);
     282}}}
     283
     284The Tx Controller B state machine is started by toggling its enable bit in the MAC support core's register bank:
     285{{{#!c
     286// Start Tx Controller B
     287wlan_mac_tx_ctrl_B_start(1);
     288wlan_mac_tx_ctrl_B_start(0);
     289}}}
     290
     291The Tx Controller B state machine is implemented as an m-code block in the {{{wlan_mac_hw}}} core. The m source code is in the repository at [browser:/ReferenceDesigns/w3_802.11/sysgen/wlan_mac_hw/mcode_blocks/mac_tx_ctrl_b_fsm.m mac_tx_ctrl_b_fsm.m]