Added hashed message with ack
This commit is contained in:
parent
5f3ca913b7
commit
b7b7167d85
@ -5996,8 +5996,6 @@ QStringList MainWindow::buildFT8MessageFrames(QString const& text){
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
frames.append(frame);
|
|
||||||
|
|
||||||
// to compound callsign
|
// to compound callsign
|
||||||
if(!dirTo.isEmpty() && dirTo.contains("/")){
|
if(!dirTo.isEmpty() && dirTo.contains("/")){
|
||||||
QString compoundMessage = QString("<%1>").arg(dirTo);
|
QString compoundMessage = QString("<%1>").arg(dirTo);
|
||||||
@ -6007,6 +6005,8 @@ QStringList MainWindow::buildFT8MessageFrames(QString const& text){
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
frames.append(frame);
|
||||||
|
|
||||||
line = line.mid(n);
|
line = line.mid(n);
|
||||||
|
|
||||||
// generate a checksum for buffered commands with line data
|
// generate a checksum for buffered commands with line data
|
||||||
@ -6017,7 +6017,8 @@ QStringList MainWindow::buildFT8MessageFrames(QString const& text){
|
|||||||
line = lstrip(line);
|
line = lstrip(line);
|
||||||
|
|
||||||
qDebug() << "before:" << line;
|
qDebug() << "before:" << line;
|
||||||
if(dirCmd == "#"){
|
bool shouldUseLargeChecksum = false;
|
||||||
|
if(shouldUseLargeChecksum && dirCmd == "#"){
|
||||||
line = line + " " + Varicode::checksum32(line);
|
line = line + " " + Varicode::checksum32(line);
|
||||||
} else {
|
} else {
|
||||||
line = line + " " + Varicode::checksum16(line);
|
line = line + " " + Varicode::checksum16(line);
|
||||||
@ -7535,6 +7536,18 @@ void MainWindow::buildQueryMenu(QMenu * menu){
|
|||||||
toggleTx(true);
|
toggleTx(true);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
auto hashAction = menu->addAction("#message - Please ACK if you receive this message in its entirety");
|
||||||
|
hashAction->setDisabled(isAllCall);
|
||||||
|
connect(hashAction, &QAction::triggered, this, [this](){
|
||||||
|
|
||||||
|
QString selectedCall = callsignSelected();
|
||||||
|
if(selectedCall.isEmpty()){
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
addMessageText(QString("%1#").arg(selectedCall), true);
|
||||||
|
});
|
||||||
|
|
||||||
auto retransmitAction = menu->addAction("|message - Please ACK and retransmit the following message");
|
auto retransmitAction = menu->addAction("|message - Please ACK and retransmit the following message");
|
||||||
retransmitAction->setDisabled(isAllCall);
|
retransmitAction->setDisabled(isAllCall);
|
||||||
connect(retransmitAction, &QAction::triggered, this, [this](){
|
connect(retransmitAction, &QAction::triggered, this, [this](){
|
||||||
@ -8901,7 +8914,8 @@ void MainWindow::processBufferedActivity() {
|
|||||||
|
|
||||||
bool valid = false;
|
bool valid = false;
|
||||||
|
|
||||||
if(buffer.cmd.cmd == "#"){
|
bool shouldUseLargeChecksum = false;
|
||||||
|
if(shouldUseLargeChecksum && buffer.cmd.cmd == "#"){
|
||||||
checksum = message.right(6);
|
checksum = message.right(6);
|
||||||
message = message.left(message.length() - 7);
|
message = message.left(message.length() - 7);
|
||||||
valid = Varicode::checksum32Valid(checksum, message);
|
valid = Varicode::checksum32Valid(checksum, message);
|
||||||
@ -9007,7 +9021,7 @@ void MainWindow::processCommandActivity() {
|
|||||||
reply = QString("%1 SNR %2").arg(d.from).arg(Varicode::formatSNR(d.snr));
|
reply = QString("%1 SNR %2").arg(d.from).arg(Varicode::formatSNR(d.snr));
|
||||||
}
|
}
|
||||||
// QUERIED ACK
|
// QUERIED ACK
|
||||||
//else if(d.cmd == "#"){
|
//else if(d.cmd == "^"){
|
||||||
// reply = QString("%1 ACK").arg(Radio::base_callsign(d.from));
|
// reply = QString("%1 ACK").arg(Radio::base_callsign(d.from));
|
||||||
//}
|
//}
|
||||||
// QUERIED PWR
|
// QUERIED PWR
|
||||||
@ -9061,6 +9075,11 @@ void MainWindow::processCommandActivity() {
|
|||||||
lines.prepend(QString("%1 ACK %2\n").arg(d.from).arg(i));
|
lines.prepend(QString("%1 ACK %2\n").arg(d.from).arg(i));
|
||||||
reply = lines.join(' ');
|
reply = lines.join(' ');
|
||||||
}
|
}
|
||||||
|
// PROCESS MESSAGE ACK
|
||||||
|
else if (d.cmd == "^" && !isAllCall) {
|
||||||
|
// TODO: jsherer - perhaps parse d.text and ensure it is a valid message as well as prefix it with our call...
|
||||||
|
reply = QString("%1 ACK").arg(d.from);
|
||||||
|
}
|
||||||
// PROCESS RETRANSMIT
|
// PROCESS RETRANSMIT
|
||||||
else if (d.cmd == "|" && !isAllCall) {
|
else if (d.cmd == "|" && !isAllCall) {
|
||||||
// TODO: jsherer - perhaps parse d.text and ensure it is a valid message as well as prefix it with our call...
|
// TODO: jsherer - perhaps parse d.text and ensure it is a valid message as well as prefix it with our call...
|
||||||
|
Loading…
Reference in New Issue
Block a user