1. Capitalize names of palettes appropriately.

2. Remove (or comment out) most qDebug() statements.
3. Swap positions of labels 2 and 3 on status bar.
4. In "Split Tx" mode, transmit audio always between 1500 and 2000 Hz.
5. Rearrange positions of WideGraph controls.



git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@3535 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Joe Taylor 2013-08-08 14:26:53 +00:00
parent 47c4245984
commit a114b8c9ea
35 changed files with 154 additions and 151 deletions

View File

@ -66,8 +66,7 @@ void Modulator::send (unsigned symbolsLength, double framesPerSymbol, unsigned f
m_silentFrames = m_ic + m_frameRate - (mstr * m_frameRate / 1000); m_silentFrames = m_ic + m_frameRate - (mstr * m_frameRate / 1000);
} }
qDebug () << "Modulator: starting at " << m_ic / m_frameRate << " sec, sending " << m_silentFrames << " silent frames"; // qDebug () << "Modulator: starting at " << m_ic / m_frameRate << " sec, sending " << m_silentFrames << " silent frames";
Q_EMIT stateChanged ((m_state = (synchronize && m_silentFrames) ? Synchronizing : Active)); Q_EMIT stateChanged ((m_state = (synchronize && m_silentFrames) ? Synchronizing : Active));
} }
@ -79,7 +78,7 @@ qint64 Modulator::readData (char * data, qint64 maxSize)
frame_t * frames (reinterpret_cast<frame_t *> (data)); frame_t * frames (reinterpret_cast<frame_t *> (data));
qint64 numFrames (maxSize / sizeof (frame_t)); qint64 numFrames (maxSize / sizeof (frame_t));
qDebug () << "Modulator: " << numFrames << " requested, m_ic = " << m_ic << ", tune mode is " << m_tuning; // qDebug () << "Modulator: " << numFrames << " requested, m_ic = " << m_ic << ", tune mode is " << m_tuning;
switch (m_state) switch (m_state)
{ {

View File

@ -16,10 +16,11 @@ void LogBook::init()
_setAlreadyWorkedFromLog(); _setAlreadyWorkedFromLog();
/*
int QSOcount = _log.getCount(); int QSOcount = _log.getCount();
int count = _worked.getWorkedCount(); int count = _worked.getWorkedCount();
qDebug() << QSOcount << "QSOs and" << count << "countries worked in file" << logFilename; qDebug() << QSOcount << "QSOs and" << count << "countries worked in file" << logFilename;
*/
} }

View File

