form_Setting.cpp
上传用户:gelin96
上传日期:2017-01-08
资源大小:20993k
文件大小:22k
- /*****************************************************************************
- * 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:
- * ---------
- * form_Setting.cpp
- *
- * Project:
- * --------
- * Maui META APP
- *
- * Description:
- * ------------
- * Setting form 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>
- #pragma hdrstop
- #include "form_Setting.h"
- #include "form_main.h"
- //---------------------------------------------------------------------------
- #pragma package(smart_init)
- #pragma resource "*.dfm"
- TfrmSetting *frmSetting;
- extern TfrmMainSel *frmMainSel;
- //==============================================================================
- static void CNF_ReadFromNVRAM( void )
- { frmSetting->UploadFromFlashDone();
- }
- //---------------------------------------------------------------------------
- static void CNF_WriteToNVRAM( void )
- { frmSetting->DownloadToFlashDone();
- }
- //---------------------------------------------------------------------------
- static void CNF_ResetNVRAMData( void )
- {
- frmSetting->CNF_ResetNVRAMData();
- }
- //==============================================================================
- __fastcall TfrmSetting::TfrmSetting(TComponent* Owner)
- : TForm(Owner)
- {
-
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::FormCreate(TObject *Sender)
- {
- InitMsClassFromUi();
- InitPlmnSelectionFromUi();
- InitGprsAttachModeFromUi();
- }
- //--------------------------------------------------------------------
- void TfrmSetting::InitMsClassFromUi(void)
- {
- if (rbClassCC->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_MOBILE_CLASS_CC;
- }
- else if (rbClassCG->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_MOBILE_CLASS_CG;
- }
- else if (rbClassBGSM->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_MOBILE_CLASS_BGSM;
- }
- else if (rbClassBGprs->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_MOBILE_CLASS_BGPRS;
- }
- }
- //--------------------------------------------------------------------
- void TfrmSetting::InitPlmnSelectionFromUi(void)
- {
- if (rbManual->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_PLMN_SELECTION_MANUAL;
- }
- else if (rbAutomatic->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_PLMN_SELECTION_AUTO;
- }
- }
- //--------------------------------------------------------------------
- void TfrmSetting::InitGprsAttachModeFromUi(void)
- {
- if (rbNotAutoAttach->Checked)
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_GPRS_ATTACH_NOTAUTO;
- }
- else
- {
- m_sNvramEfRacPreference.uc_arg1 |= ARG1_GPRS_ATTACH_AUTO;
- }
- }
- //==============================================================================
- void __fastcall TfrmSetting::btnUploadFromFlashClick(TObject *Sender)
- {
- if (!NVRAMMan->Get_IsInit())
- {
- frmMainSel->mnuFDMDatabaseClick(Sender);
- }
- if (!NVRAMMan->Get_IsInit())
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " NVRAM database file initialize fail";
- Application->MessageBox("Execution Failure : NVRAM database file initialize fail", "FAILURE", MB_OK);
- return;
- }
- CurrentPageLock();
- m_cSETTING_BAND_Obj.ConfirmCallback = ::CNF_ReadFromNVRAM;
- m_cSETTING_BAND_Obj.REQ_Read_From_NVRAM_Start();
- }
- //---------------------------------------------------------------------------
- void TfrmSetting::UploadFromFlashDone(void)
- {
- E_METAAPP_RESULT_T state = m_cSETTING_BAND_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_cSETTING_BAND_Obj.Get_RacPreference(m_sNvramEfRacPreference);
- ReDrawFields();
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Upload band setting from flash successful";
- }
- break;
- case METAAPP_FAIL:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Upload band setting from flash fail, please check the version of load and NVRAM database are same.";
- Application->MessageBox("Execution Failure : Upload band setting form flash, please check the version of load and NVRAM database are same.", "FAILURE", MB_OK);
- }
- break;
- case METAAPP_TIMEOUT:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Upload band setting from flash timeout";
- Application->MessageBox("Execution Timeout : Upload band setting form flash", "TIMEOUT", MB_OK);
- }
- break;
- case METAAPP_STOP:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Upload band setting from flash stop";
- }
- break;
- }
- CurrentPageReset();
- }
- //==============================================================================
- void __fastcall TfrmSetting::btnDownloadToFlashClick(TObject *Sender)
- {
- if (!NVRAMMan->Get_IsInit())
- {
- frmMainSel->mnuFDMDatabaseClick(Sender);
- }
- if (!NVRAMMan->Get_IsInit())
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " NVRAM database file initialize fail";
- Application->MessageBox( "Execution Failure : NVRAM database file initialize fail", "FAILURE", MB_OK );
- return;
- }
- CurrentPageLock();
-
- m_cSETTING_BAND_Obj.Set_RacPreference(m_sNvramEfRacPreference);
- m_cSETTING_BAND_Obj.ConfirmCallback = ::CNF_WriteToNVRAM;
- m_cSETTING_BAND_Obj.REQ_Write_To_NVRAM_Start();
- }
- //-----------------------------------------------
- void TfrmSetting::DownloadToFlashDone(void)
- {
- E_METAAPP_RESULT_T state = m_cSETTING_BAND_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Download band setting to flash successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Download band setting to flash fail, please check the version of load and NVRAM database are same.";
- Application->MessageBox("Execution Failure : Download uc_band setting to flash, please check the version of load and NVRAM database are same.", "FAILURE", MB_OK);
- }
- break;
- case METAAPP_TIMEOUT:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Download uc_band setting to flash timeout";
- Application->MessageBox("Execution Timeout : Download band setting to flash", "TIMEOUT", MB_OK);
- }
- break;
- case METAAPP_STOP:
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Download band setting to flash stop";
- }
- }
- CurrentPageReset();
- }
- //==============================================================================
- void TfrmSetting::ReDrawFields( void )
- {
- #if 0
- // uc_band
- switch( m_sNvramEfRacPreference.uc_band )
- {
- case BAND_MODE_GSM900:
- rbGSM900->Checked = true;
- break;
- case BAND_MODE_DCS1800:
- rbDCS1800->Checked = true;
- break;
- case BAND_MODE_PCS1900:
- rbPCS1900->Checked = true;
- break;
- case BAND_MODE_GSM850:
- rbGSM850->Checked = true;
- break;
- case DUAL_BAND_MODE:
- rbDualBand->Checked = true;
- break;
- case DUAL_BAND_MODE_850_1900:
- rbDualBand850_1900->Checked = true;
- break;
- default:
- Application->MessageBox( "Band mode value not valid", "ERROR!", MB_OK );
- break;
- }
- #endif
- // uc_arg1
- switch ( m_sNvramEfRacPreference.uc_arg1 & MASK_ARG1_PLMN_SELECTION)
- {
- case ARG1_PLMN_SELECTION_MANUAL:
- {
- rbManual->Checked = true;
- }
- break;
- case ARG1_PLMN_SELECTION_AUTO:
- {
- rbAutomatic->Checked = true;
- }
- break;
- }
- switch (m_sNvramEfRacPreference.uc_arg1 & MASK_ARG1_MOBILE_CLASS)
- {
- case ARG1_MOBILE_CLASS_CC:
- rbClassCC->Checked = true;
- break;
- case ARG1_MOBILE_CLASS_CG:
- rbClassCG->Checked = true;
- break;
- case ARG1_MOBILE_CLASS_BGSM:
- rbClassBGSM->Checked = true;
- break;
- case ARG1_MOBILE_CLASS_BGPRS:
- rbClassBGprs->Checked = true;
- break;
- }
- switch ( m_sNvramEfRacPreference.uc_arg1 & MASK_ARG1_GPRS_ATTACH )
- {
- case ARG1_GPRS_ATTACH_NOTAUTO:
- rbNotAutoAttach->Checked = true;
- break;
- case ARG1_GPRS_ATTACH_AUTO:
- rbAutoAttach->Checked = true;
- break;
- }
- }
- #if 0
- //--------------------------------------------------------------------
- void TfrmSetting::InitBandFromUi( void )
- {
- if( rbGSM900->Checked )
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_GSM900;
- }
- else if( rbDCS1800->Checked )
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_DCS1800;
- }
- else if( rbPCS1900->Checked )
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_PCS1900;
- }
- else if( rbGSM850->Checked )
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_GSM850;
- }
- else if( rbDualBand->Checked )
- {
- m_sNvramEfRacPreference.uc_band = DUAL_BAND_MODE;
- }
- else if( rbDualBand850_1900->Checked )
- {
- m_sNvramEfRacPreference.uc_band = DUAL_BAND_MODE_850_1900;
- }
- }
- #endif
- //==============================================================================
- void __fastcall TfrmSetting::rbGSM900Click(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_GSM900;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbDCS1800Click(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_DCS1800;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbPCS1900Click(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_PCS1900;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbGSM850Click(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_band = BAND_MODE_GSM850;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbDualBandClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_band = DUAL_BAND_MODE;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbDualBand850_1900Click(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_band = DUAL_BAND_MODE_850_1900;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::btnLoadFromFileClick(TObject *Sender)
- {
- char str[512];
- bool ok;
- float fdata;
- ok = OpenDialog->Execute();
- if( !ok )
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Load band setting from file fail";
- Application->MessageBox( "Execution Failure : Load band setting from file", "FAILURE", MB_OK );
- return;
- }
- strcpy( str, OpenDialog->FileName.c_str() );
- ok = m_cSETTING_BAND_Obj.REQ_Read_From_File( str );
- if( ok )
- {
- m_cSETTING_BAND_Obj.Get_RacPreference(m_sNvramEfRacPreference);
- ReDrawFields();
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Load band setting from file successful";
- }
- else
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Load band setting from file fail";
- Application->MessageBox( "Execution Failure : Load band setting from file", "FAILURE", MB_OK );
- }
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::btnSaveToFileClick(TObject *Sender)
- {
- char str[512];
- bool ok;
- ok = SaveDialog->Execute();
- if (!ok)
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Save band setting to file fail";
- Application->MessageBox( "Execution Failure : Save band setting to file", "FAILURE", MB_OK );
- return;
- }
- m_cSETTING_BAND_Obj.Set_RacPreference(m_sNvramEfRacPreference);
- strcpy(str, SaveDialog->FileName.c_str());
- ok = m_cSETTING_BAND_Obj.REQ_Write_To_File(str);
- if (!ok)
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Save band setting to file fail";
- Application->MessageBox( "Execution Failure : Save band setting to file", "FAILURE", MB_OK );
- }
- else
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Save band setting to file successfully";
- }
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::btnChangeDBClick(TObject *Sender)
- {
- frmMainSel->mnuFDMDatabaseClick(Sender);
- if (!NVRAMMan->Get_IsInit())
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " NVRAM database file initialization fail";
- Application->MessageBox( "Execution Failure : NVRAM database file initialization fail", "FAILURE", MB_OK );
- return;
- }
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Change NVRAM database file successfully";
- }
- //-----------------------------------------------
- void TfrmSetting::CNF_ResetNVRAMData( void )
- {
- int state = m_cSETTING_BAND_Obj.Get_ConfirmState();
- CurrentPageReset();
- if( state==METAAPP_SUCCESS )
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Reset AGC path loss setting in flash successfully";
- }
- else if( state==METAAPP_FAIL )
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Reset AGC path loss setting in flash fail, please check the version of load and NVRAM database are same.";
- Application->MessageBox( "Execution Failure : Reset AGC path loss setting in flash, please check the version of load and NVRAM database are same.", "FAILURE", MB_OK );
- }
- else if( state==METAAPP_TIMEOUT )
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Reset AGC path loss setting in flash timeout";
- Application->MessageBox( "Execution Timeout : Reset AGC path loss setting in flash", "TIMEOUT", MB_OK );
- }
- else if( state==METAAPP_STOP )
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " Reset AGC path loss setting in flash stop";
- // Application->MessageBox( "Execution Stop : Reset AGC path loss setting in flash", "STOP", MB_OK );
- }
- }
- //==========================================================================
- #if 0
- void TfrmSetting::Display_BandSupport( void )
- {
- RfMsCapabilityEx_S capability;
- capability = frmMainSel->Get_FinalMSCap();
- if( capability.band_support.GSM850 ) rbGSM850->Visible = true;
- if( capability.band_support.GSM900 ) rbGSM900->Visible = true;
- if( capability.band_support.DCS1800 ) rbDCS1800->Visible = true;
- if( capability.band_support.PCS1900 ) rbPCS1900->Visible = true;
- if( capability.band_support.GSM900 && capability.band_support.DCS1800 ) rbDualBand->Visible = true;
- if( capability.band_support.GSM850 && capability.band_support.PCS1900 ) rbDualBand850_1900->Visible = true;
- if( capability.band_support.GSM900 ) rbGSM900->Checked = true;
- else if( capability.band_support.DCS1800 ) rbDCS1800->Checked = true;
- else if( capability.band_support.PCS1900 ) rbPCS1900->Checked = true;
- else rbGSM850->Checked = true;
- }
- #endif
- //--------------------------------------------------------------------------
- void __fastcall TfrmSetting::btnResetNVRAMDataClick(TObject *Sender)
- {
- if( ! NVRAMMan->Get_IsInit() )
- { frmMainSel->mnuFDMDatabaseClick(Sender);
- }
- if( ! NVRAMMan->Get_IsInit() )
- {
- sbBandSetting->Panels->Items[0]->Text = (AnsiString) " NVRAM database file initialization fail";
- Application->MessageBox( "Execution Failure : NVRAM database file initialization", "FAILURE", MB_OK );
- return;
- }
- m_cSETTING_BAND_Obj.ConfirmCallback = ::CNF_ResetNVRAMData;
- m_cSETTING_BAND_Obj.REQ_Reset_NVRAM_Data();
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmSetting::CurrentPageLock( void )
- {
- btnUploadFromFlash->Enabled = false;
- btnDownloadToFlash->Enabled = false;
- // btnResetNVRAMData->Enabled = false;
- btnChangeDB->Enabled = false;
- btnLoadFromFile->Enabled = false;
- btnSaveToFile->Enabled = false;
- }
- //----------------------------------------------------------------------------
- void TfrmSetting::CurrentPageReset( void )
- {
- btnUploadFromFlash->Enabled = true;
- btnDownloadToFlash->Enabled = true;
- // btnResetNVRAMData->Enabled = true;
- btnChangeDB->Enabled = true;
- btnLoadFromFile->Enabled = true;
- btnSaveToFile->Enabled = true;
- }
- //----------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbClassCCClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_MOBILE_CLASS)) | ARG1_MOBILE_CLASS_CC;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbClassCGClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_MOBILE_CLASS)) | ARG1_MOBILE_CLASS_CG;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbClassBGSMClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_MOBILE_CLASS)) | ARG1_MOBILE_CLASS_BGSM;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbClassBGprsClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_MOBILE_CLASS)) | ARG1_MOBILE_CLASS_BGPRS;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbManualClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_PLMN_SELECTION)) | ARG1_PLMN_SELECTION_MANUAL;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbAutomaticClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_PLMN_SELECTION)) | ARG1_PLMN_SELECTION_AUTO;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbNotAutoAttachClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_GPRS_ATTACH)) | ARG1_GPRS_ATTACH_NOTAUTO;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmSetting::rbAutoAttachClick(TObject *Sender)
- {
- m_sNvramEfRacPreference.uc_arg1 = (m_sNvramEfRacPreference.uc_arg1 & (0xFF ^ MASK_ARG1_GPRS_ATTACH)) | ARG1_GPRS_ATTACH_AUTO;
- }
- //---------------------------------------------------------------------------