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

📄 meta.h

📁 MTK 最新的flashtool工具的源代码
💻 H
📖 第 1 页 / 共 5 页
字号:
   short			max_arfcn;		// sub-band boundary of this PCL weighting area
   unsigned short   mid_level;		// PCLboundary level to apply high/low weighting
   unsigned short   hi_weight;		// scale factor of PCLs higher than mid_level
   unsigned short   low_weight;		// scale factor of PCLs lower than mid_level

} sARFCN_SECTION;

typedef  struct
{
   int				lowest_power;						// The lower apc power of the indicated band
   unsigned short	power[16];							// The mapping of power level to apc dac value
   sRAMPAREADATA	ramp[ PROFILE_NUM ];				// ramp profile
   sARFCN_SECTION	arfcn_weight[ ARFCN_SECTION_NUM ];	// profile of weighting power level by PCL and sub-band
   unsigned short	battery_compensate[3][3];			// [volt][temp] 
   short			tx_afc_offset;
} sRAMPDATA;

typedef struct
{
   int				lowest_power;						// The lower apc power of the indicated band
   unsigned short	power[16];							// The mapping of power level to apc dac value
   sRAMPAREADATA	ramp[ PROFILE_NUM ];				// ramp profile
   sARFCN_SECTION	arfcn_weight[ ARFCN_SECTION_NUM_Ex ];	// profile of weighting power level by PCL and sub-band
   unsigned short	battery_compensate[3][3];			// [volt][temp] 
   short			tx_afc_offset;
} sRAMPDATA_Ex;

typedef  struct
{
   int				lowest_power;						// The lower apc power of the indicated band
   unsigned short	power[16];							// The mapping of power level to apc dac value
   sRAMPAREADATA	ramp[ PROFILE_NUM ];				// ramp profile
   sARFCN_SECTION	arfcn_weight[ ARFCN_SECTION_NUM ];	// profile of weighting power level by PCL and sub-band
   unsigned short	battery_compensate[3][3];			// [volt][temp] 
   short			tx_afc_offset;
   unsigned char	vbias[16];
} sRAMPDATA_Ex2;

typedef struct
{
   sRAMPDATA          rampData;							// apc ramp profile of all bands
}l1cal_rampTable_T;

typedef struct
{
   sRAMPDATA_Ex          rampData;							// apc ramp profile of all bands
}l1cal_rampTable_T_Ex;

typedef struct
{
   sRAMPDATA_Ex2          rampData;							// apc ramp profile of all bands
}l1cal_rampTable_T_Ex2;

//-----------------------------------------------------//
//  TX Inter Ramping Table                             //
//-----------------------------------------------------//

// interRampData 
typedef struct {   
	unsigned char	interRampData[16];
} l1cal_interRampData_T;

// EPSK interRampData 
typedef struct {
	unsigned char	EPSK_interRampData[4][16];
} l1cal_EPSK_interRampData_T;

//-----------------------------------------------------//
//  3F RF compose/decompose table                      //
//-----------------------------------------------------//
#define  CAL_UARFCN_SECTION  15
#define  U_ARFCN_SECTION_NUM   15
#define  CAL_TEMP_SECTION     8
typedef  struct
{
   short  max_uarfcn;
    char   loss;
    char   gain_diff_HM;
    char   gain_diff_HL;
}  U_sAGCGAINOFFSET;

typedef  struct
{
    char   temp;   
   U_sAGCGAINOFFSET  gain_of_uarfcn[CAL_UARFCN_SECTION];   
}  U_sTEMPAGCOFFSET;

typedef  struct
{
   unsigned short  pa_dac;
   unsigned short  vga_dac[81];
} U_sTXPOWERDATA;

typedef  struct
{
   unsigned short start;
   unsigned short end;
} U_sHYSTERESISDATA;

typedef  struct
{
   unsigned char   point[2][16];
} U_sRAMPAREADATA;

typedef  struct
{
   short  max_uarfcn;
   unsigned short  mid_level;
   unsigned short  hi_weight;
   unsigned short  low_weight;
} U_sARFCN_SECTION;

typedef  struct
{
   U_sTXPOWERDATA  power_dac[3];  //0:PA high mode, 1:PA low mode
   U_sHYSTERESISDATA tx_hysteresis[2];
   U_sRAMPAREADATA   u_ramp;
   U_sARFCN_SECTION  u_arfcn_weight[ U_ARFCN_SECTION_NUM ];
   //kal_uint16  u_battery_compensate[3/*volt*/][3/*temp*/];
} U_sRAMPDATA;