@ -1027,15 +1027,16 @@ void MainWindow::createStatusBar() //createStatusBar
lab1->setFrameStyle(QFrame::Panel | QFrame::Sunken); lab1->setFrameStyle(QFrame::Panel | QFrame::Sunken);
statusBar()->addWidget(lab1); statusBar()->addWidget(lab1);
lab2 = new QLabel(""); lab2 = new QLabel("");
lab2->setAlignment(Qt::AlignHCenter); lab2->setAlignment(Qt::AlignHCenter);
lab2->setMinimumSize(QSize(150,18)); lab2->setMinimumSize(QSize(80,18));
lab2->setFrameStyle(QFrame::Panel | QFrame::Sunken); lab2->setFrameStyle(QFrame::Panel | QFrame::Sunken);
statusBar()->addWidget(lab2); statusBar()->addWidget(lab2);
lab3 = new QLabel(""); lab3 = new QLabel("");
lab3->setAlignment(Qt::AlignHCenter); lab3->setAlignment(Qt::AlignHCenter);
lab3->setMinimumSize(QSize(80,18)); lab3->setMinimumSize(QSize(150,18));
lab3->setFrameStyle(QFrame::Panel | QFrame::Sunken); lab3->setFrameStyle(QFrame::Panel | QFrame::Sunken);
statusBar()->addWidget(lab3); statusBar()->addWidget(lab3);
} }
@ -1672,7 +1673,7 @@ void MainWindow::guiUpdate()
msgsent[22]=0; msgsent[22]=0;
QString t=QString::fromLatin1(msgsent); QString t=QString::fromLatin1(msgsent);
if(m_tune) t="TUNE"; if(m_tune) t="TUNE";
lab2->setText("Last Tx: " + t); lab3->setText("Last Tx: " + t);
if(m_restart) { if(m_restart) {
QFile f("ALL.TXT"); QFile f("ALL.TXT");
f.open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Append); f.open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Append);
@ -2506,8 +2507,8 @@ void MainWindow::on_actionJT9_1_triggered()
m_TRperiod=60; m_TRperiod=60;
m_nsps=6912; m_nsps=6912;
m_hsymStop=173; m_hsymStop=173;
lab3->setStyleSheet("QLabel{background-color: #ff6ec7}"); lab2->setStyleSheet("QLabel{background-color: #ff6ec7}");
lab3->setText(m_mode); lab2->setText(m_mode);
ui->actionJT9_1->setChecked(true); ui->actionJT9_1->setChecked(true);
g_pWideGraph->setPeriod(m_TRperiod,m_nsps); g_pWideGraph->setPeriod(m_TRperiod,m_nsps);
g_pWideGraph->setMode(m_mode); g_pWideGraph->setMode(m_mode);
@ -2523,8 +2524,8 @@ void MainWindow::on_actionJT65_triggered()
m_TRperiod=60; m_TRperiod=60;
m_nsps=6912; //For symspec only m_nsps=6912; //For symspec only
m_hsymStop=173; m_hsymStop=173;
lab3->setStyleSheet("QLabel{background-color: #ffff00}"); lab2->setStyleSheet("QLabel{background-color: #ffff00}");
lab3->setText(m_mode); lab2->setText(m_mode);
ui->actionJT65->setChecked(true); ui->actionJT65->setChecked(true);
g_pWideGraph->setPeriod(m_TRperiod,m_nsps); g_pWideGraph->setPeriod(m_TRperiod,m_nsps);
g_pWideGraph->setMode(m_mode); g_pWideGraph->setMode(m_mode);
@ -2540,8 +2541,8 @@ void MainWindow::on_actionJT9_JT65_triggered()
m_TRperiod=60; m_TRperiod=60;
m_nsps=6912; m_nsps=6912;
m_hsymStop=173; m_hsymStop=173;
lab3->setStyleSheet("QLabel{background-color: #ffa500}"); lab2->setStyleSheet("QLabel{background-color: #ffa500}");
lab3->setText(m_mode); lab2->setText(m_mode);
ui->actionJT9_JT65->setChecked(true); ui->actionJT9_JT65->setChecked(true);
g_pWideGraph->setPeriod(m_TRperiod,m_nsps); g_pWideGraph->setPeriod(m_TRperiod,m_nsps);
g_pWideGraph->setMode(m_mode); g_pWideGraph->setMode(m_mode);
@ -3011,11 +3012,7 @@ void MainWindow::setXIT(int n)
int ret; int ret;
m_XIT = 0; m_XIT = 0;
if(m_bRigOpen) { if(m_bRigOpen) {
m_XIT=-1000; m_XIT=(n/500)*500 - 1500;
if(n>1000) m_XIT=0;
if(n>2000) m_XIT=1000;
if(n>3000) m_XIT=2000;
if(n>4000) m_XIT=3000;
if(m_bXIT) { if(m_bXIT) {
ret=rig->setXit((shortfreq_t)m_XIT,RIG_VFO_TX); ret=rig->setXit((shortfreq_t)m_XIT,RIG_VFO_TX);
if(ret!=RIG_OK) { if(ret!=RIG_OK) {

View File

@ -69,13 +69,8 @@ bool SoundInput::start(QAudioDeviceInfo const& device, int framesPerBuffer, QIOD
} }
connect (m_stream.data(), &QAudioInput::stateChanged, this, &SoundInput::handleStateChanged); connect (m_stream.data(), &QAudioInput::stateChanged, this, &SoundInput::handleStateChanged);
m_stream->setBufferSize (m_stream->format ().bytesForFrames (framesPerBuffer)); m_stream->setBufferSize (m_stream->format ().bytesForFrames (framesPerBuffer));
m_stream->start (sink); m_stream->start (sink);
qDebug () << "audio input buffer size = " << m_stream->bufferSize () << " bytes";
return audioError () ? false : true; return audioError () ? false : true;
} }
@ -84,29 +79,24 @@ void SoundInput::handleStateChanged (QAudio::State newState) const
switch (newState) switch (newState)
{ {
case QAudio::IdleState: case QAudio::IdleState:
qDebug () << "SoundInput idle";
Q_EMIT status (tr ("Idle")); Q_EMIT status (tr ("Idle"));
break; break;
case QAudio::ActiveState: case QAudio::ActiveState:
qDebug () << "SoundInput active";
Q_EMIT status (tr ("Receiving")); Q_EMIT status (tr ("Receiving"));
break; break;
case QAudio::SuspendedState: case QAudio::SuspendedState:
qDebug () << "SoundInput suspended";
Q_EMIT status (tr ("Suspended")); Q_EMIT status (tr ("Suspended"));
break; break;
case QAudio::StoppedState: case QAudio::StoppedState:
if (audioError ()) if (audioError ())
{ {
qDebug () << "SoundInput error";
Q_EMIT status (tr ("Error")); Q_EMIT status (tr ("Error"));
} }
else else
{ {
qDebug () << "SoundInput stopped";
Q_EMIT status (tr ("Stopped")); Q_EMIT status (tr ("Stopped"));
} }
break; break;

View File

@ -101,8 +101,6 @@ void SoundOutput::startStream (QAudioDeviceInfo const& device)
m_stream->setBufferSize (m_stream->format ().bytesForDuration (MS_BUFFERED * 1000)); m_stream->setBufferSize (m_stream->format ().bytesForDuration (MS_BUFFERED * 1000));
m_stream->start (m_source); m_stream->start (m_source);
audioError (); audioError ();
qDebug () << "audio output buffer size = " << m_stream->bufferSize () << " bytes";
} }
void SoundOutput::suspend () void SoundOutput::suspend ()
@ -137,25 +135,21 @@ void SoundOutput::handleStateChanged (QAudio::State newState)
switch (newState) switch (newState)
{ {
case QAudio::IdleState: case QAudio::IdleState:
qDebug () << "SoundOutput: entered Idle state";
Q_EMIT status (tr ("Idle")); Q_EMIT status (tr ("Idle"));
m_active = false; m_active = false;
break; break;
case QAudio::ActiveState: case QAudio::ActiveState:
qDebug () << "SoundOutput: entered Active state";
m_active = true; m_active = true;
Q_EMIT status (tr ("Sending")); Q_EMIT status (tr ("Sending"));
break; break;
case QAudio::SuspendedState: case QAudio::SuspendedState:
qDebug () << "SoundOutput: entered Suspended state";
m_active = true; m_active = true;
Q_EMIT status (tr ("Suspended")); Q_EMIT status (tr ("Suspended"));
break; break;
case QAudio::StoppedState: case QAudio::StoppedState:
qDebug () << "SoundOutput: entered Stopped state";
m_active = false; m_active = false;
if (audioError ()) if (audioError ())
{ {

View File

@ -52,92 +52,17 @@
</item> </item>
<item> <item>
<layout class="QGridLayout" name="gridLayout"> <layout class="QGridLayout" name="gridLayout">
<item row="0" column="0"> <item row="0" column="6">
<spacer name="horizontalSpacer"> <widget class="QLabel" name="labPalette">
<property name="orientation"> <property name="text">
<enum>Qt::Horizontal</enum> <string>Palette</string>
</property> </property>
<property name="sizeHint" stdset="0"> <property name="alignment">
<size> <set>Qt::AlignCenter</set>
<width>40</width>
<height>20</height>
</size>
</property> </property>
</spacer> </widget>
</item> </item>
<item row="0" column="3"> <item row="0" column="3">
<widget class="QSpinBox" name="waterfallAvgSpinBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>38</width>
<height>16777215</height>
</size>
</property>
<property name="toolTip">
<string>Number of FFTs averaged (controls waterfall scrolling rate)</string>
</property>
<property name="prefix">
<string>N Avg </string>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>20</number>
</property>
</widget>
</item>
<item row="0" column="6">
<widget class="QDoubleSpinBox" name="slopeSpinBox">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="prefix">
<string>Slope </string>
</property>
<property name="decimals">
<number>1</number>
</property>
<property name="minimum">
<double>-2.000000000000000</double>
</property>
<property name="maximum">
<double>2.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
</widget>
</item>
<item row="0" column="7">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="5">
<widget class="QSpinBox" name="zeroSpinBox"> <widget class="QSpinBox" name="zeroSpinBox">
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
@ -168,6 +93,60 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="3">
<widget class="QSpinBox" name="gainSpinBox">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>38</width>
<height>16777215</height>
</size>
</property>
<property name="toolTip">
<string>Scaling (dB) applied to spectra before plotting</string>
</property>
<property name="prefix">
<string>Gain </string>
</property>
<property name="minimum">
<number>-20</number>
</property>
<property name="maximum">
<number>20</number>
</property>
</widget>
</item>
<item row="0" column="0">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="7">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="2"> <item row="0" column="2">
<widget class="QSpinBox" name="fStartSpinBox"> <widget class="QSpinBox" name="fStartSpinBox">
<property name="sizePolicy"> <property name="sizePolicy">
@ -276,7 +255,85 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="6">
<widget class="QComboBox" name="paletteComboBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Select waterfall palette</string>
</property>
</widget>
</item>
<item row="1" column="2"> <item row="1" column="2">
<widget class="QDoubleSpinBox" name="slopeSpinBox">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="prefix">
<string>Slope </string>
</property>
<property name="decimals">
<number>1</number>
</property>
<property name="minimum">
<double>-2.000000000000000</double>
</property>
<property name="maximum">
<double>2.000000000000000</double>
</property>
<property name="singleStep">
<double>0.100000000000000</double>
</property>
</widget>
</item>
<item row="0" column="4">
<widget class="QSpinBox" name="waterfallAvgSpinBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>38</width>
<height>16777215</height>
</size>
</property>
<property name="toolTip">
<string>Number of FFTs averaged (controls waterfall scrolling rate)</string>
</property>
<property name="prefix">
<string>N Avg </string>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>20</number>
</property>
</widget>
</item>
<item row="1" column="4">
<widget class="QComboBox" name="spec2dComboBox"> <widget class="QComboBox" name="spec2dComboBox">
<property name="toolTip"> <property name="toolTip">
<string>Select data for display curve</string> <string>Select data for display curve</string>
@ -296,41 +353,6 @@
</item> </item>
</widget> </widget>
</item> </item>
<item row="1" column="3">
<widget class="QComboBox" name="paletteComboBox">
<property name="toolTip">
<string>Select waterfall palette</string>
</property>
</widget>
</item>
<item row="1" column="5">
<widget class="QSpinBox" name="gainSpinBox">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>38</width>
<height>16777215</height>
</size>
</property>
<property name="toolTip">
<string>Scaling (dB) applied to spectra before plotting</string>
</property>
<property name="prefix">
<string>Gain </string>
</property>
<property name="minimum">
<number>-20</number>
</property>
<property name="maximum">
<number>20</number>
</property>
</widget>
</item>
</layout> </layout>
</item> </item>
</layout> </layout>