mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-22 04:11:16 -05:00
Add or fix a number of features for DXpedition Fox/Hound modes.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@8329 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
35d9e53529
commit
86a246fd33
@ -988,6 +988,7 @@ void MainWindow::writeSettings()
|
||||
m_settings->setValue ("MsgAvgDisplayed", m_msgAvgWidget && m_msgAvgWidget->isVisible());
|
||||
m_settings->setValue ("FreeText", ui->freeTextMsg->currentText ());
|
||||
m_settings->setValue("ShowMenus",ui->cbMenus->isChecked());
|
||||
m_settings->setValue("NoDupes",ui->cbNoDupes->isChecked());
|
||||
m_settings->setValue("CallFirst",ui->cbFirst->isChecked());
|
||||
m_settings->setValue("HoundSort",ui->comboBoxHoundSort->currentIndex());
|
||||
m_settings->setValue("FoxNlist",ui->sbNlist->value());
|
||||
@ -1060,6 +1061,7 @@ void MainWindow::readSettings()
|
||||
if (m_settings->contains ("FreeText")) ui->freeTextMsg->setCurrentText (
|
||||
m_settings->value ("FreeText").toString ());
|
||||
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->comboBoxHoundSort->setCurrentIndex(m_settings->value("HoundSort",3).toInt());
|
||||
ui->sbNlist->setValue(m_settings->value("FoxNlist",12).toInt());
|
||||
@ -2873,7 +2875,7 @@ void MainWindow::readFromStdout() //readFromStdout
|
||||
ui->cbFirst->setStyleSheet("");
|
||||
} else {
|
||||
//### if(m_config.bFox() and for_us and (audioFreq<1000)) bDisplayRight=true;
|
||||
if(m_config.bFox() and (audioFreq<1000)) bDisplayRight=true;
|
||||
if(m_config.bFox() and for_us and (audioFreq<1000)) bDisplayRight=true;
|
||||
if(!m_config.bFox() and (for_us or (abs(audioFreq - m_wideGraph->rxFreq()) <= 10))) bDisplayRight=true;
|
||||
}
|
||||
}
|
||||
@ -7209,8 +7211,9 @@ void MainWindow::selectHound(QString line)
|
||||
if(rpt.mid(0,1) != "-") t2="+" + rpt;
|
||||
if(t2.length()==2) t2=t2.mid(0,1) + "0" + t2.mid(1,1);
|
||||
t1=t1.mid(0,7) + t2;
|
||||
m_houndQueue.enqueue(t1); // Put this hound into the queue
|
||||
ui->textBrowser4->displayFoxToBeCalled(t1,"#ffffff"); // Add hound call and rpt to tb4
|
||||
t1=t1 + " " + houndGrid; // Append the grid
|
||||
m_houndQueue.enqueue(t1); // Put this hound into the queue
|
||||
QTextCursor cursor = ui->textBrowser4->textCursor();
|
||||
cursor.setPosition(0); // Scroll to top of list
|
||||
ui->textBrowser4->setTextCursor(cursor);
|
||||
@ -7240,7 +7243,8 @@ void MainWindow::houndCallers()
|
||||
paddedHoundCall=houndCall + " ";
|
||||
//Don't list a hound already in the queue
|
||||
if(!ui->textBrowser4->toPlainText().contains(paddedHoundCall)) {
|
||||
if(m_loggedByFox[houndCall].contains(m_lastBand)) continue; //already logged on this band
|
||||
if(m_loggedByFox[houndCall].contains(m_lastBand) and
|
||||
ui->cbNoDupes->isChecked()) continue; //already logged on this band
|
||||
bool bmatch=false;
|
||||
for(int i=0; i<m_Nslots; i++) {
|
||||
if(m_houndCall[i]==houndCall) bmatch=true;
|
||||
@ -7280,10 +7284,6 @@ void MainWindow::foxRxSequencer(DecodedText decodedtext, QString houndCall, QStr
|
||||
m_houndRptRcvd[i]=houndGrid.mid(1);
|
||||
int i1=qMax(m_foxMsgSent[i].indexOf("+"), m_foxMsgSent[i].indexOf("-"));
|
||||
m_foxMsgToBeSent[i]=m_foxMsgSent[i].mid(0,i1-1) + " RR73";
|
||||
ui->decodedTextBrowser2->displayDecodedText(decodedtext,m_baseCall,false,
|
||||
m_logBook,m_config.color_CQ(),m_config.color_MyCall(),
|
||||
m_config.color_DXCC(),m_config.color_NewCall(),m_config.ppfx());
|
||||
|
||||
} else {
|
||||
m_foxMsgToBeSent[i]=m_foxMsgSent[i];
|
||||
}
|
||||
@ -7308,13 +7308,15 @@ void MainWindow::foxTxSequencer()
|
||||
int i1=m_foxMsgToBeSent[i].indexOf(";");
|
||||
if(i1>0) m_foxMsgToBeSent[i]=m_foxMsgToBeSent[i].mid(i1+2);
|
||||
|
||||
TxTimeout:
|
||||
QString fm; //Fox message to be transmitted in this slot
|
||||
fm=m_foxMsgToBeSent[i]; //Default, if available
|
||||
if(fm=="" or fm.mid(0,3)=="CQ ") {
|
||||
if(!m_houndQueue.isEmpty()) {
|
||||
QString t=m_houndQueue.dequeue(); //Fetch new hound call from queue
|
||||
m_houndCall[i]=t.mid(0,6).trimmed(); //Save hound call for potential logging
|
||||
rm_tb4(m_houndCall[i]); //Remove him from tb4
|
||||
m_houndGrid[i]=t.mid(11,4); //Also hound grid
|
||||
rm_tb4(m_houndCall[i]); //Remove him from tb4
|
||||
QString rpt=t.mid(7,3); //Report to send him
|
||||
fm= m_houndCall[i] + " " + m_config.my_callsign() + " " + rpt; //Tx message
|
||||
} else { //If no hound in queue, we call CQ
|
||||
@ -7327,18 +7329,21 @@ void MainWindow::foxTxSequencer()
|
||||
|
||||
// Log this QSO!
|
||||
m_hisCall=m_houndCall[i];
|
||||
m_hisGrid="";
|
||||
m_hisGrid=m_houndGrid[i];
|
||||
m_rptSent=m_houndRptSent[i];
|
||||
m_rptRcvd=m_houndRptRcvd[i];
|
||||
qDebug() << "Logged by Fox:" << i << m_hisCall << m_rptSent << m_rptRcvd << m_lastBand;
|
||||
qDebug() << "Logged by Fox:" << i << m_hisCall << m_hisGrid << m_rptSent << m_rptRcvd << m_lastBand;
|
||||
on_logQSOButton_clicked();
|
||||
m_houndCall[i]="";
|
||||
m_houndGrid[i]="";
|
||||
m_loggedByFox[m_hisCall] += (m_lastBand + " ");
|
||||
|
||||
//Find someone to call next
|
||||
if(!m_houndQueue.isEmpty()) {
|
||||
QString t=m_houndQueue.dequeue(); //Fetch next hound call
|
||||
m_houndCall[i]=t.mid(0,6).trimmed();
|
||||
rm_tb4(m_houndCall[i]); //Remove the call from tb4
|
||||
QString t=m_houndQueue.dequeue(); //Fetch next hound
|
||||
m_houndCall[i]=t.mid(0,6).trimmed(); //Save hound call
|
||||
m_houndGrid[i]=t.mid(11,4); //Also hound grid
|
||||
rm_tb4(m_houndCall[i]); //Remove the call from tb4
|
||||
QString rpt=t.mid(7,3); //Report to send him
|
||||
fm=fm.mid(0,6) + " RR73; " + m_houndCall[i] + " <" + m_config.my_callsign() +
|
||||
"> " + rpt;
|
||||
@ -7356,6 +7361,16 @@ void MainWindow::foxTxSequencer()
|
||||
m_houndCall0[i]=m_houndCall[i];
|
||||
m_nFoxMsgTimes[i]++;
|
||||
|
||||
// Check for Tx message timeout
|
||||
if(ui->sbMaxRepeats->value() > 0 and m_nFoxMsgTimes[i] > ui->sbMaxRepeats->value()
|
||||
and !fm.contains("CQ ")) {
|
||||
m_houndCall[i]="";
|
||||
m_houndGrid[i]="";
|
||||
m_nFoxMsgTimes[i]=0;
|
||||
m_foxMsgToBeSent[i]="";
|
||||
goto TxTimeout;
|
||||
}
|
||||
|
||||
//Send Tx message to right window
|
||||
fm += " ";
|
||||
fm=fm.mid(0,32);
|
||||
|
213
mainwindow.ui
213
mainwindow.ui
@ -1049,7 +1049,7 @@ QLabel[oob="true"] {
|
||||
<enum>QTabWidget::Triangular</enum>
|
||||
</property>
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
<number>2</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="tab">
|
||||
<attribute name="title">
|
||||
@ -1625,6 +1625,85 @@ list. The list can be maintained in Settings (F2).</string>
|
||||
<layout class="QGridLayout" name="gridLayout_11">
|
||||
<item row="0" column="1" rowspan="2">
|
||||
<layout class="QGridLayout" name="gridLayout_10">
|
||||
<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>5</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QPushButton" name="pbFoxReset">
|
||||
<property name="text">
|
||||
<string>Reset</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QSpinBox" name="sbNlist">
|
||||
<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="prefix">
|
||||
<string>N List </string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>100</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>12</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="0">
|
||||
<spacer name="verticalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QComboBox" name="comboBoxCQ">
|
||||
<item>
|
||||
@ -1719,6 +1798,34 @@ list. The list can be maintained in Settings (F2).</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QSpinBox" name="sbMax_dB">
|
||||
<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="prefix">
|
||||
<string>Max dB </string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>-15</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>30</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>30</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QComboBox" name="comboBoxHoundSort">
|
||||
<property name="sizePolicy">
|
||||
@ -1766,34 +1873,6 @@ list. The list can be maintained in Settings (F2).</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QSpinBox" name="sbMax_dB">
|
||||
<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="prefix">
|
||||
<string>Max dB </string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>-15</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>30</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>30</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QSpinBox" name="sbMaxRepeats">
|
||||
<property name="sizePolicy">
|
||||
@ -1822,82 +1901,10 @@ list. The list can be maintained in Settings (F2).</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QSpinBox" name="sbNlist">
|
||||
<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="prefix">
|
||||
<string>N List </string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>100</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>12</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<spacer name="verticalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</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>5</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QPushButton" name="pbFoxReset">
|
||||
<widget class="QCheckBox" name="cbNoDupes">
|
||||
<property name="text">
|
||||
<string>Reset</string>
|
||||
<string>No Dupes</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
|
Loading…
Reference in New Issue
Block a user