META_factory_cfg_storage.cpp
上传用户:gelin96
上传日期:2017-01-08
资源大小:20993k
文件大小:53k
源码类别:
MTK
开发平台:
C++ Builder
- /*****************************************************************************
- * Copyright Statement:
- * --------------------
- * This software is protected by Copyright and the information contained
- * herein is confidential. The software may not be copied and the information
- * contained herein may not be used or disclosed except with the written
- * permission of MediaTek Inc. (C) 2005
- *
- * BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES
- * THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE")
- * RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON
- * AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.
- * NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE
- * SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR
- * SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH
- * THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO
- * NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S
- * SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM.
- *
- * BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE
- * LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE,
- * AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE,
- * OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO
- * MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE.
- *
- * THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE
- * WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF
- * LAWS PRINCIPLES. ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND
- * RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER
- * THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC).
- *
- *****************************************************************************/
- /*****************************************************************************
- *
- * Filename:
- * ---------
- * META_Factory_cfg_storage.cpp
- *
- * Project:
- * --------
- * Maui META APP
- *
- * Description:
- * ------------
- * META factory configuration storage source
- *
- * Author:
- * -------
- * Andy Ueng (mtk00490)
- *
- *============================================================================
- * HISTORY
- * Below this line, this part is controlled by PVCS VM. DO NOT MODIFY!!
- *------------------------------------------------------------------------------
- * $Revision$
- * $Modtime$
- * $Log$
- *
- *------------------------------------------------------------------------------
- * Upper this line, this part is controlled by PVCS VM. DO NOT MODIFY!!
- *============================================================================
- ****************************************************************************/
- #include <vcl.h>
- #include <inifiles.hpp>
- #include <stdio.h>
- #pragma hdrstop
- #include "META_factory_cfg_storage.h"
- TMETA_factory_cfg_storage *META_factory_cfg_storage;
- //----------------------------------------------------------------------------
- __fastcall TMETA_factory_cfg_storage::TMETA_factory_cfg_storage()
- {
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::getGPIB_Addr(AnsiString &as)
- {
- as = as_8960_GPIB_Addr;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGPIB_Addr(AnsiString as)
- {
- as_8960_GPIB_Addr = as;
- return true;
- }
- //=============================================================================
- int TMETA_factory_cfg_storage::getTimeOut()
- {
- return i_TimeOut;
- }
- //-----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setTimeOut(int i)
- {
- i_TimeOut = i;
- return true;
- }
- //-----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setTimeOut(AnsiString as)
- {
- i_TimeOut = as.ToInt();
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getFreqBank(AnsiString &as)
- {
- as = as_FreqBank;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setFreqBank(AnsiString as)
- {
- as_FreqBank = as;
- return true;
- }
- //=============================================================================
- short TMETA_factory_cfg_storage::getARFCN_C0_GSM850()
- {
- return m_sARFCN_C0_GSM850;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_GSM850(short s)
- {
- m_sARFCN_C0_GSM850 = s;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_GSM850(AnsiString as)
- {
- m_sARFCN_C0_GSM850 = as.ToInt();
- return true;
- }
- //=============================================================================
- short TMETA_factory_cfg_storage::getARFCN_C0_GSM()
- {
- return m_sARFCN_C0_GSM;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_GSM(short s)
- {
- m_sARFCN_C0_GSM = s;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_GSM(AnsiString as)
- {
- m_sARFCN_C0_GSM = as.ToInt();
- return true;
- }
- //=============================================================================
- short TMETA_factory_cfg_storage::getARFCN_C0_DCS()
- {
- return m_sARFCN_C0_DCS;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_DCS(short s)
- {
- m_sARFCN_C0_DCS = s;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_DCS(AnsiString as)
- {
- m_sARFCN_C0_DCS = as.ToInt();
- return true;
- }
- //=============================================================================
- short TMETA_factory_cfg_storage::getARFCN_C0_PCS()
- {
- return m_sARFCN_C0_PCS;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_PCS(short s)
- {
- m_sARFCN_C0_PCS = s;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setARFCN_C0_PCS(AnsiString as)
- {
- m_sARFCN_C0_PCS = as.ToInt();
- return true;
- }
- //=============================================================================
- int TMETA_factory_cfg_storage::getP_DL()
- {
- return d_P_DL;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setP_DL(double d)
- {
- d_P_DL = d;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setP_DL(AnsiString as)
- {
- d_P_DL = atof(as.c_str());
- return true;
- }
- //=============================================================================
- short TMETA_factory_cfg_storage::getN_PM()
- {
- return i_N_PM;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setN_PM(short i)
- {
- i_N_PM = i;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setN_PM(AnsiString as)
- {
- i_N_PM = as.ToInt();
- return true;
- }
- //=============================================================================
- char TMETA_factory_cfg_storage::getM_PM()
- {
- return c_M_PM;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setM_PM(char c)
- {
- c_M_PM = c;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setM_PM(AnsiString as)
- {
- c_M_PM = as.ToInt();
- return true;
- }
- //=============================================================================
- short TMETA_factory_cfg_storage::getN_AFC()
- {
- return m_sN_AFC;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setN_AFC(int i)
- {
- i_N_AFC = i;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setN_AFC(AnsiString as)
- {
- i_N_AFC = as.ToInt();
- return true;
- }
- //=============================================================================
- int TMETA_factory_cfg_storage::getDCA1()
- {
- return i_DAC1;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCA1(int i)
- {
- i_DAC1 = i;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCA1(AnsiString as)
- {
- i_DAC1 = as.ToInt();
- return true;
- }
- //=============================================================================
- int TMETA_factory_cfg_storage::getDAC2()
- {
- return i_DAC2;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDAC2(int i)
- {
- i_DAC2 = i;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDAC2(AnsiString as)
- {
- i_DAC2 = as.ToInt();
- return true;
- }
- // ***************************** GSM 850 *************************************
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_CAL_PCL(AnsiString &as)
- {
- as = as_GSM850_CAL_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_CAL_PCL(AnsiString as)
- {
- as_GSM850_CAL_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_PCL(AnsiString &as)
- {
- as = as_GSM850_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_PCL(AnsiString as)
- {
- as_GSM850_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_CHECK_PCL(AnsiString &as)
- {
- as = as_GSM850_CHECK_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_CHECK_PCL(AnsiString as)
- {
- as_GSM850_CHECK_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_MAX_P(AnsiString &as)
- {
- as = as_GSM850_MAX_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_MAX_P(AnsiString as)
- {
- as_GSM850_MAX_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_WANTED_P(AnsiString &as)
- {
- as = as_GSM850_WANTED_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_WANTED_P(AnsiString as)
- {
- as_GSM850_WANTED_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_MIN_P(AnsiString &as)
- {
- as = as_GSM850_MIN_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_MIN_P(AnsiString as)
- {
- as_GSM850_MIN_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_C(AnsiString &as)
- {
- as = as_GSM850_C;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_C(AnsiString as)
- {
- as_GSM850_C = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_MAX_RX_LOSS(AnsiString &as)
- {
- as = as_GSM850_MAX_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_MAX_RX_LOSS(AnsiString as)
- {
- as_GSM850_MAX_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_MIN_RX_LOSS(AnsiString &as)
- {
- as = as_GSM850_MIN_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_MIN_RX_LOSS(AnsiString as)
- {
- as_GSM850_MIN_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM850_CORRECTION(AnsiString &as)
- {
- as = as_GSM850_CORRECTION;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM850_CORRECTION(AnsiString as)
- {
- as_GSM850_CORRECTION = as;
- return true;
- }
- // ****************************************************************************
- // ***************************** GSM 900 *************************************
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_CAL_PCL(AnsiString &as)
- {
- as = as_GSM900_CAL_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_CAL_PCL(AnsiString as)
- {
- as_GSM900_CAL_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_PCL(AnsiString &as)
- {
- as = as_GSM900_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_PCL(AnsiString as)
- {
- as_GSM900_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_CHECK_PCL(AnsiString &as)
- {
- as = as_GSM900_CHECK_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_CHECK_PCL(AnsiString as)
- {
- as_GSM900_CHECK_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_MAX_P(AnsiString &as)
- {
- as = as_GSM900_MAX_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_MAX_P(AnsiString as)
- {
- as_GSM900_MAX_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_WANTED_P(AnsiString &as)
- {
- as = as_GSM900_WANTED_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_WANTED_P(AnsiString as)
- {
- as_GSM900_WANTED_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_MIN_P(AnsiString &as)
- {
- as = as_GSM900_MIN_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_MIN_P(AnsiString as)
- {
- as_GSM900_MIN_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_C(AnsiString &as)
- {
- as = as_GSM900_C;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_C(AnsiString as)
- {
- as_GSM900_C = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_MAX_RX_LOSS(AnsiString &as)
- {
- as = as_GSM900_MAX_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_MAX_RX_LOSS(AnsiString as)
- {
- as_GSM900_MAX_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_MIN_RX_LOSS(AnsiString &as)
- {
- as = as_GSM900_MIN_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_MIN_RX_LOSS(AnsiString as)
- {
- as_GSM900_MIN_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getGSM900_CORRECTION(AnsiString &as)
- {
- as = as_GSM900_CORRECTION;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setGSM900_CORRECTION(AnsiString as)
- {
- as_GSM900_CORRECTION = as;
- return true;
- }
- // ****************************************************************************
- // ***************************** DCS 1800 ************************************
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_PCL(AnsiString &as)
- {
- as = as_DCS1800_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_PCL(AnsiString as)
- {
- as_DCS1800_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_CHECK_PCL(AnsiString &as)
- {
- as = as_DCS1800_CHECK_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_CHECK_PCL(AnsiString as)
- {
- as_DCS1800_CHECK_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_MAX_P(AnsiString &as)
- {
- as = as_DCS1800_MAX_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_MAX_P(AnsiString as)
- {
- as_DCS1800_MAX_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_WANTED_P(AnsiString &as)
- {
- as = as_DCS1800_WANTED_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_WANTED_P(AnsiString as)
- {
- as_DCS1800_WANTED_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_MIN_P(AnsiString &as)
- {
- as = as_DCS1800_MIN_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_MIN_P(AnsiString as)
- {
- as_DCS1800_MIN_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_C(AnsiString &as)
- {
- as = as_DCS1800_C;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_C(AnsiString as)
- {
- as_DCS1800_C = as;
- return true;
- }
- //=============================================================================
- // added by Andy Ueng
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_MAX_RX_LOSS(AnsiString &as)
- {
- as = as_DCS1800_MAX_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_MAX_RX_LOSS(AnsiString as)
- {
- as_DCS1800_MAX_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_MIN_RX_LOSS(AnsiString &as)
- {
- as = as_DCS1800_MIN_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_MIN_RX_LOSS(AnsiString as)
- {
- as_DCS1800_MIN_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getDCS1800_CORRECTION(AnsiString &as)
- {
- as = as_DCS1800_CORRECTION;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setDCS1800_CORRECTION(AnsiString as)
- {
- as_DCS1800_CORRECTION = as;
- return true;
- }
- // end of added
- // ***************************** DCS 1800 end ********************************
- // ***************************** PCS 1900 begin ******************************
- //=============================================================================
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_PCL(AnsiString &as)
- {
- as = as_PCS1900_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_PCL(AnsiString as)
- {
- as_PCS1900_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_CHECK_PCL(AnsiString &as)
- {
- as = as_PCS1900_CHECK_PCL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_CHECK_PCL(AnsiString as)
- {
- as_PCS1900_CHECK_PCL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_MAX_P(AnsiString &as)
- {
- as = as_PCS1900_MAX_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_MAX_P(AnsiString as)
- {
- as_PCS1900_MAX_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_WANTED_P(AnsiString &as)
- {
- as = as_PCS1900_WANTED_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_WANTED_P(AnsiString as)
- {
- as_PCS1900_WANTED_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_MIN_P(AnsiString &as)
- {
- as = as_PCS1900_MIN_P;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_MIN_P(AnsiString as)
- {
- as_PCS1900_MIN_P = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_C(AnsiString &as)
- {
- as = as_PCS1900_C;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_C(AnsiString as)
- {
- as_PCS1900_C = as;
- return true;
- }
- //=============================================================================
- // added by Andy Ueng
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_MAX_RX_LOSS(AnsiString &as)
- {
- as = as_PCS1900_MAX_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_MAX_RX_LOSS(AnsiString as)
- {
- as_PCS1900_MAX_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_MIN_RX_LOSS(AnsiString &as)
- {
- as = as_PCS1900_MIN_RX_LOSS;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_MIN_RX_LOSS(AnsiString as)
- {
- as_PCS1900_MIN_RX_LOSS = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getPCS1900_CORRECTION(AnsiString &as)
- {
- as = as_PCS1900_CORRECTION;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setPCS1900_CORRECTION(AnsiString as)
- {
- as_PCS1900_CORRECTION = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MAX_INIT_AFC_DAC(int &i)
- {
- i = i_MAX_INIT_AFC_DAC;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MAX_INIT_AFC_DAC(int i)
- {
- i_MAX_INIT_AFC_DAC = i;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MIN_INIT_AFC_DAC(int &i)
- {
- i = i_MIN_INIT_AFC_DAC;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MIN_INIT_AFC_DAC(int i)
- {
- i_MIN_INIT_AFC_DAC = i;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MAX_AFC_SLOPE(double &d)
- {
- d = d_MAX_AFC_SLOPE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MAX_AFC_SLOPE(double d)
- {
- d_MAX_AFC_SLOPE = d;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MIN_AFC_SLOPE(double &d)
- {
- d = d_MIN_AFC_SLOPE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MIN_AFC_SLOPE(double d)
- {
- d_MIN_AFC_SLOPE = d;
- return true;
- }
- // end of added
- // ***************************** PCS 1900 end ********************************
- signed char TMETA_factory_cfg_storage::getBSIC()
- {
- return sc_BSIC;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setBSIC(signed char sc)
- {
- sc_BSIC = sc;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setBSIC(AnsiString as)
- {
- sc_BSIC = as.ToInt();
- return true;
- }
- // added by Andy Ueng
- //=============================================================================
- // bool TMETA_factory_cfg_storage::get_FACTORY_ID(AnsiString &as)
- // {
- // as = as_FACTORY_ID;
- // return true;
- // }
- //----------------------------------------------------------------------------
- // bool TMETA_factory_cfg_storage::set_FACTORY_ID(AnsiString as)
- // {
- // as_FACTORY_ID = as;
- // return true;
- // }
- // end of added
- // added by Andy Ueng for ADC calibration
- //=============================================================================
- bool TMETA_factory_cfg_storage::get663x2_GPIB_Addr(AnsiString &as)
- {
- as = as_663x2_GPIB_Addr;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set663x2_GPIB_Addr(AnsiString as)
- {
- as_663x2_GPIB_Addr = as;
- return true;
- }
- bool TMETA_factory_cfg_storage::getADC_V1(AnsiString &as)
- {
- as = as_ADC_V1;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setADC_V1(AnsiString as)
- {
- as_ADC_V1 = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getADC_V2(AnsiString &as)
- {
- as = as_ADC_V2;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setADC_V2(AnsiString as)
- {
- as_ADC_V2 = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::getADC_CHECK_VOLTAGE(AnsiString &as)
- {
- as = as_ADC_CHECK_VOLTAGE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::setADC_CHECK_VOLTAGE(AnsiString as)
- {
- as_ADC_CHECK_VOLTAGE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_NORMAL_VOLTAGE(AnsiString &as)
- {
- as = as_NORMAL_VOLTAGE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_NORMAL_VOLTAGE(AnsiString as)
- {
- as_NORMAL_VOLTAGE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MAX_BATTERY_ADC_SLOPE(AnsiString &as)
- {
- as = as_MAX_BATTERY_ADC_SLOPE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MAX_BATTERY_ADC_SLOPE(AnsiString as)
- {
- as_MAX_BATTERY_ADC_SLOPE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MIN_BATTERY_ADC_SLOPE(AnsiString &as)
- {
- as = as_MIN_BATTERY_ADC_SLOPE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MIN_BATTERY_ADC_SLOPE(AnsiString as)
- {
- as_MIN_BATTERY_ADC_SLOPE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MAX_BATTERY_ADC_OFFSET(AnsiString &as)
- {
- as = as_MAX_BATTERY_ADC_OFFSET;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MAX_BATTERY_ADC_OFFSET(AnsiString as)
- {
- as_MAX_BATTERY_ADC_OFFSET = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MIN_BATTERY_ADC_OFFSET(AnsiString &as)
- {
- as = as_MIN_BATTERY_ADC_OFFSET;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MIN_BATTERY_ADC_OFFSET(AnsiString as)
- {
- as_MIN_BATTERY_ADC_OFFSET = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_BATTERY_CHANNEL(AnsiString &as)
- {
- as = as_BATTERY_CHANNEL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_BATTERY_CHANNEL(AnsiString as)
- {
- as_BATTERY_CHANNEL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_CHARGER_CHANNEL(AnsiString &as)
- {
- as = as_CHARGER_CHANNEL;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_CHARGER_CHANNEL(AnsiString as)
- {
- as_CHARGER_CHANNEL = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_ADC_RESISTANCE(AnsiString &as)
- {
- as = as_ADC_RESISTANCE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_ADC_RESISTANCE(AnsiString as)
- {
- as_ADC_RESISTANCE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MAX_VOLTAGE_DIFFERENCE(AnsiString &as)
- {
- as = as_MAX_VOLTAGE_DIFFERENCE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MAX_VOLTAGE_DIFFERENCE(AnsiString as)
- {
- as_MAX_VOLTAGE_DIFFERENCE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_MAX_CURRENT_DIFFERENCE(AnsiString &as)
- {
- as = as_MAX_CURRENT_DIFFERENCE;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_MAX_CURRENT_DIFFERENCE(AnsiString as)
- {
- as_MAX_CURRENT_DIFFERENCE = as;
- return true;
- }
- //=============================================================================
- bool TMETA_factory_cfg_storage::get_ADC_MEASUREMENT_COUNT(AnsiString &as)
- {
- as = as_ADC_MEASUREMENT_COUNT;
- return true;
- }
- //----------------------------------------------------------------------------
- bool TMETA_factory_cfg_storage::set_ADC_MEASUREMENT_COUNT(AnsiString as)
- {
- as_ADC_MEASUREMENT_COUNT = as;
- return true;
- }
- //=============================================================================
- void TMETA_factory_cfg_storage::ReadFromIniFile(AnsiString as)
- {
- TIniFile *ini;
- ini = new TIniFile( as );
- if(ini != NULL)
- {
- setGPIB_Addr( ini->ReadString("8960 Initialization",
- "8960 GPIB Address",
- "GPIB0::15::INSTR"
- ));
- setTimeOut( ini->ReadString("8960 Initialization",
- "Time Out",
- "10000"
- ));
- setFreqBank( ini->ReadString("Frequency Bank",
- "bank",
- "0x0C"
- ));
- setARFCN_C0_GSM850( ini->ReadInteger("C0 for each Bank",
- "arfcn_C0_GSM850",
- 190
- ));
- setARFCN_C0_GSM( ini->ReadInteger("C0 for each Bank",
- "arfcn_C0_GSM",
- 60
- ));
- setARFCN_C0_DCS( ini->ReadInteger("C0 for each Bank",
- "arfcn_C0_DCS",
- 750
- ));
- setARFCN_C0_PCS( ini->ReadInteger("C0 for each Bank",
- "arfcn_C0_PCS",
- 660
- ));
- setP_DL( ini->ReadInteger("Downlink power",
- "P_DL",
- -80
- ));
- setN_PM( ini->ReadInteger("RX measurement samples",
- "N_PM",
- 5
- ));
- setM_PM( ini->ReadInteger("RX measurement samples",
- "M_PM",
- 4
- ));
- setN_AFC( ini->ReadInteger("AFC Calibration",
- "N_AFC",
- 5
- ));
- setDCA1( ini->ReadInteger("AFC Calibration",
- "DAC1",
- 3000
- ));
- setDAC2( ini->ReadInteger("AFC Calibration",
- "DAC2",
- 4000
- ));
- // GSM850
- setGSM850_CAL_PCL( ini->ReadString("TX PCL table",
- "GSM850_CAL_PCL",
- "0"
- ));
- setGSM850_PCL( ini->ReadString("TX PCL table",
- "GSM850_PCL",
- "0"
- ));
- setGSM850_CHECK_PCL( ini->ReadString("TX PCL table",
- "GSM850_CHECK_PCL",
- "0"
- ));
- setGSM850_MAX_P( ini->ReadString("TX PCL table",
- "GSM850_MAX_P",
- "0"
- ));
- setGSM850_WANTED_P( ini->ReadString("TX PCL table",
- "GSM850_WANTED_P",
- "0"
- ));
- setGSM850_MIN_P( ini->ReadString("TX PCL table",
- "GSM850_MIN_P",
- "0"
- ));
- setGSM850_C( ini->ReadString("TX PCL table",
- "GSM850_C",
- "0"
- ));
- setGSM850_MAX_RX_LOSS( ini->ReadString("RX path loss table",
- "GSM850_MAX_RX_LOSS",
- "0"
- ));
- setGSM850_MIN_RX_LOSS( ini->ReadString("RX path loss table",
- "GSM850_MIN_RX_LOSS",
- "0"
- ));
- setGSM850_CORRECTION( ini->ReadString("TX PCL table",
- "GSM850_CORRECTION",
- "0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"
- ));
- // GSM900
- setGSM900_CAL_PCL( ini->ReadString("TX PCL table",
- "GSM900_CAL_PCL",
- "0"
- ));
- setGSM900_PCL( ini->ReadString("TX PCL table",
- "GSM900_PCL",
- "0"
- ));
- setGSM900_CHECK_PCL( ini->ReadString("TX PCL table",
- "GSM900_CHECK_PCL",
- "0"
- ));
- setGSM900_MAX_P( ini->ReadString("TX PCL table",
- "GSM900_MAX_P",
- "0"
- ));
- setGSM900_WANTED_P( ini->ReadString("TX PCL table",
- "GSM900_WANTED_P",
- "0"
- ));
- setGSM900_MIN_P( ini->ReadString("TX PCL table",
- "GSM900_MIN_P",
- "0"
- ));
- setGSM900_C( ini->ReadString("TX PCL table",
- "GSM900_C",
- "0"
- ));
- setGSM900_MAX_RX_LOSS( ini->ReadString("RX path loss table",
- "GSM900_MAX_RX_LOSS",
- "0"
- ));
- setGSM900_MIN_RX_LOSS( ini->ReadString("RX path loss table",
- "GSM900_MIN_RX_LOSS",
- "0"
- ));
- setGSM900_CORRECTION( ini->ReadString("TX PCL table",
- "GSM900_CORRECTION",
- "0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"
- ));
- // DCS1800
- setDCS1800_CAL_PCL( ini->ReadString("TX PCL table",
- "DCS1800_CAL_PCL",
- "0"
- ));
- setDCS1800_PCL( ini->ReadString("TX PCL table",
- "DCS1800_PCL",
- "0"
- ));
- setDCS1800_CHECK_PCL( ini->ReadString("TX PCL table",
- "DCS1800_CHECK_PCL",
- "0"
- ));
- setDCS1800_MAX_P( ini->ReadString("TX PCL table",
- "DCS1800_MAX_P",
- "0"
- ));
- setDCS1800_WANTED_P( ini->ReadString("TX PCL table",
- "DCS1800_WANTED_P",
- "0"
- ));
- setDCS1800_MIN_P( ini->ReadString("TX PCL table",
- "DCS1800_MIN_P",
- "0"
- ));
- setDCS1800_C( ini->ReadString("TX PCL table",
- "DCS1800_C",
- "0"
- ));
- setDCS1800_MAX_RX_LOSS( ini->ReadString("RX path loss table",
- "DCS1800_MAX_RX_LOSS",
- "0"
- ));
- setDCS1800_MIN_RX_LOSS( ini->ReadString("RX path loss table",
- "DCS1800_MIN_RX_LOSS",
- "0"
- ));
- setDCS1800_CORRECTION( ini->ReadString("TX PCL table",
- "DCS1800_CORRECTION",
- "0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"
- ));
- // PCS1900
- setPCS1900_CAL_PCL( ini->ReadString("TX PCL table",
- "PCS1900_CAL_PCL",
- "0"
- ));
- setPCS1900_PCL( ini->ReadString("TX PCL table",
- "PCS1900_PCL",
- "0"
- ));
- setPCS1900_MAX_P( ini->ReadString("TX PCL table",
- "PCS1900_MAX_P",
- "0"
- ));
- setPCS1900_WANTED_P( ini->ReadString("TX PCL table",
- "PCS1900_WANTED_P",
- "0"
- ));
- setPCS1900_MIN_P( ini->ReadString("TX PCL table",
- "PCS1900_MIN_P",
- "0"
- ));
- setPCS1900_C( ini->ReadString("TX PCL table",
- "PCS1900_C",
- "0"
- ));
- setPCS1900_MAX_RX_LOSS( ini->ReadString("RX path loss table",
- "PCS1900_MAX_RX_LOSS",
- "0"
- ));
- setPCS1900_MIN_RX_LOSS( ini->ReadString("RX path loss table",
- "PCS1900_MIN_RX_LOSS",
- "0"
- ));
- setPCS1900_CORRECTION( ini->ReadString("TX PCL table",
- "GSM900_CORRECTION",
- "0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"
- ));
- setBSIC( ini->ReadInteger("TX PCL table",
- "BSIC",
- 5
- ));
- // added by Andy Ueng
- // set_FACTORY_ID( ini->ReadString("META factory",
- // "FACTORY_ID",
- // "0"
- // ));
- // added by Andy Ueng for ADC calibration
- setADC_V1( ini->ReadString("ADC table",
- "ADC_V1",
- "3400"
- ));
- setADC_V2( ini->ReadString("ADC table",
- "ADC_V2",
- "4200"
- ));
- setADC_CHECK_VOLTAGE( ini->ReadString("ADC table",
- "ADC_CHECK_VOLTAGE",
- "3600"
- ));
- set_NORMAL_VOLTAGE( ini->ReadString("ADC table",
- "NORMAL_VOLTAGE",
- "3800"
- ));
- set_MAX_BATTERY_ADC_SLOPE( ini->ReadString("ADC table",
- "MAX_BATTERY_ADC_SLOPE",
- "5300.0"
- ));
- set_MIN_BATTERY_ADC_SLOPE( ini->ReadString("ADC table",
- "MIN_BATTERY_ADC_SLOPE",
- "5100.0"
- ));
- set_MAX_BATTERY_ADC_OFFSET( ini->ReadString("ADC table",
- "MAX_BATTERY_ADC_OFFSET",
- "1000000"
- ));
- set_MIN_BATTERY_ADC_OFFSET( ini->ReadString("ADC table",
- "MIN_BATTERY_ADC_OFFSET",
- "0"
- ));
- set_BATTERY_CHANNEL( ini->ReadString("ADC table",
- "BATTERY_CHANNEL",
- "0"
- ));
- set_CHARGER_CHANNEL( ini->ReadString("ADC table",
- "CHARGER_CHANNEL",
- "3"
- ));
- set_ADC_RESISTANCE( ini->ReadString("ADC table",
- "ADC_RESISTANCE",
- "0.33"
- ));
- set_MAX_VOLTAGE_DIFFERENCE( ini->ReadString("ADC table",
- "MAX_VOLTAGE_DIFFERENCE",
- "0.04"
- ));
- set_MAX_CURRENT_DIFFERENCE( ini->ReadString("ADC table",
- "MAX_CURRENT_DIFFERENCE",
- "0.02"
- ));
- set_ADC_MEASUREMENT_COUNT( ini->ReadString("ADC table",
- "ADC_MEASUREMENT_COUNT",
- "100"
- ));
- delete ini;
- }
- // ini = NULL;
- }
- //=============================================================================