From 5e70b486097e07fed4758ae82a6f45029d68077c Mon Sep 17 00:00:00 2001 From: wittend99 Date: Sun, 30 Dec 2012 22:41:15 +0000 Subject: [PATCH] Trivial updates, looking for uninitialized variables and other loose ends. git-svn-id: https://svn.code.sf.net/p/freetel/code@1155 01035d8c-6547-0410-b346-abe4f91aad63 --- fdmdv2/build/codelite/fdmdv2.mk | 2 +- fdmdv2/build/codelite/fdmdv2.project | 2 +- fdmdv2/build/codelite/libCTB/libCTB.mk | 22 +++++++++++----------- fdmdv2/src/fdmdv2_main.cpp | 11 ----------- fdmdv2/src/fdmdv2_main.h | 10 ++++------ fdmdv2/src/fdmdv2_plot_waterfall_linux.cpp | 7 ++++--- fdmdv2/src/topFrame.h | 2 -- 7 files changed, 21 insertions(+), 35 deletions(-) diff --git a/fdmdv2/build/codelite/fdmdv2.mk b/fdmdv2/build/codelite/fdmdv2.mk index d5ef007c..eb4d452d 100644 --- a/fdmdv2/build/codelite/fdmdv2.mk +++ b/fdmdv2/build/codelite/fdmdv2.mk @@ -13,7 +13,7 @@ CurrentFileName := CurrentFilePath := CurrentFileFullPath := User :=wittend -Date :=12/29/2012 +Date :=12/30/2012 CodeLitePath :="D:\bin\CodeLite" LinkerName :=g++ SharedObjectLinkerName :=g++ -shared -fPIC diff --git a/fdmdv2/build/codelite/fdmdv2.project b/fdmdv2/build/codelite/fdmdv2.project index f02253d5..e446b832 100644 --- a/fdmdv2/build/codelite/fdmdv2.project +++ b/fdmdv2/build/codelite/fdmdv2.project @@ -65,7 +65,7 @@ - + diff --git a/fdmdv2/build/codelite/libCTB/libCTB.mk b/fdmdv2/build/codelite/libCTB/libCTB.mk index 4fe13f21..1f1c5844 100644 --- a/fdmdv2/build/codelite/libCTB/libCTB.mk +++ b/fdmdv2/build/codelite/libCTB/libCTB.mk @@ -2,18 +2,18 @@ ## Auto Generated makefile by CodeLite IDE ## any manual changes will be erased ## -## Release +## Debug ProjectName :=libCTB -ConfigurationName :=Release +ConfigurationName :=Debug WorkspacePath := "D:\Projects\Radio\fdmdv2\build\codelite" ProjectPath := "D:\Projects\Radio\fdmdv2\build\codelite\libCTB" -IntermediateDirectory :=./Release +IntermediateDirectory :=./Debug OutDir := $(IntermediateDirectory) CurrentFileName := CurrentFilePath := CurrentFileFullPath := User :=wittend -Date :=12/29/2012 +Date :=12/30/2012 CodeLitePath :="D:\bin\CodeLite" LinkerName :=g++ SharedObjectLinkerName :=g++ -shared -fPIC @@ -52,8 +52,8 @@ LibPath := $(LibraryPathSwitch). AR := ar rcus CXX := g++ CC := gcc -CXXFLAGS := -DSVN_REVISION=\"1152\" $(Preprocessors) -CFLAGS := -DSVN_REVISION=\"1152\" $(Preprocessors) +CXXFLAGS := -g -DSVN_REVISION=\"1152\" $(Preprocessors) +CFLAGS := -g -DSVN_REVISION=\"1152\" $(Preprocessors) ## @@ -78,11 +78,11 @@ $(OutputFile): $(Objects) @echo "" > $(IntermediateDirectory)/.d @echo $(Objects) > $(ObjectsFileList) $(AR) $(ArchiveOutputSwitch)$(OutputFile) @$(ObjectsFileList) $(ArLibs) - @$(MakeDirCommand) "D:\Projects\Radio\fdmdv2\build\codelite\.build-release" - @echo rebuilt > "D:\Projects\Radio\fdmdv2\build\codelite\.build-release\libCTB" + @$(MakeDirCommand) "D:\Projects\Radio\fdmdv2\build\codelite\.build-debug" + @echo rebuilt > "D:\Projects\Radio\fdmdv2\build\codelite\.build-debug\libCTB" -./Release: - @$(MakeDirCommand) "./Release" +./Debug: + @$(MakeDirCommand) "./Debug" PreBuild: @@ -208,6 +208,6 @@ clean: $(RM) $(IntermediateDirectory)/win32_timer$(PreprocessSuffix) $(RM) $(OutputFile) $(RM) $(OutputFile) - $(RM) "D:\Projects\Radio\fdmdv2\build\codelite\.build-release\libCTB" + $(RM) "D:\Projects\Radio\fdmdv2\build\codelite\.build-debug\libCTB" diff --git a/fdmdv2/src/fdmdv2_main.cpp b/fdmdv2/src/fdmdv2_main.cpp index 0d5db73e..63ec85ec 100644 --- a/fdmdv2/src/fdmdv2_main.cpp +++ b/fdmdv2/src/fdmdv2_main.cpp @@ -718,16 +718,6 @@ void MainFrame::OnCloseFrame(wxCloseEvent& event) Pa_Terminate(); Destroy(); } -/* -//------------------------------------------------------------------------- -// OnExitClick() -//------------------------------------------------------------------------- -void MainFrame::OnExitClick(wxCommandEvent& event) -{ - Pa_Terminate(); - Destroy(); -} -*/ //------------------------------------------------------------------------- // OnTop() @@ -906,7 +896,6 @@ void MainFrame::OnTogBtnPTT (wxCommandEvent& event) m_maxLevel = 0; m_textLevel->SetLabel(wxT("")); m_gaugeLevel->SetValue(0); - event.Skip(); } diff --git a/fdmdv2/src/fdmdv2_main.h b/fdmdv2/src/fdmdv2_main.h index ef5a9de4..5635c00a 100644 --- a/fdmdv2/src/fdmdv2_main.h +++ b/fdmdv2/src/fdmdv2_main.h @@ -154,7 +154,6 @@ class MainApp : public wxApp bool m_snrSlow; // LPC Post Filter - bool m_codec2LPCPostFilterEnable; bool m_codec2LPCPostFilterBassBoost; float m_codec2LPCPostFilterGamma; @@ -224,19 +223,16 @@ typedef struct struct FIFO *outfifo1; // FIFOs attached to second sound card - struct FIFO *infifo2; struct FIFO *outfifo2; // FIFOs for rx process - struct FIFO *rxinfifo; struct FIFO *rxoutfifo; int inputChannels1, inputChannels2; // EQ filter states - void *sbqMicInBass; void *sbqMicInTreble; void *sbqMicInMid; @@ -269,11 +265,13 @@ class MyExtraRecFilePanel : public wxPanel { public: MyExtraRecFilePanel(wxWindow *parent); - ~MyExtraRecFilePanel() { + ~MyExtraRecFilePanel() + { wxLogDebug("Destructor\n"); } void setSecondsToRecord(wxString value) { m_secondsToRecord->SetValue(value); } - wxString getSecondsToRecord(void) { + wxString getSecondsToRecord(void) + { wxLogDebug("getSecondsToRecord: %s\n",m_secondsToRecord->GetValue()); return m_secondsToRecord->GetValue(); } diff --git a/fdmdv2/src/fdmdv2_plot_waterfall_linux.cpp b/fdmdv2/src/fdmdv2_plot_waterfall_linux.cpp index f2368a51..34cd3164 100644 --- a/fdmdv2/src/fdmdv2_plot_waterfall_linux.cpp +++ b/fdmdv2/src/fdmdv2_plot_waterfall_linux.cpp @@ -338,15 +338,17 @@ void PlotWaterfall::plotPixelData() dy_blocks = m_rGrid.GetHeight()/ dy; // update min and max amplitude estimates - float max_mag = MIN_MAG_DB; int min_fft_bin=((float)200/FDMDV_MAX_F_HZ)*FDMDV_NSPEC; int max_fft_bin=((float)2800/FDMDV_MAX_F_HZ)*FDMDV_NSPEC; - for(int i=min_fft_bin; i max_mag) + { max_mag = g_avmag[i]; + } } m_max_mag = BETA*m_max_mag + (1 - BETA)*max_mag; @@ -363,7 +365,6 @@ void PlotWaterfall::plotPixelData() */ // Shift previous bit map up one row of blocks ---------------------------- - wxNativePixelData data(*m_pBmp); assert(data != NULL); wxNativePixelData::Iterator bitMapStart(data); diff --git a/fdmdv2/src/topFrame.h b/fdmdv2/src/topFrame.h index 4c319c0b..9195fd63 100644 --- a/fdmdv2/src/topFrame.h +++ b/fdmdv2/src/topFrame.h @@ -152,13 +152,11 @@ class TopFrame : public wxFrame wxToggleButton* m_btnTogPTT; wxToggleButton* m_togBtnLoopRx; wxToggleButton* m_togBtnLoopTx; - wxAuiNotebook* m_auiNbookCtrl; TopFrame( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("FreeDV ") + _(FREEDV_VERSION), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 761,500 ), long style = wxDEFAULT_FRAME_STYLE|wxRESIZE_BORDER|wxTAB_TRAVERSAL ); ~TopFrame(); - }; #endif //__TOPFRAME_H__ -- 2.25.1