Updated N3FJP integration to send the correct data

This commit is contained in:
Jordan Sherer 2019-06-02 13:25:31 -04:00
parent fd29d6a931
commit 88455247a4
3 changed files with 14 additions and 9 deletions

View File

@ -23,7 +23,7 @@
<string>Select tab to change configuration parameters.</string>
</property>
<property name="currentIndex">
<number>3</number>
<number>0</number>
</property>
<widget class="QWidget" name="general_tab">
<attribute name="title">
@ -36,7 +36,7 @@
<item>
<widget class="QTabWidget" name="tabWidget_2">
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<widget class="QWidget" name="stationTab">
<attribute name="title">
@ -62,8 +62,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>587</width>
<height>303</height>
<width>738</width>
<height>453</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
@ -4291,11 +4291,11 @@ soundcard changes</string>
</connections>
<buttongroups>
<buttongroup name="PTT_method_button_group"/>
<buttongroup name="TX_audio_source_button_group"/>
<buttongroup name="CAT_data_bits_button_group"/>
<buttongroup name="split_mode_button_group"/>
<buttongroup name="CAT_handshake_button_group"/>
<buttongroup name="CAT_stop_bits_button_group"/>
<buttongroup name="TX_audio_source_button_group"/>
<buttongroup name="TX_mode_button_group"/>
<buttongroup name="CAT_data_bits_button_group"/>
<buttongroup name="CAT_stop_bits_button_group"/>
</buttongroups>
</ui>

View File

@ -87,6 +87,7 @@ void LogQSO::initLogQSO(QString const& hisCall, QString const& hisGrid, QString
bool toDATA, bool dBtoComments, bool bFox, QString const& opCall, QString const& comments)
{
if(!isHidden()) return;
ui->call->setFocus();
ui->call->setText(hisCall);
ui->grid->setText(hisGrid);
ui->name->setText("");

View File

@ -6669,13 +6669,15 @@ void MainWindow::acceptQSO (QDateTime const& QSO_date_off, QString const& call,
"<fldDateStr>%1</fldDateStr>"
"<fldTimeOnStr>%2</fldTimeOnStr>"
"<fldCall>%3</fldCall>"
"<fldGrid>%4</fldGrid>"
"<fldGridR>%4</fldGridR>"
"<fldBand>%5</fldBand>"
"<fldFrequency>%6</fldFrequency>"
"<fldMode>JS8</fldMode>"
"<fldOperator>%7</fldOperator>"
"<fldNameR>%8</fldNameR>"
"<fldComments>%9</fldComments>"
"<fldRstS>%10</fldRstS>"
"<fldRstR>%11</fldRstR>"
"</CMD>");
data = data.arg(QSO_date_on.toString("yyyy/MM/dd"));
@ -6687,13 +6689,15 @@ void MainWindow::acceptQSO (QDateTime const& QSO_date_off, QString const& call,
data = data.arg(operator_call);
data = data.arg(name);
data = data.arg(comments);
data = data.arg(rpt_sent);
data = data.arg(rpt_received);
auto host = m_config.n3fjp_server_name();
auto port = m_config.n3fjp_server_port();
m_n3fjpClient->sendNetworkMessage(host, port, data.toLocal8Bit());
QTimer::singleShot(1000, this, [this, host, port](){
QTimer::singleShot(300, this, [this, host, port](){
m_n3fjpClient->sendNetworkMessage(host, port, "<CMD><CHECKLOG></CMD>");
m_n3fjpClient->sendNetworkMessage(host, port, "\r\n");
});