//chliu provide
typedef struct
{
   unsigned char tempdacData[8];
}ul1cal_tempdacData_T; 

typedef struct
{
   U_sTEMPAGCOFFSET  pathlossData[CAL_TEMP_SECTION]; 
}ul1cal_pathlossData_T;

typedef struct
{
   U_sRAMPDATA txdacData; 
}ul1cal_txdacData_T;

/* end of chliu */

//-----------------------------------------------------//
//  RF Module Special Coef                             //
//-----------------------------------------------------//

//mt6140D
typedef struct{
   short		pcl_index;
   unsigned char pa_vbias1;   
}pa_vbias;

typedef struct {
   pa_vbias low_band_pa_vbias[8];
   pa_vbias high_band_pa_vbias[8];
}mt6140tx_pa_vbias;

typedef struct{  
      mt6140tx_pa_vbias data;
}mt6140tx;  
// Skyworks 
typedef struct {
	unsigned int		icorrection;
	unsigned int		qcorrection;
} RF_SKY74045_IP2_Coef;

typedef struct {
	RF_SKY74045_IP2_Coef	coef[5/*band*/];
} RF_SKY74045_RX_Coef;

typedef struct {
	RF_SKY74045_RX_Coef		rx;
} RF_SKY74045_Coef_T;

typedef struct {
	unsigned int			ipol;
	unsigned int			qpol;
} RF_SKY74117_IP2_Pol;

typedef struct {
	RF_SKY74045_IP2_Coef	coef[5/*band*/];
	RF_SKY74117_IP2_Pol		pol[5/*band*/];
} RF_SKY74117_RX_Coef;

typedef struct {
	RF_SKY74117_RX_Coef		rx;
} RF_SKY74117_Coef_T;

// MT6139B 
typedef struct {
	unsigned int		acode;
	unsigned int		amcode;
} RF_MT6139B_IP2_Coef;

typedef struct {  
	RF_MT6139B_IP2_Coef		coef[5/*band*/];
	unsigned int			rxamcalmode;
} RF_MT6139B_RX_Coef;

typedef struct {
	RF_MT6139B_RX_Coef		rx;
} RF_MT6139B_Coef_T;

// Bright5P 
typedef struct {
	unsigned int		word6_4_0;
	unsigned int		word6_5_0;
	unsigned int		word6_6_0;
	unsigned int		word6_7_0;
	unsigned int		bvmode;
	unsigned int		c3mode;
	unsigned int		wordC3;
} RF_BRIGHT5P_TX_Coef;

typedef struct {
	RF_BRIGHT5P_TX_Coef		tx;
} RF_BRIGHT5P_Coef_T;

//-----------------------------------------------------//
//  RF Testing: callback function definition           //
//-----------------------------------------------------//
typedef void (__stdcall *META_RF_PM_CNF)(const RfPm_Cnf *cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_AFC_CNF)(const RfAfc_Cnf *cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_NB_TX_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_CONT_RX_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_CONT_TX_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_SETBBTX_CFG_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_SELBAND_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_STOP_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_MULTISLOT_TX_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_SET_RAMPAPCLEVEL_CNF)(const unsigned char cnf, const short token, void *usrData);
typedef void (__stdcall *META_RF_SET_AFCDACVALUE_CNF)(const unsigned char cnf, const short token, void *usrData);

