source: ReferenceDesigns/w3_802.11/c/wlan_mac_high_ap/include/wlan_mac_ap.h

Last change on this file was 6319, checked in by chunter, 5 years ago

1.8.0 release wlan-mac-se

File size: 3.9 KB
Line 
1/** @file wlan_mac_ap.h
2 *  @brief Access Point
3 *
4 *  This contains code for the 802.11 Access Point.
5 *
6 *  @copyright Copyright 2013-2019, Mango Communications. All rights reserved.
7 *          Distributed under the Mango Communications Reference Design License
8 *              See LICENSE.txt included in the design archive or
9 *              at http://mangocomm.com/802.11/license
10 *
11 *  This file is part of the Mango 802.11 Reference Design (https://mangocomm.com/802.11)
12 */
13
14/*************************** Constant Definitions ****************************/
15#ifndef WLAN_MAC_AP_H_
16#define WLAN_MAC_AP_H_
17
18/***************************** Include Files *********************************/
19
20#include "xil_types.h"
21#include "wlan_common_types.h"
22
23// Forward declarations
24struct station_info_t;
25struct rx_common_entry;
26struct network_info_t;
27enum scan_state_t;
28struct bss_config_t;
29struct tx_frame_info_t;
30struct eth_rx_queue_buffer_t;
31struct tx_queue_buffer_t;
32
33//-----------------------------------------------
34// Enable the WLAN UART Menu
35#define WLAN_USE_UART_MENU
36
37
38//-----------------------------------------------
39// Allow Ethernet transmission of packets received by an associated station
40// destined for another associated station
41//#define ALLOW_ETH_TX_OF_WIRELESS_TX
42
43
44//-----------------------------------------------
45// Common Defines
46#define MAX_TX_QUEUE_LEN                                   150       /// Maximum number of entries in any Tx queue
47
48#define MAX_NUM_ASSOC                                      10        /// Maximum number of associations allowed
49#define MAX_NUM_AUTH                                       10        /// Maximum number of authentications allowed
50
51
52//-----------------------------------------------
53// Timing Parameters
54
55// Period for checking association table for stale associations
56#define ASSOCIATION_CHECK_INTERVAL_MS                     (1000)
57#define ASSOCIATION_CHECK_INTERVAL_US                     (ASSOCIATION_CHECK_INTERVAL_MS * 1000)
58
59// Timeout for last reception for an association; timed-out associations are subject to de-association
60#define ASSOCIATION_TIMEOUT_S                             (300)
61#define ASSOCIATION_TIMEOUT_US                            (ASSOCIATION_TIMEOUT_S * 1000000)
62
63// Interval to allow associations after entering ASSOCIATION_ALLOW_TEMPORARY mode
64#define ASSOCIATION_ALLOW_INTERVAL_MS                     (30000)
65#define ASSOCIATION_ALLOW_INTERVAL_US                     (ASSOCIATION_ALLOW_INTERVAL_MS * 1000)
66
67// Blinking period for hex displays, when used to show association mode
68#define ANIMATION_RATE_US                                 (100000)
69
70
71/*********************** Global Structure Definitions ************************/
72
73/*************************** Function Prototypes *****************************/
74int  main();
75
76void ltg_event(u32 id, void* callback_arg);
77
78int ethernet_receive(struct eth_rx_queue_buffer_t* eth_rx_queue_buffer);
79u32                     mpdu_rx_process(void* pkt_buf_addr, struct station_info_t* station_info, struct rx_common_entry* rx_event_log_entry);
80struct network_info_t*      active_network_info_getter();
81void                    process_scan_state_change(enum scan_state_t scan_state);
82
83void queue_state_change(u32 aid, u32 queue_len);
84void update_tim_tag_aid(u8 aid, u8 bit_val_in);
85void update_tim_tag_all(u32 sched_id);
86
87void poll_tx_queues();
88void purge_all_wireless_tx_queue();
89
90void enable_associations();
91void disable_associations();
92void remove_inactive_station_infos();
93void association_timestamp_adjust(s64 timestamp_diff);
94
95u32  deauthenticate_station( struct station_info_t* station_info );
96void deauthenticate_all_stations();
97void handle_cpu_low_reboot(u32 type);
98u32  configure_bss(struct bss_config_t* bss_config, u32 update_mask);
99void mpdu_dequeue(struct tx_queue_buffer_t* tx_80211_queue_buffer);
100
101void button_0_press();
102void button_0_release();
103
104void uart_rx(u8 rxByte);
105
106#endif /* WLAN_MAC_AP_H_ */
Note: See TracBrowser for help on using the repository browser.