⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tuner.h

📁 这是DVB tuner驱动部分和其它相关的源码和一些技术资料文档.
💻 H
字号:
/*****************************************************************************File Name   : tuner.hDescription : Core Tuner API.Copyright (C) 1999 STMicroelectronicsReference   :*****************************************************************************//* Define to prevent recursive inclusion */#ifndef __TUNER_H#define __TUNER_H/* Includes --------------------------------------------------------------- */#include "sttuner.h"#include "stevt.h"/* Exported Constants ----------------------------------------------------- */#define TUNER_NO_ERROR              ST_NO_ERROR#define TUNER_ERROR_BAD_PARAMETER   ST_ERROR_BAD_PARAMETER#define TUNER_ERROR_NO_MEMORY       ST_ERROR_NO_MEMORY/* Exported Variables ----------------------------------------------------- *//* Exported Types --------------------------------------------------------- *//* Errors specific to the Core Tuner API */typedef U32 TUNER_ErrorCode_t;#define SCAN_TASK_STACK_SIZE        (4 * 1024)/* Scan Task Information */typedef struct{    task_t                  ScanTask;    tdesc_t                 ScanTaskDescriptor;    U8                      ScanTaskStack[SCAN_TASK_STACK_SIZE];    semaphore_t             GuardSemaphore;    semaphore_t             TimeoutSemaphore;    U32                     TimeoutDelayMs;    BOOL                    DeleteTask;} TUNER_ScanTask_t;/* Scan information */typedef struct{    STTUNER_Scan_t          *Scan_p;    STTUNER_Status_t        *Status_p;    U32                     ScanIndex;    U32                     FrequencyStart;    U32                     FrequencyEnd;    S32                     FrequencyStep;    S32                     ScanDirection;    U32                     FrequencyLO;    U32                     NextFrequency;    U32                     LockCount;    U32                     PlrMask;} TUNER_ScanInfo_t;/* Tuner control block */typedef struct{    /* API Data */    ST_DeviceName_t         DeviceName;    STTUNER_Handle_t        Handle;    STI2C_Handle_t          I2CDemodHandle;    STI2C_Handle_t          I2CTunerHandle;    STTUNER_InitParams_t    InitParams;    STTUNER_OpenParams_t    OpenParams;    STTUNER_Capability_t    Capability;    STTUNER_TunerInfo_t     TunerInfo;    STTUNER_ScanList_t      ScanList;    STTUNER_BandList_t      BandList;    STTUNER_ThresholdList_t ThresholdList;    U32                     *ThresholdHits;    STTUNER_TunerInfo_t     CurrentTunerInfo;    STTUNER_Scan_t          SingleScan;    STTUNER_QualityFormat_t QualityFormat;    /* Private data */    TUNER_ScanTask_t        ScanTask;    TUNER_ScanInfo_t        ScanInfo;    TNR_Handle_t            TunerHandle;    SAT_Handle_t            SatHandle;    SAT_Capability_t        SatCapability;    DEMOD_Handle_t          DemodHandle;    DEMOD_Capability_t      DEMODCapability;    U32                     LastThreshold;    U32                     LastSignal;    U32                     Timeout;    BOOL                    ScanExact;    U32                     SymbolWidthMin;    U32                     PolarizationMask;    U32                     FECRates;    STEVT_Handle_t          EVTHandle;    STEVT_EventID_t         EvtId[STTUNER_NUMBER_EVENTS];#ifdef STTUNER_DEBUG    U32                     BusErrorCount;#endif} TUNER_ControlBlock_t;/* Exported Macros -------------------------------------------------------- *//* Macro that converts an STTUNER event to an offset in the EvtId[] array * stored in the tuner control block. */#define EventToId(x)        (x-STTUNER_EV_LOCKED)/* Exported Functions ----------------------------------------------------- *//* The main tuner API is represented by functions of the form TUNER_XyzAbc().   Subsets of the API come in the form of:   TNR_XyzAbc() -- tuner device   SAT_XyzAbc() -- sat/lnb control device   DEMON_XyzAbc()  -- management/demodulator device*/TUNER_ErrorCode_t TUNER_Init(TUNER_ControlBlock_t *Tuner_p,                             STTUNER_InitParams_t *InitParams_p);TUNER_ErrorCode_t TUNER_Term(TUNER_ControlBlock_t *Tuner_p);TUNER_ErrorCode_t TUNER_AbortScan(TUNER_ControlBlock_t *Tuner_p);TUNER_ErrorCode_t TUNER_StartScan(TUNER_ControlBlock_t *Tuner_p);TUNER_ErrorCode_t TUNER_ContinueScan(TUNER_ControlBlock_t *Tuner_p);TUNER_ErrorCode_t TUNER_SetFrequency(TUNER_ControlBlock_t *Tuner_p);#endif /* __TUNER_H *//* End of tuner.h */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -