xref: /utopia/UTPA2-700.0.x/modules/demodulator/hal/maxim/demod/halDMD_INTERN_DVBS.h (revision 53ee8cc121a030b8d368113ac3e966b4705770ef)
1*53ee8cc1Swenshuai.xi //<MStar Software>
2*53ee8cc1Swenshuai.xi //******************************************************************************
3*53ee8cc1Swenshuai.xi // MStar Software
4*53ee8cc1Swenshuai.xi // Copyright (c) 2010 - 2012 MStar Semiconductor, Inc. All rights reserved.
5*53ee8cc1Swenshuai.xi // All software, firmware and related documentation herein ("MStar Software") are
6*53ee8cc1Swenshuai.xi // intellectual property of MStar Semiconductor, Inc. ("MStar") and protected by
7*53ee8cc1Swenshuai.xi // law, including, but not limited to, copyright law and international treaties.
8*53ee8cc1Swenshuai.xi // Any use, modification, reproduction, retransmission, or republication of all
9*53ee8cc1Swenshuai.xi // or part of MStar Software is expressly prohibited, unless prior written
10*53ee8cc1Swenshuai.xi // permission has been granted by MStar.
11*53ee8cc1Swenshuai.xi //
12*53ee8cc1Swenshuai.xi // By accessing, browsing and/or using MStar Software, you acknowledge that you
13*53ee8cc1Swenshuai.xi // have read, understood, and agree, to be bound by below terms ("Terms") and to
14*53ee8cc1Swenshuai.xi // comply with all applicable laws and regulations:
15*53ee8cc1Swenshuai.xi //
16*53ee8cc1Swenshuai.xi // 1. MStar shall retain any and all right, ownership and interest to MStar
17*53ee8cc1Swenshuai.xi //    Software and any modification/derivatives thereof.
18*53ee8cc1Swenshuai.xi //    No right, ownership, or interest to MStar Software and any
19*53ee8cc1Swenshuai.xi //    modification/derivatives thereof is transferred to you under Terms.
20*53ee8cc1Swenshuai.xi //
21*53ee8cc1Swenshuai.xi // 2. You understand that MStar Software might include, incorporate or be
22*53ee8cc1Swenshuai.xi //    supplied together with third party`s software and the use of MStar
23*53ee8cc1Swenshuai.xi //    Software may require additional licenses from third parties.
24*53ee8cc1Swenshuai.xi //    Therefore, you hereby agree it is your sole responsibility to separately
25*53ee8cc1Swenshuai.xi //    obtain any and all third party right and license necessary for your use of
26*53ee8cc1Swenshuai.xi //    such third party`s software.
27*53ee8cc1Swenshuai.xi //
28*53ee8cc1Swenshuai.xi // 3. MStar Software and any modification/derivatives thereof shall be deemed as
29*53ee8cc1Swenshuai.xi //    MStar`s confidential information and you agree to keep MStar`s
30*53ee8cc1Swenshuai.xi //    confidential information in strictest confidence and not disclose to any
31*53ee8cc1Swenshuai.xi //    third party.
32*53ee8cc1Swenshuai.xi //
33*53ee8cc1Swenshuai.xi // 4. MStar Software is provided on an "AS IS" basis without warranties of any
34*53ee8cc1Swenshuai.xi //    kind. Any warranties are hereby expressly disclaimed by MStar, including
35*53ee8cc1Swenshuai.xi //    without limitation, any warranties of merchantability, non-infringement of
36*53ee8cc1Swenshuai.xi //    intellectual property rights, fitness for a particular purpose, error free
37*53ee8cc1Swenshuai.xi //    and in conformity with any international standard.  You agree to waive any
38*53ee8cc1Swenshuai.xi //    claim against MStar for any loss, damage, cost or expense that you may
39*53ee8cc1Swenshuai.xi //    incur related to your use of MStar Software.
40*53ee8cc1Swenshuai.xi //    In no event shall MStar be liable for any direct, indirect, incidental or
41*53ee8cc1Swenshuai.xi //    consequential damages, including without limitation, lost of profit or
42*53ee8cc1Swenshuai.xi //    revenues, lost or damage of data, and unauthorized system use.
43*53ee8cc1Swenshuai.xi //    You agree that this Section 4 shall still apply without being affected
44*53ee8cc1Swenshuai.xi //    even if MStar Software has been modified by MStar in accordance with your
45*53ee8cc1Swenshuai.xi //    request or instruction for your use, except otherwise agreed by both
46*53ee8cc1Swenshuai.xi //    parties in writing.
47*53ee8cc1Swenshuai.xi //
48*53ee8cc1Swenshuai.xi // 5. If requested, MStar may from time to time provide technical supports or
49*53ee8cc1Swenshuai.xi //    services in relation with MStar Software to you for your use of
50*53ee8cc1Swenshuai.xi //    MStar Software in conjunction with your or your customer`s product
51*53ee8cc1Swenshuai.xi //    ("Services").
52*53ee8cc1Swenshuai.xi //    You understand and agree that, except otherwise agreed by both parties in
53*53ee8cc1Swenshuai.xi //    writing, Services are provided on an "AS IS" basis and the warranty
54*53ee8cc1Swenshuai.xi //    disclaimer set forth in Section 4 above shall apply.
55*53ee8cc1Swenshuai.xi //
56*53ee8cc1Swenshuai.xi // 6. Nothing contained herein shall be construed as by implication, estoppels
57*53ee8cc1Swenshuai.xi //    or otherwise:
58*53ee8cc1Swenshuai.xi //    (a) conferring any license or right to use MStar name, trademark, service
59*53ee8cc1Swenshuai.xi //        mark, symbol or any other identification;
60*53ee8cc1Swenshuai.xi //    (b) obligating MStar or any of its affiliates to furnish any person,
61*53ee8cc1Swenshuai.xi //        including without limitation, you and your customers, any assistance
62*53ee8cc1Swenshuai.xi //        of any kind whatsoever, or any information; or
63*53ee8cc1Swenshuai.xi //    (c) conferring any license or right under any intellectual property right.
64*53ee8cc1Swenshuai.xi //
65*53ee8cc1Swenshuai.xi // 7. These terms shall be governed by and construed in accordance with the laws
66*53ee8cc1Swenshuai.xi //    of Taiwan, R.O.C., excluding its conflict of law rules.
67*53ee8cc1Swenshuai.xi //    Any and all dispute arising out hereof or related hereto shall be finally
68*53ee8cc1Swenshuai.xi //    settled by arbitration referred to the Chinese Arbitration Association,
69*53ee8cc1Swenshuai.xi //    Taipei in accordance with the ROC Arbitration Law and the Arbitration
70*53ee8cc1Swenshuai.xi //    Rules of the Association by three (3) arbitrators appointed in accordance
71*53ee8cc1Swenshuai.xi //    with the said Rules.
72*53ee8cc1Swenshuai.xi //    The place of arbitration shall be in Taipei, Taiwan and the language shall
73*53ee8cc1Swenshuai.xi //    be English.
74*53ee8cc1Swenshuai.xi //    The arbitration award shall be final and binding to both parties.
75*53ee8cc1Swenshuai.xi //
76*53ee8cc1Swenshuai.xi //******************************************************************************
77*53ee8cc1Swenshuai.xi //<MStar Software>
78*53ee8cc1Swenshuai.xi ////////////////////////////////////////////////////////////////////////////////
79*53ee8cc1Swenshuai.xi //
80*53ee8cc1Swenshuai.xi // Copyright (c) 2006-2009 MStar Semiconductor, Inc.
81*53ee8cc1Swenshuai.xi // All rights reserved.
82*53ee8cc1Swenshuai.xi //
83*53ee8cc1Swenshuai.xi // Unless otherwise stipulated in writing, any and all information contained
84*53ee8cc1Swenshuai.xi // herein regardless in any format shall remain the sole proprietary of
85*53ee8cc1Swenshuai.xi // MStar Semiconductor Inc. and be kept in strict confidence
86*53ee8cc1Swenshuai.xi // (��MStar Confidential Information��) by the recipient.
87*53ee8cc1Swenshuai.xi // Any unauthorized act including without limitation unauthorized disclosure,
88*53ee8cc1Swenshuai.xi // copying, use, reproduction, sale, distribution, modification, disassembling,
89*53ee8cc1Swenshuai.xi // reverse engineering and compiling of the contents of MStar Confidential
90*53ee8cc1Swenshuai.xi // Information is unlawful and strictly prohibited. MStar hereby reserves the
91*53ee8cc1Swenshuai.xi // rights to any and all damages, losses, costs and expenses resulting therefrom.
92*53ee8cc1Swenshuai.xi //
93*53ee8cc1Swenshuai.xi ////////////////////////////////////////////////////////////////////////////////
94*53ee8cc1Swenshuai.xi 
95*53ee8cc1Swenshuai.xi #ifndef _INTERN_DVBS_H_
96*53ee8cc1Swenshuai.xi #define _INTERN_DVBS_H_
97*53ee8cc1Swenshuai.xi 
98*53ee8cc1Swenshuai.xi #ifdef _INTERN_DVBS_C_
99*53ee8cc1Swenshuai.xi #define EXTSEL
100*53ee8cc1Swenshuai.xi #else
101*53ee8cc1Swenshuai.xi #define EXTSEL extern
102*53ee8cc1Swenshuai.xi #endif
103*53ee8cc1Swenshuai.xi 
104*53ee8cc1Swenshuai.xi #define NEW_TR_MODULE
105*53ee8cc1Swenshuai.xi //--------------------------------------------------------------------
106*53ee8cc1Swenshuai.xi 
107*53ee8cc1Swenshuai.xi // #define     DEMOD_DYNAMIC_SLAVE_ID_1          0x32
108*53ee8cc1Swenshuai.xi // #define     DEMOD_DYNAMIC_SLAVE_ID_2          0x72
109*53ee8cc1Swenshuai.xi // #define     DEMOD_DYNAMIC_SLAVE_ID_3          0xB2
110*53ee8cc1Swenshuai.xi // #define     DEMOD_DYNAMIC_SLAVE_ID_4          0xF2
111*53ee8cc1Swenshuai.xi 
112*53ee8cc1Swenshuai.xi #define     DEMOD_ADDR_H            0x00
113*53ee8cc1Swenshuai.xi #define     DEMOD_ADDR_L            0x01
114*53ee8cc1Swenshuai.xi #define     DEMOD_WRITE_REG         0x02
115*53ee8cc1Swenshuai.xi #define     DEMOD_WRITE_REG_EX      0x03
116*53ee8cc1Swenshuai.xi #define     DEMOD_READ_REG          0x04
117*53ee8cc1Swenshuai.xi #define     DEMOD_RAM_CONTROL       0x05
118*53ee8cc1Swenshuai.xi 
119*53ee8cc1Swenshuai.xi #if  0//DTV_SCAN_AUTO_FINE_TUNE_ENABLE
120*53ee8cc1Swenshuai.xi     //INTERN_DVBT_ Capture Range fix to 500K
121*53ee8cc1Swenshuai.xi     #define DEMOD_CAPTURE_RANGE_500_K            500
122*53ee8cc1Swenshuai.xi     #define DEMOD_CAPTURE_RANGE_SIZE			 DEMOD_CAPTURE_RANGE_500_K
123*53ee8cc1Swenshuai.xi #endif
124*53ee8cc1Swenshuai.xi 
125*53ee8cc1Swenshuai.xi #define MDrv_ReadByte(x)  HAL_DMD_RIU_ReadByte(x)
126*53ee8cc1Swenshuai.xi #define MDrv_WriteByte(x,y)  HAL_DMD_RIU_WriteByte(x,y)
127*53ee8cc1Swenshuai.xi 
128*53ee8cc1Swenshuai.xi #if 1
129*53ee8cc1Swenshuai.xi #define U8      unsigned char
130*53ee8cc1Swenshuai.xi #define U16     unsigned short
131*53ee8cc1Swenshuai.xi #define U32     unsigned long
132*53ee8cc1Swenshuai.xi #define BOOL    unsigned char
133*53ee8cc1Swenshuai.xi #define BOOLEAN  unsigned char
134*53ee8cc1Swenshuai.xi #if 0
135*53ee8cc1Swenshuai.xi #define BIT0     0x01
136*53ee8cc1Swenshuai.xi #define BIT1     0x02
137*53ee8cc1Swenshuai.xi #define BIT2     0x04
138*53ee8cc1Swenshuai.xi #define BIT3     0x08
139*53ee8cc1Swenshuai.xi #define BIT4     0x10
140*53ee8cc1Swenshuai.xi #define BIT5     0x20
141*53ee8cc1Swenshuai.xi #define BIT6     0x40
142*53ee8cc1Swenshuai.xi #define BIT7     0x80
143*53ee8cc1Swenshuai.xi #endif
144*53ee8cc1Swenshuai.xi #define BYTE     MAPI_U8
145*53ee8cc1Swenshuai.xi 
146*53ee8cc1Swenshuai.xi #define WORD     MAPI_WORD
147*53ee8cc1Swenshuai.xi #define E_RESULT_SUCCESS     MAPI_TRUE
148*53ee8cc1Swenshuai.xi #define E_RESULT_FAILURE     MAPI_FALSE
149*53ee8cc1Swenshuai.xi #define FUNCTION_RESULT      MAPI_BOOL
150*53ee8cc1Swenshuai.xi 
151*53ee8cc1Swenshuai.xi 
152*53ee8cc1Swenshuai.xi #define INTERN_DVBS_TS_SERIAL_INVERSION       			0
153*53ee8cc1Swenshuai.xi #define INTERN_DVBS_TS_PARALLEL_INVERSION     			1
154*53ee8cc1Swenshuai.xi #define INTERN_DVBS_DTV_DRIVING_LEVEL          			1
155*53ee8cc1Swenshuai.xi #define INTERN_DVBS_WEAK_SIGNAL_PICTURE_FREEZE_ENABLE  	1
156*53ee8cc1Swenshuai.xi #endif
157*53ee8cc1Swenshuai.xi 
158*53ee8cc1Swenshuai.xi typedef struct
159*53ee8cc1Swenshuai.xi {
160*53ee8cc1Swenshuai.xi     MS_U8        cmd_code;
161*53ee8cc1Swenshuai.xi     MS_U8        param[64];
162*53ee8cc1Swenshuai.xi } S_CMDPKTREG;
163*53ee8cc1Swenshuai.xi typedef enum
164*53ee8cc1Swenshuai.xi {
165*53ee8cc1Swenshuai.xi     TS_MODUL_MODE,
166*53ee8cc1Swenshuai.xi     TS_FFX_VALUE,
167*53ee8cc1Swenshuai.xi     TS_GUARD_INTERVAL,
168*53ee8cc1Swenshuai.xi     TS_CODE_RATE,
169*53ee8cc1Swenshuai.xi 
170*53ee8cc1Swenshuai.xi     TS_PARAM_MAX_NUM
171*53ee8cc1Swenshuai.xi }E_SIGNAL_TYPE;
172*53ee8cc1Swenshuai.xi 
173*53ee8cc1Swenshuai.xi typedef enum
174*53ee8cc1Swenshuai.xi {
175*53ee8cc1Swenshuai.xi     CMD_SYSTEM_INIT = 0,
176*53ee8cc1Swenshuai.xi     CMD_DAC_CALI,
177*53ee8cc1Swenshuai.xi     CMD_DVBT_CONFIG,
178*53ee8cc1Swenshuai.xi     CMD_DVBC_CONFIG,
179*53ee8cc1Swenshuai.xi     CMD_VIF_CTRL,
180*53ee8cc1Swenshuai.xi     CMD_FSM_CTRL,
181*53ee8cc1Swenshuai.xi     CMD_INDIR_RREG,
182*53ee8cc1Swenshuai.xi     CMD_INDIR_WREG,
183*53ee8cc1Swenshuai.xi     CMD_GET_INFO,
184*53ee8cc1Swenshuai.xi     CMD_TS_CTRL,
185*53ee8cc1Swenshuai.xi     CMD_TUNED_VALUE,
186*53ee8cc1Swenshuai.xi 
187*53ee8cc1Swenshuai.xi     CMD_MAX_NUM
188*53ee8cc1Swenshuai.xi }E_CMD_CODE;
189*53ee8cc1Swenshuai.xi typedef enum
190*53ee8cc1Swenshuai.xi {
191*53ee8cc1Swenshuai.xi     TS_PARALLEL = 0,
192*53ee8cc1Swenshuai.xi     TS_SERIAL = 1,
193*53ee8cc1Swenshuai.xi 
194*53ee8cc1Swenshuai.xi     TS_MODE_MAX_NUM
195*53ee8cc1Swenshuai.xi }E_TS_MODE;
196*53ee8cc1Swenshuai.xi typedef enum
197*53ee8cc1Swenshuai.xi {
198*53ee8cc1Swenshuai.xi     E_SYS_UNKOWN = -1,
199*53ee8cc1Swenshuai.xi     E_SYS_DVBT,
200*53ee8cc1Swenshuai.xi     E_SYS_DVBC,
201*53ee8cc1Swenshuai.xi     E_SYS_ATSC,
202*53ee8cc1Swenshuai.xi     E_SYS_VIF,
203*53ee8cc1Swenshuai.xi     E_SYS_DVBS,
204*53ee8cc1Swenshuai.xi 
205*53ee8cc1Swenshuai.xi     E_SYS_NUM
206*53ee8cc1Swenshuai.xi }E_SYSTEM;
207*53ee8cc1Swenshuai.xi 
208*53ee8cc1Swenshuai.xi //--------------------------------------------------------------------
209*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Reset ( void );
210*53ee8cc1Swenshuai.xi MS_U16 	INTERN_DVBS_DSPReg_Init(const MS_U8 *u8DVBS_DSPReg,  MS_U8 u8Size);
211*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Cmd_Packet_Send(S_CMDPKTREG* pCmdPacket, MS_U8 param_cnt);
212*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Exit ( void );
213*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Active(MS_BOOL bEnable);
214*53ee8cc1Swenshuai.xi 
215*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetPostViterbiBer(MS_U32 *BitErr, MS_U16 *BitErrPeriod);
216*53ee8cc1Swenshuai.xi 
217*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetPerViterbiBer(float *perber);
218*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetPacketErr(MS_U16 *pktErr);
219*53ee8cc1Swenshuai.xi 
220*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Power_On_Initialization(MS_BOOL bRFAGCTristateEnable, MS_U8 u8ADCIQMode, MS_U8 u8PadSel, MS_BOOL bPGAEnable, MS_U8 u8PGAGain, const MS_U8 *u8DMD_DVBS_DSPRegInitExt, MS_U8 u8DMD_DVBS_DSPRegInitSize);
221*53ee8cc1Swenshuai.xi 
222*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Serial_Control(MS_BOOL bEnable, MS_U8 u8TSClk);
223*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Config(MS_U32 u32SymbolRate, DMD_DVBS_MODULATION_TYPE eQamMode, MS_U32 u32IFFreq, MS_BOOL bSpecInv, MS_BOOL bSerialTS, MS_U8 u8TSClk, MS_U16 *pu16_symbol_rate_list,MS_U8 u8_symbol_rate_list_num);
224*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_Config(MS_U32 u32SymbolRate, DMD_DVBS_MODULATION_TYPE eQamMode, MS_U32 u32IFFreq, MS_BOOL bSpecInv, MS_BOOL bSerialTS, MS_U8 u8TSClk, MS_U16 *pu16_symbol_rate_list,MS_U8 u8_symbol_rate_list_num);
225*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Active(MS_BOOL bEnable);
226*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetLock(DMD_DVBS_GETLOCK_TYPE eType, MS_U16 fCurrRFPowerDbm, MS_U16 fNoChannelRFPowerDbm, MS_U32 u32TimeInterval);
227*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetSignalStrength(MS_U16 fRFPowerDbm, DMD_DVBS_DEMOD_TYPE *pDemodType, MS_U8  *u8_DVBS2_CurrentCodeRateLocal,  MS_U8   *u8_DVBS2_CurrentConstellationLocal);
228*53ee8cc1Swenshuai.xi //MS_BOOL INTERN_DVBS_GetSignalQuality(MS_U16 *quality, const DMD_DVBS_InitData *sDMD_DVBS_InitData, MS_U8 u8SarValue, float fRFPowerDbm);
229*53ee8cc1Swenshuai.xi 
230*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetSNR(MS_U32 *u32NDA_SNR_A, MS_U32 *u32NDA_SNR_AB);
231*53ee8cc1Swenshuai.xi 
232*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetIFAGC(MS_U8 *ifagc_reg, MS_U8 *ifagc_reg_lsb, MS_U16 *ifagc_err);
233*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Get_CELL_ID(MS_U16 *cell_id);
234*53ee8cc1Swenshuai.xi // MS_BOOL INTERN_DVBC_Get_TPS_Parameter_Const( MS_U16 * TPS_parameter, E_SIGNAL_TYPE eSignalType);
235*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Version(MS_U16 *ver);
236*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetCurrentSymbolRate(MS_U32 *u32SymbolRate);
237*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Get_FreqOffset(MS_S16 *s16CFO);
238*53ee8cc1Swenshuai.xi 
239*53ee8cc1Swenshuai.xi void INTERN_DVBS_info(void);
240*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Show_AGC_Info(void);
241*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetTsDivNum(MS_U32 *u32SymbolRate, MS_U8* system_type_reg, MS_U8 *code_rate_idx, MS_U8 *fec_type_idx, MS_U8 *pilot_flag, MS_U32 *u32temp, MS_U8 *code_rate_reg);
242*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetCurrentModulationType(DMD_DVBS_MODULATION_TYPE *pQAMMode);
243*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetCurrentDemodType(DMD_DVBS_DEMOD_TYPE *pDemodType);
244*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetCurrentDemodCodeRate(DMD_DVBS_CODE_RATE_TYPE *pCodeRate);
245*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetTunrSignalLevel_PWR(MS_U16 *u16Data);
246*53ee8cc1Swenshuai.xi //--------------------------------------------------------------------
247*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_GetRollOff(MS_U8 *pRollOff);
248*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_GetTunerFreq(MS_U16 *u16TunerCenterFreq, MS_U16 *u16TunerCutOffFreq);
249*53ee8cc1Swenshuai.xi 
250*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_Start(MS_U16 u16StartFreq,MS_U16 u16EndFreq);
251*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_NextFreq(MS_BOOL* bBlindScanEnd);
252*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_Cancel(void);
253*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_End(void);
254*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_GetChannel(MS_U16 u16ReadStart,MS_U16* u16TPNum,HAL_DEMOD_MS_FE_CARRIER_PARAM *pTable);
255*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_GetCurrentFreq(MS_U32 *u32CurrentFeq);
256*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_BlindScan_WaitCurFreqFinished(MS_U8* u8Progress,MS_U8 *u8FindNum, MS_U8 *substate_reg, MS_U32  *u32Data, MS_U16 *symbolrate_reg, MS_U16 *CFO_reg);
257*53ee8cc1Swenshuai.xi 
258*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_Init(void);
259*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_SetLNBOut(MS_BOOL bLow);
260*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_GetLNBOut(MS_BOOL* bLNBOutLow);
261*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_Set22kOnOff(MS_BOOL b22kOn);
262*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_Get22kOnOff(MS_BOOL* b22kOn);
263*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_SendCmd(MS_U8* pCmd,MS_U8 u8CmdSize);
264*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_SetTxToneMode(MS_BOOL bTxTone22kOff);
265*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DiSEqC_SetTone(MS_BOOL bTone1);
266*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_UnicableAGCCheckPower(MS_BOOL pbAGCCheckPower);
267*53ee8cc1Swenshuai.xi 
268*53ee8cc1Swenshuai.xi //MS_BOOL INTERN_DVBS_Demod_Restart(MS_U32 u32SymbolRate, MS_U32 u32Frequency);
269*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Get_DTV_SQuality_BAR(MS_U8 *u8_gSQValue);
270*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Demod_Get_Debug_Info_get_once(void);
271*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_Demod_Get_Debug_Info_polling(void);
272*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_WriteReg2bytes(MS_U16 u16Addr, MS_U16 u16Data);
273*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_ReadReg2bytes(MS_U16 u16Addr, MS_U16 *pu16Data);
274*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DTV_FrontendSetFreeze(void);
275*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DTV_FrontendUnFreeze(void);
276*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DTV_InnerSetFreeze(void);
277*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_DTV_InnerUnFreeze(void);
278*53ee8cc1Swenshuai.xi MS_BOOL INTERN_DVBS_PowerSaving (void);
279*53ee8cc1Swenshuai.xi 
280*53ee8cc1Swenshuai.xi #define INTERN_DVBS_LOAD_FW_FROM_CODE_MEMORY
281*53ee8cc1Swenshuai.xi 
282*53ee8cc1Swenshuai.xi #undef EXTSEL
283*53ee8cc1Swenshuai.xi #endif
284*53ee8cc1Swenshuai.xi 
285