mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-25 05:38:46 -05:00
Remove unnecessary Fox controls; write debugging info to the file FoxQSO.txt.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@8554 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
5cdc4b7848
commit
2453ee3d07
@ -1006,13 +1006,11 @@ void MainWindow::writeSettings()
|
|||||||
m_settings->setValue ("MsgAvgDisplayed", m_msgAvgWidget && m_msgAvgWidget->isVisible());
|
m_settings->setValue ("MsgAvgDisplayed", m_msgAvgWidget && m_msgAvgWidget->isVisible());
|
||||||
m_settings->setValue ("FreeText", ui->freeTextMsg->currentText ());
|
m_settings->setValue ("FreeText", ui->freeTextMsg->currentText ());
|
||||||
m_settings->setValue("ShowMenus",ui->cbMenus->isChecked());
|
m_settings->setValue("ShowMenus",ui->cbMenus->isChecked());
|
||||||
m_settings->setValue("NoDupes",ui->cbNoDupes->isChecked());
|
|
||||||
m_settings->setValue("CallFirst",ui->cbFirst->isChecked());
|
m_settings->setValue("CallFirst",ui->cbFirst->isChecked());
|
||||||
m_settings->setValue("HoundSort",ui->comboBoxHoundSort->currentIndex());
|
m_settings->setValue("HoundSort",ui->comboBoxHoundSort->currentIndex());
|
||||||
m_settings->setValue("FoxNlist",ui->sbNlist->value());
|
m_settings->setValue("FoxNlist",ui->sbNlist->value());
|
||||||
m_settings->setValue("FoxNslots",ui->sbNslots->value());
|
m_settings->setValue("FoxNslots",ui->sbNslots->value());
|
||||||
m_settings->setValue("FoxMaxDB",ui->sbMax_dB->value());
|
m_settings->setValue("FoxMaxDB",ui->sbMax_dB->value());
|
||||||
m_settings->setValue("FoxMaxCalls",ui->sbMaxCalls->value());
|
|
||||||
m_settings->endGroup();
|
m_settings->endGroup();
|
||||||
|
|
||||||
m_settings->beginGroup("Common");
|
m_settings->beginGroup("Common");
|
||||||
@ -1080,13 +1078,11 @@ void MainWindow::readSettings()
|
|||||||
if (m_settings->contains ("FreeText")) ui->freeTextMsg->setCurrentText (
|
if (m_settings->contains ("FreeText")) ui->freeTextMsg->setCurrentText (
|
||||||
m_settings->value ("FreeText").toString ());
|
m_settings->value ("FreeText").toString ());
|
||||||
ui->cbMenus->setChecked(m_settings->value("ShowMenus",true).toBool());
|
ui->cbMenus->setChecked(m_settings->value("ShowMenus",true).toBool());
|
||||||
ui->cbNoDupes->setChecked(m_settings->value("NoDupes",true).toBool());
|
|
||||||
ui->cbFirst->setChecked(m_settings->value("CallFirst",true).toBool());
|
ui->cbFirst->setChecked(m_settings->value("CallFirst",true).toBool());
|
||||||
ui->comboBoxHoundSort->setCurrentIndex(m_settings->value("HoundSort",3).toInt());
|
ui->comboBoxHoundSort->setCurrentIndex(m_settings->value("HoundSort",3).toInt());
|
||||||
ui->sbNlist->setValue(m_settings->value("FoxNlist",12).toInt());
|
ui->sbNlist->setValue(m_settings->value("FoxNlist",12).toInt());
|
||||||
ui->sbNslots->setValue(m_settings->value("FoxNslots",5).toInt());
|
ui->sbNslots->setValue(m_settings->value("FoxNslots",5).toInt());
|
||||||
ui->sbMax_dB->setValue(m_settings->value("FoxMaxDB",30).toInt());
|
ui->sbMax_dB->setValue(m_settings->value("FoxMaxDB",30).toInt());
|
||||||
ui->sbMaxCalls->setValue(m_settings->value("FoxMaxCalls",4).toInt());
|
|
||||||
m_settings->endGroup();
|
m_settings->endGroup();
|
||||||
|
|
||||||
// do this outside of settings group because it uses groups internally
|
// do this outside of settings group because it uses groups internally
|
||||||
@ -7407,6 +7403,7 @@ void MainWindow::selectHound(QString line)
|
|||||||
ui->textBrowser4->displayFoxToBeCalled(t1,"#ffffff"); // Add hound call and rpt to tb4
|
ui->textBrowser4->displayFoxToBeCalled(t1,"#ffffff"); // Add hound call and rpt to tb4
|
||||||
t1=t1 + " " + houndGrid; // Append the grid
|
t1=t1 + " " + houndGrid; // Append the grid
|
||||||
m_houndQueue.enqueue(t1); // Put this hound into the queue
|
m_houndQueue.enqueue(t1); // Put this hound into the queue
|
||||||
|
writeFoxQSO(" Sel: " + t1);
|
||||||
QTextCursor cursor = ui->textBrowser4->textCursor();
|
QTextCursor cursor = ui->textBrowser4->textCursor();
|
||||||
cursor.setPosition(0); // Scroll to top of list
|
cursor.setPosition(0); // Scroll to top of list
|
||||||
ui->textBrowser4->setTextCursor(cursor);
|
ui->textBrowser4->setTextCursor(cursor);
|
||||||
@ -7442,8 +7439,7 @@ void MainWindow::houndCallers()
|
|||||||
paddedHoundCall=houndCall + " ";
|
paddedHoundCall=houndCall + " ";
|
||||||
//Don't list a hound already in the queue
|
//Don't list a hound already in the queue
|
||||||
if(!ui->textBrowser4->toPlainText().contains(paddedHoundCall)) {
|
if(!ui->textBrowser4->toPlainText().contains(paddedHoundCall)) {
|
||||||
if(m_loggedByFox[houndCall].contains(m_lastBand) and
|
if(m_loggedByFox[houndCall].contains(m_lastBand)) continue; //already logged on this band
|
||||||
ui->cbNoDupes->isChecked()) continue; //already logged on this band
|
|
||||||
if(m_foxQSO.contains(houndCall)) continue; //still in the QSO map
|
if(m_foxQSO.contains(houndCall)) continue; //still in the QSO map
|
||||||
QString countryName,continent;
|
QString countryName,continent;
|
||||||
bool callWorkedBefore,countryWorkedBefore;
|
bool callWorkedBefore,countryWorkedBefore;
|
||||||
@ -7492,11 +7488,11 @@ void MainWindow::foxRxSequencer(QString msg, QString houndCall, QString rptRcvd)
|
|||||||
*/
|
*/
|
||||||
// qDebug() << "foxRxSeq1" << houndCall << rptRcvd << m_foxQSO.contains(houndCall);
|
// qDebug() << "foxRxSeq1" << houndCall << rptRcvd << m_foxQSO.contains(houndCall);
|
||||||
if(m_foxQSO.contains(houndCall)) {
|
if(m_foxQSO.contains(houndCall)) {
|
||||||
if(m_foxQSO[houndCall].ncall <= ui->sbMaxCalls->value()) { //### Not sure about "<=" ###
|
if(m_foxQSO[houndCall].ncall <= qMax(4,m_Nslots+1)) { //### Not sure about "<=" ###
|
||||||
m_foxQSO[houndCall].rcvd=rptRcvd.mid(1); //Save Fox's report for the log
|
m_foxQSO[houndCall].rcvd=rptRcvd.mid(1); //Save Fox's report for the log
|
||||||
// qDebug() << "foxRxSeq2" << houndCall << rptRcvd << m_foxQSO[houndCall].ncall;
|
// qDebug() << "foxRxSeq2" << houndCall << rptRcvd << m_foxQSO[houndCall].ncall;
|
||||||
m_foxRR73Queue.enqueue(houndCall); //Request RR73 to be sent to Hound
|
m_foxRR73Queue.enqueue(houndCall); //Request RR73 to be sent to Hound
|
||||||
writeFoxQSO(" " + msg.trimmed());
|
writeFoxQSO(" Rx: " + msg.trimmed());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -7549,6 +7545,7 @@ void MainWindow::foxTxSequencer()
|
|||||||
m_msgAvgWidget->foxAddLog(logLine);
|
m_msgAvgWidget->foxAddLog(logLine);
|
||||||
}
|
}
|
||||||
on_logQSOButton_clicked();
|
on_logQSOButton_clicked();
|
||||||
|
writeFoxQSO(" Log: " + logLine.mid(17));
|
||||||
|
|
||||||
m_foxRateQueue.enqueue(now); //Add present time in seconds to Rate queue.
|
m_foxRateQueue.enqueue(now); //Add present time in seconds to Rate queue.
|
||||||
m_loggedByFox[hc1] += (m_lastBand + " ");
|
m_loggedByFox[hc1] += (m_lastBand + " ");
|
||||||
@ -7614,8 +7611,7 @@ Transmit:
|
|||||||
|
|
||||||
for(auto a: m_foxQSO.keys()) {
|
for(auto a: m_foxQSO.keys()) {
|
||||||
int ncalls=m_foxQSO[a].ncall;
|
int ncalls=m_foxQSO[a].ncall;
|
||||||
// qDebug() << "ncalls: " << a << ncalls << ui->sbMaxCalls->value();
|
if(ncalls >= qMax(4,m_Nslots+1)) { //### Not sure about ">=" ###
|
||||||
if(ncalls >= ui->sbMaxCalls->value()) { //### Not sure about ">=" ###
|
|
||||||
m_foxQSO.remove(a);
|
m_foxQSO.remove(a);
|
||||||
m_foxQSOqueue.removeOne(a);
|
m_foxQSOqueue.removeOne(a);
|
||||||
if(m_foxRR73Queue.contains(a)) m_foxRR73Queue.removeOne(a);
|
if(m_foxRR73Queue.contains(a)) m_foxRR73Queue.removeOne(a);
|
||||||
@ -7627,8 +7623,6 @@ Transmit:
|
|||||||
m_foxRateQueue.dequeue();
|
m_foxRateQueue.dequeue();
|
||||||
}
|
}
|
||||||
m_msgAvgWidget->foxLabRate(m_foxRateQueue.size());
|
m_msgAvgWidget->foxLabRate(m_foxRateQueue.size());
|
||||||
|
|
||||||
qDebug() << "QSOs in progress:" << m_foxQSOqueue.count();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::rm_tb4(QString houndCall)
|
void MainWindow::rm_tb4(QString houndCall)
|
||||||
@ -7687,11 +7681,14 @@ void MainWindow::foxGenWaveform(int i,QString fm)
|
|||||||
|
|
||||||
void MainWindow::writeFoxQSO(QString msg)
|
void MainWindow::writeFoxQSO(QString msg)
|
||||||
{
|
{
|
||||||
|
QString t;
|
||||||
|
t.sprintf("%3d%3d%3d",m_houndQueue.count(),m_foxQSOqueue.count(),m_foxRR73Queue.count());
|
||||||
QFile f {m_config.writeable_data_dir ().absoluteFilePath ("FoxQSO.txt")};
|
QFile f {m_config.writeable_data_dir ().absoluteFilePath ("FoxQSO.txt")};
|
||||||
if (f.open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Append)) {
|
if (f.open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Append)) {
|
||||||
QTextStream out(&f);
|
QTextStream out(&f);
|
||||||
out << QDateTime::currentDateTimeUtc().toString("yyyy-MM-dd hh:mm:ss")
|
out << QDateTime::currentDateTimeUtc().toString("yyyy-MM-dd hh:mm:ss")
|
||||||
<< " " << fixed << qSetRealNumberPrecision (4) << (m_freqNominal/1.e6) << msg << endl;
|
<< " " << fixed << qSetRealNumberPrecision (3) << (m_freqNominal/1.e6)
|
||||||
|
<< t << msg << endl;
|
||||||
f.close();
|
f.close();
|
||||||
} else {
|
} else {
|
||||||
MessageBox::warning_message (this, tr("File Open Error"),
|
MessageBox::warning_message (this, tr("File Open Error"),
|
||||||
|
@ -1599,47 +1599,13 @@ list. The list can be maintained in Settings (F2).</string>
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="6" column="0">
|
<item row="5" column="0">
|
||||||
<widget class="QPushButton" name="pbFoxReset">
|
<widget class="QPushButton" name="pbFoxReset">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Reset</string>
|
<string>Reset</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QSpinBox" name="sbNslots">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>16777215</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="suffix">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
<property name="prefix">
|
|
||||||
<string>N Slots </string>
|
|
||||||
</property>
|
|
||||||
<property name="minimum">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>5</number>
|
|
||||||
</property>
|
|
||||||
<property name="value">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="displayIntegerBase">
|
|
||||||
<number>10</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0">
|
<item row="2" column="0">
|
||||||
<widget class="QSpinBox" name="sbMax_dB">
|
<widget class="QSpinBox" name="sbMax_dB">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
@ -1668,7 +1634,7 @@ list. The list can be maintained in Settings (F2).</string>
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="5" column="0">
|
<item row="4" column="0">
|
||||||
<widget class="QComboBox" name="comboBoxCQ">
|
<widget class="QComboBox" name="comboBoxCQ">
|
||||||
<item>
|
<item>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@ -1762,21 +1728,8 @@ list. The list can be maintained in Settings (F2).</string>
|
|||||||
</item>
|
</item>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="7" column="0">
|
<item row="3" column="0">
|
||||||
<widget class="QCheckBox" name="cbNoDupes">
|
<widget class="QSpinBox" name="sbNslots">
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>No Dupes</string>
|
|
||||||
</property>
|
|
||||||
<property name="checked">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="0">
|
|
||||||
<widget class="QSpinBox" name="sbMaxCalls">
|
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -1789,17 +1742,23 @@ list. The list can be maintained in Settings (F2).</string>
|
|||||||
<height>16777215</height>
|
<height>16777215</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="suffix">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
<property name="prefix">
|
<property name="prefix">
|
||||||
<string>Max Calls </string>
|
<string>N Slots </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimum">
|
<property name="minimum">
|
||||||
<number>1</number>
|
<number>1</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="maximum">
|
<property name="maximum">
|
||||||
<number>10</number>
|
<number>5</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="value">
|
<property name="value">
|
||||||
<number>4</number>
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="displayIntegerBase">
|
||||||
|
<number>10</number>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@ -1850,6 +1809,19 @@ list. The list can be maintained in Settings (F2).</string>
|
|||||||
</item>
|
</item>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="6" column="0">
|
||||||
|
<spacer name="verticalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Vertical</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>20</width>
|
||||||
|
<height>40</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
|
Loading…
Reference in New Issue
Block a user