//-----------------------------------------------------//
//  RF Testing: exported function definition           //
//-----------------------------------------------------//
META_RESULT  __stdcall META_Rf_PM(const RfPm_Req *req, const META_RF_PM_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_PM_r(const int meta_handle, const RfPm_Req *req, const META_RF_PM_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_AFC(const RfAfc_Req *req, const META_RF_AFC_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_AFC_r(const int meta_handle, const RfAfc_Req *req, const META_RF_AFC_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_NB_TX(const RfNbtx_Req *req, const META_RF_NB_TX_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_NB_TX_r(const int meta_handle, const RfNbtx_Req *req, const META_RF_NB_TX_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_CONTINUE_RX(const RfCnRx_Req *req, const META_RF_CONT_RX_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_CONTINUE_RX_r(const int meta_handle, const RfCnRx_Req *req, const META_RF_CONT_RX_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_CONTINUE_TX(const RfCnTx_Req *req, const META_RF_CONT_TX_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_CONTINUE_TX_r(const int meta_handle, const RfCnTx_Req *req, const META_RF_CONT_TX_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SetBBTXCfg(const RfSetBBTXCfg_Req *req, const META_RF_SETBBTX_CFG_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SetBBTXCfg_r(const int meta_handle, const RfSetBBTXCfg_Req *req, const META_RF_SETBBTX_CFG_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SelectFrequencyBand1900(const unsigned char selectPCS1900, const META_RF_SELBAND_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SelectFrequencyBand1900_r(const int meta_handle, const unsigned char selectPCS1900, const META_RF_SELBAND_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_Stop(const META_RF_STOP_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_Stop_r(const int meta_handle, const META_RF_STOP_CNF cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_MultiSlot_TX(const RfMultiSlotTX_Req *req, const META_RF_MULTISLOT_TX_CNF  cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_MultiSlot_TX_r(const int meta_handle, const RfMultiSlotTX_Req *req, const META_RF_MULTISLOT_TX_CNF  cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SetAfcDacValue(const RfSetAfcDacValue_Req *req, const META_RF_SET_AFCDACVALUE_CNF  cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SetAfcDacValue_r(const int meta_handle, const RfSetAfcDacValue_Req *req, const META_RF_SET_AFCDACVALUE_CNF  cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SetBBTxCfg2(unsigned int ms_timeout, const RfBBTXCfg2  *tx_cfg_req, RfBBTXCfg2  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_SetBBTxCfg2_r(const int meta_handle, unsigned int ms_timeout, const RfBBTXCfg2  *tx_cfg_req, RfBBTXCfg2  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_GetBBTxCfg2(unsigned int ms_timeout, RfBBTXCfg2  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_GetBBTxCfg2_r(const int meta_handle, unsigned int ms_timeout, RfBBTXCfg2  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_SetCrystalCapId(unsigned int ms_timeout, const RfSetCrystalCfg_Req  *req);
META_RESULT  __stdcall META_Rf_SetCrystalCapId_r(const int meta_handle, unsigned int ms_timeout, const RfSetCrystalCfg_Req  *req);
META_RESULT  __stdcall META_Rf_BBTXAutoCal(unsigned int ms_timeout);
META_RESULT  __stdcall META_Rf_BBTXAutoCal_r(const int meta_handle, unsigned int ms_timeout);
META_RESULT  __stdcall META_Rf_QueryMSCapability(unsigned int ms_timeout, RfMsCapability_S  *p_type);
META_RESULT  __stdcall META_Rf_QueryMSCapability_r(const int meta_handle, unsigned int ms_timeout, RfMsCapability_S  *p_type);
META_RESULT  __stdcall META_Rf_QueryMSCapabilityEx(unsigned int ms_timeout, RfMsCapabilityEx_S  *p_ms_cap);
META_RESULT  __stdcall META_Rf_QueryMSCapabilityEx_r(const int meta_handle, unsigned int ms_timeout, RfMsCapabilityEx_S  *p_ms_cap);
META_RESULT  __stdcall META_Rf_SetAfcSinWaveDetection(unsigned int ms_timeout, AFC_SINWAVE_DETECTION_E  bIsAfcSinWaveOn);
META_RESULT  __stdcall META_Rf_SetAfcSinWaveDetection_r(const int meta_handle, unsigned int ms_timeout, AFC_SINWAVE_DETECTION_E  bIsAfcSinWaveOn);
META_RESULT  __stdcall META_Rf_QueryIfTwoApcDCOffsetSupport(unsigned int ms_timeout);
META_RESULT  __stdcall META_Rf_QueryIfTwoApcDCOffsetSupport_r(const int meta_handle, unsigned int ms_timeout);
META_RESULT  __stdcall META_Rf_MultiSlot_TX_Ex(unsigned int ms_timeout, const Rf_MultiSlotTXEx_Req *req);
META_RESULT  __stdcall META_Rf_MultiSlot_TX_Ex_r(const int meta_handle, unsigned int ms_timeout, const Rf_MultiSlotTXEx_Req *req);
META_RESULT  __stdcall META_Rf_GetRFID(unsigned int ms_timeout, RFMod_ID *cnf);
META_RESULT  __stdcall META_Rf_GetRFID_r(const int meta_handle, unsigned int ms_timeout, RFMod_ID *cnf);
META_RESULT  __stdcall META_Rf_CONTINUE_TX_Ex(unsigned int ms_timeout, const RfCnTxEx_Req *req);
META_RESULT  __stdcall META_Rf_CONTINUE_TX_Ex_r(const int meta_handle, unsigned int ms_timeout, const RfCnTxEx_Req *req);
META_RESULT  __stdcall META_Rf_SetBBTxCfg3(unsigned int ms_timeout, const RfBBTXCfg3  *tx_cfg_req, RfBBTXCfg3  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_SetBBTxCfg3_r(const int meta_handle, unsigned int ms_timeout, const RfBBTXCfg3  *tx_cfg_req, RfBBTXCfg3  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_GetBBTxCfg3(unsigned int ms_timeout, RfBBTXCfg3  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_GetBBTxCfg3_r(const int meta_handle, unsigned int ms_timeout, RfBBTXCfg3  *tx_cfg_cnf);
META_RESULT  __stdcall META_Rf_CONTINUE_TX_Ex2(unsigned int ms_timeout, const RfCnTxEx2_Req *req);
META_RESULT  __stdcall META_Rf_CONTINUE_TX_Ex2_r(const int meta_handle, unsigned int ms_timeout, const RfCnTxEx2_Req *req);
META_RESULT  __stdcall META_Rf_GetAfcDacValueAtRTXOffsetCal(unsigned int ms_timeout, RfGetAfcDacValueAtRTXOffsetCal *cnf);
META_RESULT  __stdcall META_Rf_GetAfcDacValueAtRTXOffsetCal_r(const int meta_handle, unsigned int ms_timeout, RfGetAfcDacValueAtRTXOffsetCal *cnf);
//-----------------------------------------------------//
//  RunTime Setting Functions Without Update NVRAM     //
//-----------------------------------------------------//
META_RESULT  __stdcall META_Rf_SetRampTable(unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T  *ramp);
META_RESULT  __stdcall META_Rf_SetRampTable_r(const int meta_handle, unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T  *ramp);
META_RESULT  __stdcall META_Rf_SetRampApcLevel(const RfSetRampApcLevel_Req *req, const META_RF_SET_RAMPAPCLEVEL_CNF  cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_SetRampApcLevel_r(const int meta_handle, const RfSetRampApcLevel_Req *req, const META_RF_SET_RAMPAPCLEVEL_CNF  cb, short *token, void *usrData);
META_RESULT  __stdcall META_Rf_EPSK_SetRampTable(unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T  *ramp);
META_RESULT  __stdcall META_Rf_EPSK_SetRampTable_r(const int meta_handle, unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T  *ramp);
META_RESULT  __stdcall META_Rf_EPSK_SetRampApcLevel(unsigned int ms_timeout, const RfSetRampApcLevel_Req *req);
META_RESULT  __stdcall META_Rf_EPSK_SetRampApcLevel_r(const int meta_handle, unsigned int ms_timeout, const RfSetRampApcLevel_Req *req);
META_RESULT  __stdcall META_Rf_SetRFImmediateBSI(unsigned int ms_timeout, const unsigned int bsi_data);
META_RESULT  __stdcall META_Rf_SetRFImmediateBSI_r(const int meta_handle, unsigned int ms_timeout, const unsigned int bsi_data);
META_RESULT  __stdcall META_Rf_GetRFImmediateBSI(unsigned int ms_timeout, unsigned int bsi_addr, unsigned int *p_bsi_data);
META_RESULT  __stdcall META_Rf_GetRFImmediateBSI_r(const int meta_handle, unsigned int ms_timeout, unsigned int bsi_addr, unsigned int *p_bsi_data);

META_RESULT  __stdcall META_Rf_SetRampTable_Ex(unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T_Ex  *ramp);
META_RESULT  __stdcall META_Rf_SetRampTable_Ex_r(const int meta_handle, unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T_Ex  *ramp);
META_RESULT  __stdcall META_Rf_SetRampTable_Ex2(unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T_Ex2  *ramp);
META_RESULT  __stdcall META_Rf_SetRampTable_Ex2_r(const int meta_handle, unsigned int ms_timeout, FrequencyBand  band, const l1cal_rampTable_T_Ex2  *ramp);
// Skyworks 
META_RESULT  __stdcall META_Rf_SKY74045_SetSpecialCoef(unsigned int ms_timeout, const RF_SKY74045_Coef_T *rf_mod_coef);
META_RESULT  __stdcall META_Rf_SKY74045_SetSpecialCoef_r(con

⌨️ 快捷键说明

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