1 | /** @file wlan_mac_userio_util.h |
---|
2 | * @brief User I/O Definitions |
---|
3 | * |
---|
4 | * This contains WARP User I/O definitions for all CPUs |
---|
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 | |
---|
15 | /*************************** Constant Definitions ****************************/ |
---|
16 | #ifndef WLAN_MAC_USERIO_UTIL_H_ |
---|
17 | #define WLAN_MAC_USERIO_UTIL_H_ |
---|
18 | |
---|
19 | //----------------------------------------------- |
---|
20 | // Base Addresses |
---|
21 | // |
---|
22 | #define USERIO_BASEADDR XPAR_W3_USERIO_BASEADDR ///< XParameters rename of base address of User I/O |
---|
23 | |
---|
24 | //----------------------------------------------- |
---|
25 | // Extra definitions not provided by driver |
---|
26 | #define W3_USERIO_DIPSW_0 0x08 |
---|
27 | #define W3_USERIO_DIPSW_1 0x04 |
---|
28 | #define W3_USERIO_DIPSW_2 0x02 |
---|
29 | #define W3_USERIO_DIPSW_3 0x01 |
---|
30 | |
---|
31 | /*********************** Global Structure Definitions ************************/ |
---|
32 | |
---|
33 | |
---|
34 | /*************************** Function Prototypes *****************************/ |
---|
35 | u8 hex_to_seven_segment(u8 hex_value); |
---|
36 | |
---|
37 | void enable_hex_pwm(); |
---|
38 | void disable_hex_pwm(); |
---|
39 | void set_hex_pwm_period(u16 period); |
---|
40 | void set_hex_pwm_min_max(u16 min, u16 max); |
---|
41 | |
---|
42 | void write_hex_display(u8 val); |
---|
43 | void write_hex_display_with_pwm(u8 val); |
---|
44 | |
---|
45 | void set_hex_display_error_status(u8 status); |
---|
46 | |
---|
47 | void blink_hex_display(u32 num_blinks, u32 blink_time); |
---|
48 | |
---|
49 | void set_hex_display_right_dp(u8 val); |
---|
50 | void set_hex_display_left_dp(u8 val); |
---|
51 | |
---|
52 | |
---|
53 | #endif // END WLAN_MAC_USERIO_UTIL_H_ |
---|