form_FM.cpp
上传用户:gelin96
上传日期:2017-01-08
资源大小:20993k
文件大小:23k
- //---------------------------------------------------------------------------
- #include <vcl.h>
- #include <stdio.h>
- #pragma hdrstop
- // FM
- #ifndef _FM_COMMON_H_
- #include "fm_common.h"
- #endif
- #ifndef _FORM_FM_H_
- #include "form_FM.h"
- #endif
- // misc
- #ifndef _MISC_FM_H_
- #include "misc_fm.h"
- #endif
- #ifndef _FT_UTILS_H_
- #include "ft_utils.h"
- #endif
- //---------------------------------------------------------------------------
- typedef enum
- {
- FM_MODE_IDX_MONO = 0,
- FM_MODE_IDX_STEREO
- }E_FM_MODE_IDX;
- //---------------------------------------------------------------------------
- #pragma package(smart_init)
- #pragma resource "*.dfm"
- TfrmFM *frmFM;
- //===========================================================================
- static void CNF_FM_PowerOn(void)
- {
- frmFM->CNF_FM_PowerOn();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_PowerReset(void)
- {
- frmFM->CNF_FM_PowerReset();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_PowerOff(void)
- {
- frmFM->CNF_FM_PowerOff();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_SetFreq(void)
- {
- frmFM->CNF_FM_SetFreq();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_SearchNextStation(void)
- {
- frmFM->CNF_FM_SearchNextStation();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_SearchPreStation(void)
- {
- frmFM->CNF_FM_SearchPreStation();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_SetAudio(void)
- {
- frmFM->CNF_FM_SetAudio();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_ReadData(void)
- {
- frmFM->CNF_FM_ReadData();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_WriteData(void)
- {
- frmFM->CNF_FM_WriteData();
- }
- //---------------------------------------------------------------------------
- static void CNF_FM_GetStatus(void)
- {
- frmFM->CNF_FM_GetStatus();
- }
- //===========================================================================
- __fastcall TfrmFM::TfrmFM(TComponent* Owner)
- : TForm(Owner)
- {
- Init();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::Init(void)
- {
- m_bInit = true;
- }
- //===========================================================================
- void __fastcall TfrmFM::FormActivate(TObject *Sender)
- {
- if (m_bInit)
- {
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_PowerOn;
- m_cFM_RADIO_Obj.REQ_FM_Power_On_Start();
- }
- }
- //===========================================================================
- void TfrmFM::CurrentPageReset(void)
- {
- m_btnReset->Enabled = true;
- m_btnSetFreq->Enabled = true;
- m_btnSearchNextStation->Enabled = true;
- m_btnSearchPreStation->Enabled = true;
- m_btnSetAudio->Enabled = true;
- m_btnRead->Enabled = true;
- m_btnWrite->Enabled = true;
- m_btnGet->Enabled = true;
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CurrentPageLock(void)
- {
- m_btnReset->Enabled = false;
- m_btnSetFreq->Enabled = false;
- m_btnSearchNextStation->Enabled = false;
- m_btnSearchPreStation->Enabled = false;
- m_btnSetAudio->Enabled = false;
- m_btnRead->Enabled = false;
- m_btnWrite->Enabled = false;
- m_btnGet->Enabled = false;
- }
- //---------------------------------------------------------------------------
- void TfrmFM::ReDrawFields(E_DRAW_FM_T draw)
- {
- if (draw & DRAW_FM_STATION)
- {
- char str[256];
- sprintf(str, "%.1f", m_sValidFreq.m_i2ValidFreq / FM_FREQ_SCALE);
- m_edtStation->Text = (AnsiString) str;
- }
- if (draw & DRAW_FM_REGISTER)
- {
- m_edtWord1->Text = IntToStr((m_usData & 0xFF00) >> 8);
- m_edtWord0->Text = IntToStr(m_usData & 0x00FF);
- }
- if (draw & DRAW_FM_STATUS)
- {
- m_stRssi->Caption = IntToStr(m_sStatus.s_rssi.m_ucSignalLevel);
- m_stIfCounter->Caption = IntToStr(m_sStatus.s_if_cnt.m_u2IfCnt);
- m_stHLSide->Caption = IntToStr(m_sStatus.s_hl_side.m_ucHighOrLow);
- m_stStereoMono->Caption = IntToStr(m_sStatus.s_stero_mono.m_ucStereoOrMono);
- }
- }
- //===========================================================================
- void TfrmFM::CNF_FM_PowerOn(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on fail";
- Application->MessageBox("Execution Failure : FM radio module power on", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on timeout";
- Application->MessageBox("Execution Timeout : FM radio module power on", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on stop";
- }
- break;
- default:
- {
- }
- break;
- }
- }
- //===========================================================================
- void TfrmFM::ShowHintLabel(TControl *sender, char* hint)
- {
- TPoint pt0 = this->ClientOrigin;
- TPoint pt1 = sender->ClientOrigin;
- lblHint->Left = (pt1.x-pt0.x);
- lblHint->Top = (pt1.y-pt0.y)+sender->Height+3;
- lblHint->Caption = hint;
- lblHint->Visible = true;
- HintTimer->Enabled = true;
- }
- //--------------------------------------------------------------------------
- void __fastcall TfrmFM::edtFreqCheck(TObject *Sender)
- {
- AnsiString text;
- short freq;
- TEdit *edit = (TEdit*)Sender;
- char hint[] = " frequecy shall be 87.5~108 MHz ";
- text = edit->Text;
- if (!IsValidFMFreq(text, freq))
- {
- ShowHintLabel(edit, hint);
- edit->SetFocus();
- return;
- }
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmFM::m_btnSetFreqClick(TObject *Sender)
- {
- FM_FREQ_REQ_T req;
- AnsiString_To_FM_Freq(m_edtFreq->Text, req.m_i2CurFreq);
-
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_SetFreq;
- m_cFM_RADIO_Obj.REQ_Set_Freq_Start(req);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set frequency progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_SetFreq(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set frequency successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set frequency fail";
- Application->MessageBox("Execution Failure : Set frequency", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set frequency timeout";
- Application->MessageBox("Execution Timeout : Set frequency", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set frequency stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmFM::edtRssiThresholdCheck(TObject *Sender)
- {
- AnsiString text;
- unsigned int uidata;
- TEdit *edit = (TEdit*)Sender;
- char hint[] = " value shall be 1~6";
- text = edit->Text;
- if (!IsValidFMRssiThreshold(text, uidata))
- {
- ShowHintLabel(edit, hint);
- edit->SetFocus();
- return;
- }
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmFM::edtIFCounterDeltaCheck(TObject *Sender)
- {
- AnsiString text;
- unsigned int uidata;
- TEdit *edit = (TEdit*)Sender;
- char hint[] = " value shall be 10~30 and multiple of 5";
- text = edit->Text;
- if (!IsValidFMIfCounterDelta(text, uidata))
- {
- ShowHintLabel(edit, hint);
- edit->SetFocus();
- return;
- }
- }
- //==========================================================================
- void __fastcall TfrmFM::m_btnSearchNextStationClick(TObject *Sender)
- {
- S_FM_SEARCH_STATION_T search_station;
- short freq;
- search_station.s_if_cnt_delta.m_u4IfCntDelta = m_cbIfCounterDelta->Text.ToInt();
- search_station.s_rssi_thrsh.m_u4RssiThreshold = m_cbRssiThreshold->ItemIndex + 1;
- AnsiString_To_FM_Freq(m_edtStation->Text, freq);
- search_station.s_freq_range.m_i2StartFreq = freq + 1;
- search_station.s_freq_range.m_i2StopFreq = FM_MAX_FREQ * FM_FREQ_SCALE;
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_SearchNextStation;
- m_cFM_RADIO_Obj.REQ_SearchFreq_Start(search_station);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search next station progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_SearchNextStation(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- FM_VAILD_FREQ_CNF_T* p_valid_freq;
- p_valid_freq = m_cFM_RADIO_Obj.Get_ValidFreq();
- m_sValidFreq = *p_valid_freq;
- ReDrawFields(DRAW_FM_STATION);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search next station successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search next station fail";
- Application->MessageBox("Execution Failure : Search next station", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search next station timeout";
- Application->MessageBox("Execution Timeout : Search next station", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search next station stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- void __fastcall TfrmFM::m_btnSearchPreStationClick(TObject *Sender)
- {
- S_FM_SEARCH_STATION_T search_station;
- short freq;
- search_station.s_if_cnt_delta.m_u4IfCntDelta = m_cbIfCounterDelta->Text.ToInt();
- search_station.s_rssi_thrsh.m_u4RssiThreshold = m_cbRssiThreshold->ItemIndex + 1;
- AnsiString_To_FM_Freq(m_edtStation->Text, freq);
- search_station.s_freq_range.m_i2StartFreq = freq - 1;
- search_station.s_freq_range.m_i2StopFreq = FM_MIN_FREQ * FM_FREQ_SCALE;
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_SearchNextStation;
- m_cFM_RADIO_Obj.REQ_SearchFreq_Start(search_station);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search previous station progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_SearchPreStation(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search previous station successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search previous station fail";
- Application->MessageBox("Execution Failure : Search previous station", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search previous station timeout";
- Application->MessageBox("Execution Timeout : Search previous station", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Search previous station stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //===========================================================================
- void __fastcall TfrmFM::m_btnSetAudioClick(TObject *Sender)
- {
- S_FM_AUDIO_T audio;
- audio.s_mono_stereo_blend.m_u2MonoOrStereo = m_cbMode->ItemIndex; // 0: mono, 1: stereo
- audio.s_mono_stereo_blend.m_u2SblendOnOrOff = m_cbStereoBlend->Checked && m_cbStereoBlend->Enabled;
- audio.s_soft_mute_onoff.m_bOnOff = m_cbSoftMute->Checked;
- //audio.s_soft_mute_level.m_ucStage = m_cbSoftMuteLevel->ItemIndex + 1;
- audio.s_stereo_blend_level.m_ucStage = m_cbStereoBlendLevel->ItemIndex + 1;
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_SetAudio;
- m_cFM_RADIO_Obj.REQ_SetAudio_Start(audio);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set audio parameter progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_SetAudio(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set audio parameter successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set audio parameter fail";
- Application->MessageBox("Execution Failure : Set audio parameter", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set audio parameter timeout";
- Application->MessageBox("Execution Timeout : Set audio parameter", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Set audio parameter stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //===========================================================================
- void __fastcall TfrmFM::m_btnReadClick(TObject *Sender)
- {
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_ReadData;
- m_cFM_RADIO_Obj.REQ_ReadData_Start(m_edtAddr->Text.ToInt());
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Read data progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_ReadData(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_usData = m_cFM_RADIO_Obj.Get_Data();
- ReDrawFields(DRAW_FM_REGISTER);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Read data successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Read data fail";
- Application->MessageBox("Execution Failure : Read data", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Read data timeout";
- Application->MessageBox("Execution Timeout : Read data", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Read data stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- void __fastcall TfrmFM::m_btnWriteClick(TObject *Sender)
- {
- unsigned short data;
- unsigned short word1;
- unsigned short word0;
- word1 = m_edtWord1->Text.ToInt() & 0x00FF;
- word0 = m_edtWord0->Text.ToInt() & 0x00FF;
- data = (word1 << 8) | word0;
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_WriteData;
- m_cFM_RADIO_Obj.REQ_WriteData_Start(m_edtAddr->Text.ToInt(), data);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Write data progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_WriteData(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Write data successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Write data fail";
- Application->MessageBox("Execution Failure : Write data", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Write data timeout";
- Application->MessageBox("Execution Timeout : Write data", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Write data stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmFM::HintTimerTimer(TObject *Sender)
- {
- HintTimer->Enabled = false;
- lblHint->Visible = false;
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmFM::m_btnGetClick(TObject *Sender)
- {
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_GetStatus;
- m_cFM_RADIO_Obj.REQ_Get_FM_Status_Start();
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Get FM status progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_GetStatus(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- S_FM_STATUS_T* p_fm_status = m_cFM_RADIO_Obj.Get_FMStatus();
- m_sStatus = *p_fm_status;
- ReDrawFields(DRAW_FM_STATUS);
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Get FM status successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Get FM status fail";
- Application->MessageBox("Execution Failure : Get FM status", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Get FM status timeout";
- Application->MessageBox("Execution Timeout : Get FM status", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Get FM status stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- void __fastcall TfrmFM::m_btnResetClick(TObject *Sender)
- {
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_PowerOff;
- m_cFM_RADIO_Obj.REQ_FM_Power_Off_Start();
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" Reset progressing";
- CurrentPageLock();
- }
- //---------------------------------------------------------------------------
- void TfrmFM::CNF_FM_PowerOff(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_cFM_RADIO_Obj.ConfirmCallback = ::CNF_FM_PowerReset;
- m_cFM_RADIO_Obj.REQ_FM_Power_On_Start();
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM module radio power on fail";
- Application->MessageBox("Execution Failure : FM radio module power on", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on timeout";
- Application->MessageBox("Execution Timeout : FM radio module power on", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on stop";
- }
- break;
- default:
- {
- }
- break;
- }
- }
- //-------------------------------------------------------------------------
- void TfrmFM::CNF_FM_PowerReset(void)
- {
- E_METAAPP_RESULT_T state = m_cFM_RADIO_Obj.Get_ConfirmState();
- switch (state)
- {
- case METAAPP_SUCCESS:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power reset successfully";
- }
- break;
- case METAAPP_FAIL:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on fail";
- Application->MessageBox("Execution Failure : FM radio module power on", "FAILURE", MB_OK );
- }
- break;
- case METAAPP_TIMEOUT:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on timeout";
- Application->MessageBox("Execution Timeout : FM radio module power on", "TIMEOUT", MB_OK );
- }
- break;
- case METAAPP_STOP:
- {
- m_sbFM->Panels->Items[0]->Text = (AnsiString)" FM radio module power on stop";
- }
- break;
- default:
- {
- }
- break;
- }
- CurrentPageReset();
- }
- //---------------------------------------------------------------------------
- void __fastcall TfrmFM::m_cbModeChange(TObject *Sender)
- {
- m_cbStereoBlend->Enabled = (FM_MODE_IDX_STEREO == (E_FM_MODE_IDX) m_cbMode->ItemIndex) ? true : false;
- }
- //---------------------------------------------------------------------------