From a7e21685325cb9fb9a5cc239e48412ea531460ce Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Mon, 9 Nov 2015 17:19:48 +0000 Subject: [PATCH] Remove code associated with the unimplemented JT9W mode. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6061 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- Configuration.cpp | 27 ------ Configuration.hpp | 3 - Configuration.ui | 203 ++++++---------------------------------------- Modes.cpp | 1 - Modes.hpp | 1 - mainwindow.cpp | 71 ++++------------ mainwindow.h | 1 - mainwindow.ui | 9 -- 8 files changed, 37 insertions(+), 279 deletions(-) diff --git a/Configuration.cpp b/Configuration.cpp index d46c73dbe..cf3798516 100644 --- a/Configuration.cpp +++ b/Configuration.cpp @@ -458,10 +458,6 @@ private: bool restart_sound_input_device_; bool restart_sound_output_device_; - unsigned jt9w_bw_mult_; - float jt9w_min_dt_; - float jt9w_max_dt_; - Type2MsgGen type_2_msg_gen_; QStringListModel macros_; @@ -583,9 +579,6 @@ QAudioDeviceInfo const& Configuration::audio_output_device () const {return m_-> AudioDevice::Channel Configuration::audio_output_channel () const {return m_->audio_output_channel_;} bool Configuration::restart_audio_input () const {return m_->restart_sound_input_device_;} bool Configuration::restart_audio_output () const {return m_->restart_sound_output_device_;} -unsigned Configuration::jt9w_bw_mult () const {return m_->jt9w_bw_mult_;} -float Configuration::jt9w_min_dt () const {return m_->jt9w_min_dt_;} -float Configuration::jt9w_max_dt () const {return m_->jt9w_max_dt_;} auto Configuration::type_2_msg_gen () const -> Type2MsgGen {return m_->type_2_msg_gen_;} QString Configuration::my_callsign () const {return m_->my_callsign_;} QString Configuration::my_grid () const {return m_->my_grid_;} @@ -976,10 +969,6 @@ Configuration::impl::impl (Configuration * self, QSettings * settings, QWidget * initialize_models (); transceiver_thread_.start (); - -#if !WSJT_ENABLE_EXPERIMENTAL_FEATURES - ui_->jt9w_group_box->setEnabled (false); -#endif } Configuration::impl::~impl () @@ -1036,9 +1025,6 @@ void Configuration::impl::initialize_models () ui_->TX_messages_check_box->setChecked (TX_messages_); ui_->enable_VHF_features_check_box->setChecked(enable_VHF_features_); ui_->decode_at_52s_check_box->setChecked(decode_at_52s_); - ui_->jt9w_bandwidth_mult_combo_box->setCurrentText (QString::number (jt9w_bw_mult_)); - ui_->jt9w_min_dt_double_spin_box->setValue (jt9w_min_dt_); - ui_->jt9w_max_dt_double_spin_box->setValue (jt9w_max_dt_); ui_->type_2_msg_gen_combo_box->setCurrentIndex (type_2_msg_gen_); ui_->rig_combo_box->setCurrentText (rig_params_.rig_name); ui_->TX_mode_button_group->button (data_mode_)->setChecked (true); @@ -1199,19 +1185,12 @@ void Configuration::impl::read_settings () // retrieve audio channel info audio_input_channel_ = AudioDevice::fromString (settings_->value ("AudioInputChannel", "Mono").toString ()); audio_output_channel_ = AudioDevice::fromString (settings_->value ("AudioOutputChannel", "Mono").toString ()); - - jt9w_bw_mult_ = settings_->value ("ToneMult", 1).toUInt (); - jt9w_min_dt_ = settings_->value ("DTmin", -2.5).toFloat (); - jt9w_max_dt_ = settings_->value ("DTmax", 5.).toFloat (); - type_2_msg_gen_ = settings_->value ("Type2MsgGen", QVariant::fromValue (Configuration::type_2_msg_3_full)).value (); - monitor_off_at_startup_ = settings_->value ("MonitorOFF", false).toBool (); monitor_last_used_ = settings_->value ("MonitorLastUsed", false).toBool (); spot_to_psk_reporter_ = settings_->value ("PSKReporter", false).toBool (); id_after_73_ = settings_->value ("After73", false).toBool (); tx_QSY_allowed_ = settings_->value ("TxQSYAllowed", false).toBool (); - macros_.setStringList (settings_->value ("Macros", QStringList {"TNX 73 GL"}).toStringList ()); if (settings_->contains ("FrequenciesForModes")) @@ -1312,9 +1291,6 @@ void Configuration::impl::write_settings () settings_->setValue ("AudioInputChannel", AudioDevice::toString (audio_input_channel_)); settings_->setValue ("AudioOutputChannel", AudioDevice::toString (audio_output_channel_)); - settings_->setValue ("ToneMult", jt9w_bw_mult_); - settings_->setValue ("DTmin", jt9w_min_dt_); - settings_->setValue ("DTmax", jt9w_max_dt_); settings_->setValue ("Type2MsgGen", QVariant::fromValue (type_2_msg_gen_)); settings_->setValue ("MonitorOFF", monitor_off_at_startup_); settings_->setValue ("MonitorLastUsed", monitor_last_used_); @@ -1693,9 +1669,6 @@ void Configuration::impl::accept () tx_QSY_allowed_ = ui_->tx_QSY_check_box->isChecked (); monitor_off_at_startup_ = ui_->monitor_off_check_box->isChecked (); monitor_last_used_ = ui_->monitor_last_used_check_box->isChecked (); - jt9w_bw_mult_ = ui_->jt9w_bandwidth_mult_combo_box->currentText ().toUInt (); - jt9w_min_dt_ = static_cast (ui_->jt9w_min_dt_double_spin_box->value ()); - jt9w_max_dt_ = static_cast (ui_->jt9w_max_dt_double_spin_box->value ()); type_2_msg_gen_ = static_cast (ui_->type_2_msg_gen_combo_box->currentIndex ()); log_as_RTTY_ = ui_->log_as_RTTY_check_box->isChecked (); report_in_comments_ = ui_->report_in_comments_check_box->isChecked (); diff --git a/Configuration.hpp b/Configuration.hpp index f6983665b..dfcc85c97 100644 --- a/Configuration.hpp +++ b/Configuration.hpp @@ -127,9 +127,6 @@ public: QDir save_directory () const; QDir azel_directory () const; QString rig_name () const; - unsigned jt9w_bw_mult () const; - float jt9w_min_dt () const; - float jt9w_max_dt () const; Type2MsgGen type_2_msg_gen () const; QColor color_CQ () const; QColor color_MyCall () const; diff --git a/Configuration.ui b/Configuration.ui index 3d067d634..ba66d788d 100644 --- a/Configuration.ui +++ b/Configuration.ui @@ -20,7 +20,7 @@ Select tab to change configuration parameters. - 0 + 2 @@ -1180,26 +1180,6 @@ radio interface behave as expected. Audio interface settings - - - - Qt::Vertical - - - - 20 - 40 - - - - - - - - Qt::Horizontal - - - @@ -1367,160 +1347,6 @@ both here. - - - - JT9W Settings - - - - - - QFormLayout::ExpandingFieldsGrow - - - - - - 1 - - - - - 2 - - - - - 4 - - - - - 8 - - - - - 16 - - - - - 32 - - - - - 64 - - - - - 128 - - - - - - - - Bandwidth Multiplier: - - - jt9w_bandwidth_mult_combo_box - - - - - - - - - QFormLayout::ExpandingFieldsGrow - - - - - DT Max: - - - jt9w_max_dt_double_spin_box - - - - - - - DT Min: - - - jt9w_min_dt_double_spin_box - - - - - - - s - - - 1 - - - -2.500000000000000 - - - 5.000000000000000 - - - 0.100000000000000 - - - -2.500000000000000 - - - - - - - s - - - 1 - - - -2.500000000000000 - - - 5.000000000000000 - - - 0.100000000000000 - - - 5.000000000000000 - - - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - - - - @@ -1566,6 +1392,26 @@ both here. + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + Qt::Horizontal + + + @@ -2344,9 +2190,6 @@ soundcard changes sound_output_channel_combo_box save_path_select_push_button azel_path_select_push_button - jt9w_bandwidth_mult_combo_box - jt9w_min_dt_double_spin_box - jt9w_max_dt_double_spin_box add_macro_line_edit add_macro_push_button delete_macro_push_button @@ -2440,12 +2283,12 @@ soundcard changes - + - + diff --git a/Modes.cpp b/Modes.cpp index c325823fc..2f118ffcc 100644 --- a/Modes.cpp +++ b/Modes.cpp @@ -12,7 +12,6 @@ namespace "", "JT65", "JT9", - "JT9W-1", "JT4", "WSPR", "Echo", diff --git a/Modes.hpp b/Modes.hpp index dba2bd78b..82c6b16d6 100644 --- a/Modes.hpp +++ b/Modes.hpp @@ -17,7 +17,6 @@ public: NULL_MODE, JT65, JT9, - JT9W_1, JT4, WSPR, Echo, diff --git a/mainwindow.cpp b/mainwindow.cpp index eeeac1d82..648c949ff 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -240,7 +240,6 @@ MainWindow::MainWindow(bool multiple, QSettings * settings, QSharedMemory *shdme QActionGroup* modeGroup = new QActionGroup(this); ui->actionJT9_1->setActionGroup(modeGroup); - ui->actionJT9W_1->setActionGroup(modeGroup); ui->actionJT65->setActionGroup(modeGroup); ui->actionJT9_JT65->setActionGroup(modeGroup); ui->actionJT4->setActionGroup(modeGroup); @@ -509,7 +508,7 @@ MainWindow::MainWindow(bool multiple, QSettings * settings, QSharedMemory *shdme genStdMsgs(m_rpt); m_ntx=6; ui->txrb6->setChecked(true); - if(m_mode!="JT9" and m_mode!="JT9W-1" and m_mode!="JT65" and m_mode!="JT9+JT65" + if(m_mode!="JT9" and m_mode!="JT65" and m_mode!="JT9+JT65" and m_mode!="JT4" and m_mode!="WSPR-2" and m_mode!="WSPR-15" and m_mode!="Echo") m_mode="JT9"; on_actionWide_Waterfall_triggered(); //### @@ -519,7 +518,6 @@ MainWindow::MainWindow(bool multiple, QSettings * settings, QSharedMemory *shdme if(m_mode=="JT4") on_actionJT4_triggered(); if(m_mode=="JT9") on_actionJT9_1_triggered(); - if(m_mode=="JT9W-1") on_actionJT9W_1_triggered(); if(m_mode=="JT65") on_actionJT65_triggered(); if(m_mode=="JT9+JT65") on_actionJT9_JT65_triggered(); if(m_mode=="WSPR-2") on_actionWSPR_2_triggered(); @@ -576,11 +574,6 @@ MainWindow::MainWindow(bool multiple, QSettings * settings, QSharedMemory *shdme m_dialFreqRxWSPR=0; wsprNet = new WSPRNet(this); connect( wsprNet, SIGNAL(uploadStatus(QString)), this, SLOT(uploadResponse(QString))); - -//### Remove this stuff! -#if !WSJT_ENABLE_EXPERIMENTAL_FEATURES - ui->actionJT9W_1->setEnabled (false); -#endif } //--------------------------------------------------- MainWindow destructor @@ -911,8 +904,6 @@ void MainWindow::on_actionSettings_triggered() //Setup Dialog pskSetLocal (); } - if(m_mode=="JT9W-1") m_toneSpacing=pow(2,m_config.jt9w_bw_mult ())*12000.0/6912.0; - if(m_config.restart_audio_input ()) { Q_EMIT startAudioInputStream (m_config.audio_input_device (), m_framesAudioInputBuffered, m_detector, m_downSampleFactor, m_config.audio_input_channel ()); } @@ -1518,7 +1509,6 @@ void MainWindow::decode() //decode() jt9com_.ntxmode=9; if(m_modeTx=="JT65") jt9com_.ntxmode=65; jt9com_.nmode=9; - if(m_mode=="JT9W-1") jt9com_.nmode=91; if(m_mode=="JT65") jt9com_.nmode=65; if(m_mode=="JT9+JT65") jt9com_.nmode=9+65; // = 74 if(m_mode=="JT4") { @@ -1737,24 +1727,19 @@ void MainWindow::decodeBusy(bool b) //decodeBusy() if ("JT9+JT65" == m_mode) m_firstDecode = 65 + 9; showProgress = true; } - if (b && m_firstDecode != 9 && m_firstDecode != 65 + 9 && - ("JT9" == m_mode || "JT9W-1" == m_mode)) - { - m_firstDecode += 9; - showProgress = true; - } - if (showProgress) - { - // this sequence is needed to create an indeterminate progress - // bar - m_optimizingProgress.setRange (0, 1); - m_optimizingProgress.setValue (0); - m_optimizingProgress.setRange (0, 0); - } - if (!b) - { - m_optimizingProgress.reset (); - } + if (b && m_firstDecode != 9 && m_firstDecode != 65 + 9 && ("JT9" == m_mode)) { + m_firstDecode += 9; + showProgress = true; + } + if (showProgress) { + // this sequence is needed to create an indeterminate progress bar + m_optimizingProgress.setRange (0, 1); + m_optimizingProgress.setValue (0); + m_optimizingProgress.setRange (0, 0); + } + if (!b) { + m_optimizingProgress.reset (); + } m_decoderBusy=b; ui->DecodeButton->setEnabled(!b); @@ -2944,34 +2929,6 @@ void MainWindow::on_actionJT9_1_triggered() ui->label_7->setText("Rx Frequency"); } -void MainWindow::on_actionJT9W_1_triggered() -{ - m_mode="JT9W-1"; - switch_mode (Modes::JT9W_1); - if(m_modeTx!="JT9") on_pbTxMode_clicked(); - statusChanged(); - m_TRperiod=60; - m_modulator->setPeriod(m_TRperiod); // TODO - not thread safe - m_detector->setPeriod(m_TRperiod); // TODO - not thread safe - m_nsps=6912; - m_hsymStop=173; - if(m_config.decode_at_52s()) m_hsymStop=181; - m_toneSpacing=pow(2,m_config.jt9w_bw_mult ())*12000.0/6912.0; - mode_label->setStyleSheet("QLabel{background-color: #ff6ec7}"); - mode_label->setText(m_mode); - ui->ClrAvgButton->setVisible(false); - ui->actionJT9W_1->setChecked(true); - VHF_features_enabled(false); - m_wideGraph->setPeriod(m_TRperiod,m_nsps); - m_wideGraph->setMode(m_mode); - m_wideGraph->setModeTx(m_modeTx); - ui->pbTxMode->setEnabled(false); - VHF_controls_visible(false); - WSPR_config(false); - ui->label_6->setText("Band Activity"); - ui->label_7->setText("Rx Frequency"); -} - void MainWindow::on_actionJT65_triggered() { if(m_mode=="JT4" or m_mode.mid(0,4)=="WSPR") { diff --git a/mainwindow.h b/mainwindow.h index fb47ea0e0..9fd107f12 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -194,7 +194,6 @@ private slots: void on_actionAstronomical_data_triggered(); void on_actionShort_list_of_add_on_prefixes_and_suffixes_triggered(); void getpfx(); - void on_actionJT9W_1_triggered(); void band_changed (Frequency); void monitor (bool); void stop_tuning (); diff --git a/mainwindow.ui b/mainwindow.ui index 724dd9023..363b5e9c4 100644 --- a/mainwindow.ui +++ b/mainwindow.ui @@ -2329,7 +2329,6 @@ QPushButton[state="ok"] { - @@ -2656,14 +2655,6 @@ QPushButton[state="ok"] { Astronomical data - - - true - - - JT9W-1 - - Short list of add-on prefixes and suffixes