blob: bcfe48bdf90be3d550d5b83740fc144330766e5a [file] [log] [blame]
lh9ed821d2023-04-07 01:36:19 -07001/*******************************************************************************
2 * Copyright (C) 2007, ZTE Corporation.
3 *
4 * File Name: drvs_rf.h
5 * File Mark:
6 * Description:
7 * Others:
8 * Version: v1.2.1
9 * Author: wangxia
10 * Date: 2009-4-17
11 * History 1:
12 * Date:
13 * Version:
14 * Author:
15 * Modification:
16 * History 2:
17 ********************************************************************************/
18
19#ifndef _DRVS_RF_H
20#define _DRVS_RF_H
21
22
23/****************************************************************************
24* Include files
25****************************************************************************/
26
27
28/****************************************************************************
29* Macros
30****************************************************************************/
31
32
33/****************************************************************************
34* Types
35****************************************************************************/
36typedef struct
37{
38 UINT32 i2s2_wa_sel:1;
39 UINT32 i2s2_clk_sel:1;
40 UINT32 i2s1_wa_sel:1;
41 UINT32 i2s1_clk_sel:1;
42 UINT32 gpio_clkout3_sel:1;
43 UINT32 gpio_clkout2_sel:1;
44 UINT32 gpio_clkout1_sel:1;
45 UINT32 gpio_clkout0_sel:1;
46 UINT32 td_spi_sel:1;
47 UINT32 reserved9_15:7;
48 UINT32 td_time2_ind_en:1;
49 UINT32 td_time1_ind_en:1;
50 UINT32 rc_out1_en:1;
51 UINT32 rc_out0_en:1;
52 UINT32 clkout3_en:1;
53 UINT32 clkout2_en:1;
54 UINT32 clkout0_en:1;
55 UINT32 clkout1_en:1;
56 UINT32 reserved24_31:8;
57}T_ZDrvRf_I2s_ClkOut;
58
59
60typedef struct
61{
62 UINT32 spi_gpio_oen:14;
63 UINT32 reserved14_15:2;
64 UINT32 spi_gpio_in:14;
65 UINT32 reserved30_31:2;
66}T_ZDrvRf_SpiEn;
67
68
69typedef struct
70{
71 UINT32 spi_gpio_out:14;
72 UINT32 reserved14_15:2;
73 UINT32 spi_gpio_sel:14;
74 UINT32 reserved30_31:2;
75}T_ZDrvRf_SpiSel;
76
77
78
79/****************************************************************************
80* Constants
81****************************************************************************/
82
83/****************************************************************************
84* Global Variables
85****************************************************************************/
86
87/****************************************************************************
88* Function Prototypes
89****************************************************************************/
90
91/*******************************************************************************
92 * Function: zDrvRf_GsmSelect
93 * Description: select GSM rf through GPIO
94 * Parameters:
95 * Input:gsmgpio 0~7
96 *
97 * Output:
98 *
99 * Returns:
100 *
101 *
102 * Others:
103 ********************************************************************************/
104SINT32 zDrvRf_GsmSelect(UINT32 gsmgpio);
105
106
107/*******************************************************************************
108 * Function: zDrvRf_TdSelect
109 * Description: select TD rf through GPIO
110 * Parameters:
111 * Input:tdgpio 0~8
112 *
113 * Output:
114 *
115 * Returns:
116 *
117 *
118 * Others:
119 ********************************************************************************/
120SINT32 zDrvRf_TdSelect(UINT32 tdgpio);
121
122/*******************************************************************************
123 * Function: zDrvRf_I2sClkOutSel
124 * Description: select I2S & Clk Out
125 * Parameters:
126 * Input:
127 *
128 * Output:
129 *
130 * Returns:
131 *
132 *
133 * Others:
134 ********************************************************************************/
135VOID zDrvRf_I2sClkOutSel(T_ZDrvRf_I2s_ClkOut i2s_clkout);
136
137/*******************************************************************************
138 * Function: zDrvRf_SpiGpioOen
139 * Description:
140 * Parameters:
141 * Input:
142 *
143 * Output:
144 *
145 * Returns:
146 *
147 *
148 * Others:
149 ********************************************************************************/
150VOID zDrvRf_SpiGpioOen(T_ZDrvRf_SpiEn spioen);
151
152/*******************************************************************************
153 * Function: zDrvRf_SpiGpioSel
154 * Description:
155 * Parameters:
156 * Input:
157 *
158 * Output:
159 *
160 * Returns:
161 *
162 *
163 * Others:
164 ********************************************************************************/
165VOID zDrvRf_SpiGpioSel(T_ZDrvRf_SpiSel spisel);
166
167
168
169
170#endif/*_DRVS_RF_H*/
171