form_wifitxprofile.h
上传用户:gelin96
上传日期:2017-01-08
资源大小:20993k
文件大小:5k
源码类别:

MTK

开发平台:

C++ Builder

  1. //---------------------------------------------------------------------------
  2. #ifndef  _FORM_WIFITXPROFILE_H_
  3. #define  _FORM_WIFITXPROFILE_H_
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Controls.hpp>
  7. #include <StdCtrls.hpp>
  8. #include <Forms.hpp>
  9. #include <ExtCtrls.hpp>
  10. #include <ComCtrls.hpp>
  11. #include <Dialogs.hpp>
  12. // WiFi
  13. #ifndef  _WIFI_COMMON_H_
  14. #include "wifi_common.h"
  15. #endif
  16. #ifndef  _WIFI_APC_2400M_H_
  17. #include "wifi_apc_2400m.h"
  18. #endif
  19. #ifndef  _WIFI_EE_H_
  20. #include "wifi_ee.h"
  21. #endif
  22. //---------------------------------------------------------------------------
  23. //---------------------------------------------------------------------------
  24. class TfrmWiFiTxProfile : public TForm
  25. {
  26. __published: // IDE-managed Components
  27.         TPanel *pnlPCL;
  28.         TEdit *edtCCKCHDAC00;
  29.         TEdit *edtCCKCHDAC01;
  30.         TEdit *edtCCKCHDAC02;
  31.         TEdit *edtCCKCHDAC03;
  32.         TEdit *edtCCKCHDAC04;
  33.         TEdit *edtCCKCHDAC05;
  34.         TEdit *edtCCKCHDAC06;
  35.         TEdit *edtCCKCHDAC07;
  36.         TEdit *edtCCKCHDAC08;
  37.         TEdit *edtCCKCHDAC09;
  38.         TEdit *edtCCKCHDAC0A;
  39.         TEdit *edtCCKCHDAC0B;
  40.         TEdit *edtOFDMCHDAC01;
  41.         TButton *btnUploadFromFlash;
  42.         TButton *btnDownloadToFlash;
  43.         TButton *btnChangeDB;
  44.         TButton *btnLoadFromFile;
  45.         TButton *btnSaveToFile;
  46.         TStatusBar *sbWiFiTXP;
  47.         TOpenDialog *OpenDialog;
  48.         TSaveDialog *SaveDialog;
  49.         TStaticText *lblHint;
  50.         TTimer *HintTimer;
  51.         TEdit *edtOFDMCHDAC02;
  52.         TEdit *edtOFDMCHDAC03;
  53.         TEdit *edtOFDMCHDAC04;
  54.         TEdit *edtOFDMCHDAC05;
  55.         TEdit *edtOFDMCHDAC06;
  56.         TEdit *edtOFDMCHDAC07;
  57.         TEdit *edtOFDMCHDAC08;
  58.         TEdit *edtOFDMCHDAC09;
  59.         TEdit *edtOFDMCHDAC0A;
  60.         TEdit *edtOFDMCHDAC0B;
  61.         TLabel *Label13;
  62.         TLabel *Label14;
  63.         TLabel *Label15;
  64.         TLabel *Label16;
  65.         TLabel *Label17;
  66.         TLabel *Label18;
  67.         TLabel *Label19;
  68.         TLabel *Label20;
  69.         TLabel *Label21;
  70.         TLabel *Label22;
  71.         TLabel *Label23;
  72.         TLabel *Label24;
  73.         TLabel *Label25;
  74.         TLabel *Label27;
  75.         TEdit *edtOFDMCHDAC00;
  76.         TButton *btnTxPowerDac;
  77.         TLabel *Label28;
  78.         TEdit *edtCCKCHDAC0C;
  79.         TEdit *edtCCKCHDAC0D;
  80.         TLabel *Label1;
  81.         TEdit *edtOFDMCHDAC0C;
  82.         TEdit *edtOFDMCHDAC0D;
  83.         TLabel *Label2;
  84.         TButton *btnLoadFromEEPROM;
  85.         void __fastcall btnUploadFromFlashClick(TObject *Sender);
  86.         void __fastcall FormCreate(TObject *Sender);
  87.         void __fastcall edtCCKCHDACCheck(TObject *Sender);
  88.         void __fastcall HintTimerTimer(TObject *Sender);
  89.         void __fastcall btnSaveToFileClick(TObject *Sender);
  90.         void __fastcall btnLoadFromFileClick(TObject *Sender);
  91.         void __fastcall btnChangeDBClick(TObject *Sender);
  92.         void __fastcall btnDownloadToFlashClick(TObject *Sender);
  93.         void __fastcall FormShow(TObject *Sender);
  94.         void __fastcall btnTxPowerDacClick(TObject *Sender);
  95.         void __fastcall edtOFDMCHDACCheck(TObject *Sender);
  96.         void __fastcall btnLoadFromEEPROMClick(TObject *Sender);
  97.         
  98. private: // User declarations
  99.         // common
  100.         bool    m_bInit;
  101.         WiFi_ChipCapability_S m_sWiFiCap;
  102.         CWIFIAPC  m_WIFI_TXP_Obj;
  103.         WiFi_TxPower_2400M_S  m_sTxPwr2400M;
  104.         WiFi_TxPower_5000M_S  m_sTxPwr5000M;
  105.         S_WIFI_EEPROM   m_sEE;
  106.         // UI
  107.         TEdit   *edtCCKCHDAC[NUM_TX_POWER_2400M_CH];
  108.         TEdit   *edtOFDMCHDAC[NUM_TX_POWER_2400M_CH];
  109.         // EEPROM
  110.         CWIFIEE   m_WIFI_EE_Obj;
  111. public: // User declarations
  112.         __fastcall TfrmWiFiTxProfile(TComponent* Owner);
  113.         void Init( void );
  114.         // UI
  115.         void  ReDrawFields( void );
  116.         bool  CheckFields( void );
  117.         void  CurrentPageReset( void );
  118.         void  CurrentPageLock( void );
  119.         void  ShowHintLabel( TControl *sender, char* hint );
  120.         // EEPROM
  121.         void  Compose_EEPROM_Parameter( void );
  122.         void  ConfirmCallback_ReadEE( void );
  123.         void  WiFiTxPowerEEToNVRAM( void );
  124.         // NVRAM
  125.         void  UploadTxPower2400MFromFlashDone( void );
  126.         void  UploadTxPower5000MFromFlashDone( void );
  127.         void  DownloadTxPower2400MToFlashDone( void );
  128.         void  DownloadTxPower5000MToFlashDone( void );
  129.         // global information
  130.         void  WIFI_APC_Obj( CWIFIAPC  *wifi_apc_obj );
  131. };
  132. //---------------------------------------------------------------------------
  133. extern PACKAGE TfrmWiFiTxProfile *frmWiFiTxProfile;
  134. //---------------------------------------------------------------------------
  135. #endif